continuing include file handling cleanup
This commit is contained in:
@ -11,9 +11,9 @@
|
||||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include "fix_manifoldforce.h" // For stuff
|
||||
#include <mpi.h>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "respa.h"
|
||||
@ -21,7 +21,6 @@
|
||||
#include "force.h"
|
||||
|
||||
#include "manifold.h"
|
||||
#include "fix_manifoldforce.h" // For stuff
|
||||
#include "manifold_factory.h" // For constructing manifold
|
||||
|
||||
|
||||
|
||||
@ -43,9 +43,9 @@ FixStyle(manifoldforce,FixManifoldForce)
|
||||
#define LMP_FIX_MANIFOLDFORCE_H
|
||||
|
||||
#include "fix.h"
|
||||
#include "manifold.h"
|
||||
|
||||
namespace LAMMPS_NS {
|
||||
namespace user_manifold { class manifold; }
|
||||
|
||||
class FixManifoldForce : public Fix {
|
||||
public:
|
||||
|
||||
@ -32,24 +32,18 @@
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include "fix_nve_manifold_rattle.h"
|
||||
#include <mpi.h>
|
||||
#include <cstring>
|
||||
#include "atom.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
#include "respa.h"
|
||||
#include "error.h"
|
||||
#include "group.h"
|
||||
#include <cmath>
|
||||
#include "input.h"
|
||||
#include "variable.h"
|
||||
#include "citeme.h"
|
||||
#include "memory.h"
|
||||
#include "comm.h"
|
||||
|
||||
|
||||
#include "fix_nve_manifold_rattle.h"
|
||||
#include "manifold_factory.h"
|
||||
#include "manifold.h"
|
||||
|
||||
|
||||
@ -42,12 +42,10 @@ FixStyle(nve/manifold/rattle,FixNVEManifoldRattle)
|
||||
#define LMP_FIX_NVE_MANIFOLD_RATTLE_H
|
||||
|
||||
#include "fix.h"
|
||||
#include "manifold.h"
|
||||
|
||||
|
||||
namespace LAMMPS_NS {
|
||||
|
||||
// namespace user_manifold {
|
||||
namespace user_manifold { class manifold; }
|
||||
|
||||
class FixNVEManifoldRattle : public Fix {
|
||||
public:
|
||||
@ -98,9 +96,7 @@ namespace LAMMPS_NS {
|
||||
|
||||
user_manifold::manifold *ptr_m;
|
||||
|
||||
|
||||
void print_stats( const char * );
|
||||
|
||||
int was_var( const char * );
|
||||
|
||||
virtual void update_var_params();
|
||||
|
||||
@ -32,25 +32,18 @@
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include "fix_nvt_manifold_rattle.h"
|
||||
#include <cstring>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
#include "respa.h"
|
||||
#include "error.h"
|
||||
#include "group.h"
|
||||
#include "input.h"
|
||||
#include "variable.h"
|
||||
#include "citeme.h"
|
||||
#include "memory.h"
|
||||
#include "comm.h"
|
||||
#include "modify.h"
|
||||
#include "compute.h"
|
||||
|
||||
#include "fix_nvt_manifold_rattle.h"
|
||||
#include "manifold.h"
|
||||
|
||||
|
||||
|
||||
@ -35,8 +35,7 @@
|
||||
#ifndef LMP_MANIFOLD_FACTORY_H
|
||||
#define LMP_MANIFOLD_FACTORY_H
|
||||
|
||||
|
||||
#include "manifold.h"
|
||||
#include <cstddef>
|
||||
#include <cstring>
|
||||
|
||||
/*
|
||||
@ -79,14 +78,16 @@ static FILE *screen = fopen("/dev/stdout","w");
|
||||
#define FLERR __FILE__,__LINE__ // Equivalent to definition in pointers.h
|
||||
#endif // USE_PHONY_LAMMPS
|
||||
|
||||
|
||||
|
||||
/* Here the actual implementation of LAMMPS-related functions begins. */
|
||||
|
||||
namespace LAMMPS_NS {
|
||||
class LAMMPS;
|
||||
|
||||
namespace user_manifold {
|
||||
|
||||
// forward declaration
|
||||
class manifold;
|
||||
|
||||
// Templated, so needs to be in header.
|
||||
template <typename m_type>
|
||||
void make_manifold_if( manifold **man_ptr, const char *name,
|
||||
@ -103,8 +104,6 @@ namespace user_manifold {
|
||||
int , char ** );
|
||||
|
||||
} // namespace user_manifold
|
||||
|
||||
} // namespace LAMMPS_NS
|
||||
|
||||
|
||||
#endif // LMP_MANIFOLD_FACTORY_H
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
#include "manifold_thylakoid.h"
|
||||
#include <cmath>
|
||||
|
||||
#include "manifold_thylakoid_shared.h"
|
||||
#include "comm.h"
|
||||
#include "domain.h" // For some checks regarding the simulation box.
|
||||
#include "error.h"
|
||||
|
||||
@ -4,12 +4,10 @@
|
||||
#include "manifold.h"
|
||||
#include <vector>
|
||||
|
||||
#include "manifold_thylakoid_shared.h"
|
||||
|
||||
namespace LAMMPS_NS {
|
||||
|
||||
namespace user_manifold {
|
||||
|
||||
struct thyla_part;
|
||||
|
||||
class manifold_thylakoid : public manifold {
|
||||
public:
|
||||
|
||||
@ -1,12 +1,12 @@
|
||||
#ifndef LMP_MEAM_H
|
||||
#define LMP_MEAM_H
|
||||
|
||||
#include "memory.h"
|
||||
#include <cmath>
|
||||
|
||||
#define maxelt 5
|
||||
|
||||
namespace LAMMPS_NS {
|
||||
class Memory;
|
||||
|
||||
typedef enum { FCC, BCC, HCP, DIM, DIA, B1, C11, L12, B2 } lattice_t;
|
||||
|
||||
|
||||
@ -1,5 +1,4 @@
|
||||
#include "meam.h"
|
||||
#include "math_special.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
|
||||
@ -1,4 +1,6 @@
|
||||
#include "meam.h"
|
||||
#include <cmath>
|
||||
#include "memory.h"
|
||||
#include "math_special.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
#include "meam.h"
|
||||
#include "math_special.h"
|
||||
#include <cmath>
|
||||
#include <algorithm>
|
||||
#include "math_special.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
|
||||
@ -16,6 +16,7 @@
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "meam.h"
|
||||
#include <cstddef>
|
||||
#include "memory.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
@ -1,6 +1,10 @@
|
||||
#include "meam.h"
|
||||
#include "math_special.h"
|
||||
#include <cmath>
|
||||
#include <cstddef>
|
||||
#include <algorithm>
|
||||
#include "math_special.h"
|
||||
#include "memory.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
void
|
||||
|
||||
@ -15,16 +15,14 @@
|
||||
Contributing author: Greg Wagner (SNL)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdio>
|
||||
#include "pair_meamc.h"
|
||||
#include <mpi.h>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include "meam.h"
|
||||
#include "pair_meamc.h"
|
||||
#include "atom.h"
|
||||
#include "force.h"
|
||||
#include "comm.h"
|
||||
#include "memory.h"
|
||||
#include "neighbor.h"
|
||||
#include "neigh_list.h"
|
||||
#include "neigh_request.h"
|
||||
|
||||
@ -24,7 +24,6 @@ PairStyle(meam,PairMEAMC)
|
||||
#include "pair.h"
|
||||
|
||||
namespace LAMMPS_NS {
|
||||
class MEAM;
|
||||
|
||||
class PairMEAMC : public Pair {
|
||||
public:
|
||||
|
||||
@ -20,8 +20,6 @@
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include <cmath>
|
||||
#include <cassert>
|
||||
|
||||
#define restrict __restrict__
|
||||
|
||||
|
||||
@ -19,7 +19,9 @@
|
||||
#ifndef READPOT__
|
||||
#define READPOT__
|
||||
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include "mgpt_splinetab.h"
|
||||
|
||||
struct potdata {
|
||||
|
||||
@ -21,17 +21,16 @@
|
||||
(2011). See LLNL copyright notice at bottom of this file.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "pair_mgpt.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include <cassert>
|
||||
|
||||
#include "pair_mgpt.h"
|
||||
#include "atom.h"
|
||||
#include "force.h"
|
||||
#include "comm.h"
|
||||
#include "memory.h"
|
||||
#include "neighbor.h"
|
||||
#include "neigh_list.h"
|
||||
#include "neigh_request.h"
|
||||
|
||||
@ -32,6 +32,7 @@ PairStyle(mgpt,PairMGPT)
|
||||
|
||||
#include <new>
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include <cassert>
|
||||
|
||||
#include "pair.h"
|
||||
@ -77,29 +78,29 @@ public:
|
||||
Link(const K &k,Link *n) : next(n),key(k),hits(1) {}
|
||||
|
||||
static void *operator new(std::size_t sz) {
|
||||
const size_t align = 32;
|
||||
size_t x = (size_t) (void *) ::operator new(sz+align);
|
||||
size_t y = (x + align) - ((x+align)&(align-1));
|
||||
assert(sizeof(void *) <= align);
|
||||
assert((x & (sizeof(void *)-1)) == 0);
|
||||
((void **) y)[-1] = (void *) x;
|
||||
return (void *) y;
|
||||
const size_t align = 32;
|
||||
size_t x = (size_t) (void *) ::operator new(sz+align);
|
||||
size_t y = (x + align) - ((x+align)&(align-1));
|
||||
assert(sizeof(void *) <= align);
|
||||
assert((x & (sizeof(void *)-1)) == 0);
|
||||
((void **) y)[-1] = (void *) x;
|
||||
return (void *) y;
|
||||
}
|
||||
static void operator delete(void *ptr) {
|
||||
::operator delete(((void **) ptr)[-1]);
|
||||
::operator delete(((void **) ptr)[-1]);
|
||||
}
|
||||
};
|
||||
|
||||
int isprime(int x) {
|
||||
if(x%2 == 0)
|
||||
return 0;
|
||||
return 0;
|
||||
else {
|
||||
int k = 3;
|
||||
while(k*k <= x) {
|
||||
if(x%k == 0) return 0;
|
||||
k = k+2;
|
||||
}
|
||||
return 1;
|
||||
int k = 3;
|
||||
while(k*k <= x) {
|
||||
if(x%k == 0) return 0;
|
||||
k = k+2;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
@ -117,25 +118,25 @@ public:
|
||||
Iterator(Hash &HH) : H(HH),idx(-1),p(0) { next(); }
|
||||
Iterator(Hash &HH,int iidx,Link *pp) : H(HH),idx(iidx),p(pp) {}
|
||||
void next() {
|
||||
if(idx >= H.Size()) return;
|
||||
if(p != 0) p = p->next;
|
||||
if(p == 0) {
|
||||
do {
|
||||
idx = idx+1;
|
||||
if(idx >= H.Size()) return;
|
||||
p = H.table[idx];
|
||||
} while(p == 0);
|
||||
}
|
||||
if(idx >= H.Size()) return;
|
||||
if(p != 0) p = p->next;
|
||||
if(p == 0) {
|
||||
do {
|
||||
idx = idx+1;
|
||||
if(idx >= H.Size()) return;
|
||||
p = H.table[idx];
|
||||
} while(p == 0);
|
||||
}
|
||||
}
|
||||
K *key() { return &p->key; }
|
||||
T *data() { return &p->data; }
|
||||
Link *link() { return p; }
|
||||
|
||||
int operator==(const Iterator &a) {
|
||||
return idx==a.idx && p==a.p;
|
||||
return idx==a.idx && p==a.p;
|
||||
}
|
||||
int operator!=(const Iterator &a) {
|
||||
return !(*this == a);
|
||||
return !(*this == a);
|
||||
}
|
||||
};
|
||||
|
||||
@ -147,7 +148,7 @@ public:
|
||||
|
||||
table = new Link *[size];
|
||||
for(int i = 0; i<size; i++)
|
||||
table[i] = 0;
|
||||
table[i] = 0;
|
||||
|
||||
/* Counters for statistics */
|
||||
maxlength = 0;
|
||||
@ -157,12 +158,12 @@ public:
|
||||
|
||||
~Hash() {
|
||||
for(int i = 0; i<size; i++) {
|
||||
Link *p = table[i];
|
||||
while(p != 0) {
|
||||
Link *q = p->next;
|
||||
delete p;
|
||||
p = q;
|
||||
}
|
||||
Link *p = table[i];
|
||||
while(p != 0) {
|
||||
Link *q = p->next;
|
||||
delete p;
|
||||
p = q;
|
||||
}
|
||||
}
|
||||
delete[] table;
|
||||
}
|
||||
@ -179,24 +180,24 @@ public:
|
||||
int idx = key.hash() % size;
|
||||
if(idx < 0) idx = idx + size;
|
||||
if(idx >= size || idx < 0) {
|
||||
printf("(1) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size);
|
||||
exit(1);
|
||||
printf("(1) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
used = used + 1;
|
||||
if(1) {
|
||||
table[idx] = new Link(key,table[idx]);
|
||||
return &table[idx]->data;
|
||||
table[idx] = new Link(key,table[idx]);
|
||||
return &table[idx]->data;
|
||||
} else { /* This is for threading... and incomplete */
|
||||
typedef Link *LinkPtr;
|
||||
LinkPtr ptr = table[idx],last = 0,dataptr = new Link(key,0);
|
||||
typedef Link *LinkPtr;
|
||||
LinkPtr ptr = table[idx],last = 0,dataptr = new Link(key,0);
|
||||
|
||||
while(ptr != 0) {
|
||||
last = ptr;
|
||||
ptr = ptr->next;
|
||||
}
|
||||
*((volatile LinkPtr *) &(last->next)) = dataptr;
|
||||
return &(dataptr->data);
|
||||
while(ptr != 0) {
|
||||
last = ptr;
|
||||
ptr = ptr->next;
|
||||
}
|
||||
*((volatile LinkPtr *) &(last->next)) = dataptr;
|
||||
return &(dataptr->data);
|
||||
}
|
||||
}
|
||||
void Remove(const K &key) {
|
||||
@ -205,28 +206,28 @@ public:
|
||||
int count = 1;
|
||||
if(idx < 0) idx = idx + size;
|
||||
if(idx >= size || idx < 0) {
|
||||
printf("(2) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size);
|
||||
exit(1);
|
||||
printf("(2) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
p = table[idx];
|
||||
while(p != 0 && !(p->key == key)) {
|
||||
last = p;
|
||||
p = p->next;
|
||||
count = count + 1;
|
||||
last = p;
|
||||
p = p->next;
|
||||
count = count + 1;
|
||||
}
|
||||
|
||||
if(p != 0) {
|
||||
used = used - 1;
|
||||
if(last == 0)
|
||||
table[idx] = p->next;
|
||||
else
|
||||
last->next = p->next;
|
||||
delete p;
|
||||
used = used - 1;
|
||||
if(last == 0)
|
||||
table[idx] = p->next;
|
||||
else
|
||||
last->next = p->next;
|
||||
delete p;
|
||||
}
|
||||
|
||||
if(count > maxlength)
|
||||
maxlength = count;
|
||||
maxlength = count;
|
||||
nsearch = nsearch + 1;
|
||||
nstep = nstep + count;
|
||||
}
|
||||
@ -236,19 +237,19 @@ public:
|
||||
int count = 1;
|
||||
if(idx < 0) idx = idx + size;
|
||||
if(idx >= size || idx < 0) {
|
||||
printf("(3) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size);
|
||||
exit(1);
|
||||
printf("(3) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
|
||||
p = table[idx];
|
||||
while(p != 0 && !(p->key == key)) {
|
||||
p = p->next;
|
||||
count = count + 1;
|
||||
p = p->next;
|
||||
count = count + 1;
|
||||
}
|
||||
|
||||
if(count > maxlength)
|
||||
maxlength = count;
|
||||
maxlength = count;
|
||||
nsearch = nsearch + 1;
|
||||
nstep = nstep + count;
|
||||
|
||||
@ -283,46 +284,46 @@ public:
|
||||
}
|
||||
void zero() {
|
||||
for(int i = 0; i<8; i++)
|
||||
for(int j = 0; j<8; j++)
|
||||
m[i][j] = 0.0;
|
||||
for(int j = 0; j<8; j++)
|
||||
m[i][j] = 0.0;
|
||||
}
|
||||
|
||||
void operator=(const Matrix &A) {
|
||||
for(int i = 1; i<=sz; i++)
|
||||
for(int j = 1; j<=sz; j++)
|
||||
m[i][j] = A.m[i][j];
|
||||
for(int j = 1; j<=sz; j++)
|
||||
m[i][j] = A.m[i][j];
|
||||
}
|
||||
void operator=(double x) {
|
||||
for(int i = 1; i<=sz; i++)
|
||||
for(int j = 1; j<=sz; j++)
|
||||
m[i][j] = x;
|
||||
for(int j = 1; j<=sz; j++)
|
||||
m[i][j] = x;
|
||||
}
|
||||
Matrix operator+(const Matrix &B) const {
|
||||
Matrix s;
|
||||
for(int i = 1; i<=sz; i++)
|
||||
for(int j = 1; j<=sz; j++)
|
||||
s.m[i][j] = m[i][j] + B.m[i][j];
|
||||
for(int j = 1; j<=sz; j++)
|
||||
s.m[i][j] = m[i][j] + B.m[i][j];
|
||||
return s;
|
||||
}
|
||||
Matrix operator-(const Matrix &B) const {
|
||||
Matrix s;
|
||||
for(int i = 1; i<=sz; i++)
|
||||
for(int j = 1; j<=sz; j++)
|
||||
s.m[i][j] = m[i][j] - B.m[i][j];
|
||||
for(int j = 1; j<=sz; j++)
|
||||
s.m[i][j] = m[i][j] - B.m[i][j];
|
||||
return s;
|
||||
}
|
||||
Matrix operator-() const {
|
||||
Matrix s;
|
||||
for(int i = 1; i<=sz; i++)
|
||||
for(int j = 1; j<=sz; j++)
|
||||
s.m[i][j] = -m[i][j];
|
||||
for(int j = 1; j<=sz; j++)
|
||||
s.m[i][j] = -m[i][j];
|
||||
return s;
|
||||
}
|
||||
Matrix operator*(double x) const {
|
||||
Matrix P;
|
||||
for(int i = 1; i<=sz; i++)
|
||||
for(int j = 0; j<=sz; j++)
|
||||
P.m[i][j] = m[i][j] * x;
|
||||
for(int j = 0; j<=sz; j++)
|
||||
P.m[i][j] = m[i][j] * x;
|
||||
return P;
|
||||
}
|
||||
Matrix operator/(double x) const {
|
||||
@ -331,8 +332,8 @@ public:
|
||||
Matrix transpose() const {
|
||||
Matrix T;
|
||||
for(int i = 1; i<=sz; i++)
|
||||
for(int j = 1; j<=sz; j++)
|
||||
T.m[j][i] = m[i][j];
|
||||
for(int j = 1; j<=sz; j++)
|
||||
T.m[j][i] = m[i][j];
|
||||
return T;
|
||||
}
|
||||
};
|
||||
@ -374,13 +375,13 @@ public:
|
||||
|
||||
int align_check() {
|
||||
return
|
||||
(H1H2.align_check() << 0) |
|
||||
(H1xH2.align_check() << 1) |
|
||||
(H1yH2.align_check() << 2) |
|
||||
(H1zH2.align_check() << 3) |
|
||||
(H1H2x.align_check() << 4) |
|
||||
(H1H2y.align_check() << 5) |
|
||||
(H1H2z.align_check() << 6) ;
|
||||
(H1H2.align_check() << 0) |
|
||||
(H1xH2.align_check() << 1) |
|
||||
(H1yH2.align_check() << 2) |
|
||||
(H1zH2.align_check() << 3) |
|
||||
(H1H2x.align_check() << 4) |
|
||||
(H1H2y.align_check() << 5) |
|
||||
(H1H2z.align_check() << 6) ;
|
||||
}
|
||||
|
||||
void zero() {
|
||||
@ -396,18 +397,18 @@ public:
|
||||
void make_bond(const double xx[][3],int i,int j,bond_data *bptr);
|
||||
void make_triplet(bond_data *ij_bond,bond_data *ik_bond,triplet_data *triptr);
|
||||
triplet_data *get_triplet(const double xx[][3],int i,int j,int k,
|
||||
Hash<bond_data,Doublet> *bhash,triplet_data *twork,
|
||||
double *dvir_ij_p,double *dvir_ik_p);
|
||||
Hash<bond_data,Doublet> *bhash,triplet_data *twork,
|
||||
double *dvir_ij_p,double *dvir_ik_p);
|
||||
|
||||
int c1_outside(const double a[3],
|
||||
int triclinic,const double alpha[3]) {
|
||||
int triclinic,const double alpha[3]) {
|
||||
const double stol = 1e-5;
|
||||
|
||||
if(triclinic) {
|
||||
for(int p = 0; p<3; p++) {
|
||||
double cog = a[p];
|
||||
if(cog < domain->sublo_lamda[p]-0.5*rmax*alpha[p]-stol) return 1;
|
||||
if(cog > domain->subhi_lamda[p]+0.5*rmax*alpha[p]+stol) return 1;
|
||||
double cog = a[p];
|
||||
if(cog < domain->sublo_lamda[p]-0.5*rmax*alpha[p]-stol) return 1;
|
||||
if(cog > domain->subhi_lamda[p]+0.5*rmax*alpha[p]+stol) return 1;
|
||||
}
|
||||
|
||||
} else {
|
||||
@ -415,63 +416,63 @@ public:
|
||||
|
||||
|
||||
for(int p = 0; p<3; p++) {
|
||||
double cog = a[p];
|
||||
if(cog < domain->sublo[p]-0.5*rmax-stol) return 1;
|
||||
if(cog > domain->subhi[p]+0.5*rmax+stol) return 1;
|
||||
double cog = a[p];
|
||||
if(cog < domain->sublo[p]-0.5*rmax-stol) return 1;
|
||||
if(cog > domain->subhi[p]+0.5*rmax+stol) return 1;
|
||||
|
||||
if(cog < domain->sublo[p]-stol) {
|
||||
double t = cog - (domain->sublo[p]-stol);
|
||||
rout = rout + t*t;
|
||||
} else if(cog > domain->subhi[p]+stol) {
|
||||
double t = cog - (domain->subhi[p]+stol);
|
||||
rout = rout + t*t;
|
||||
}
|
||||
if(cog < domain->sublo[p]-stol) {
|
||||
double t = cog - (domain->sublo[p]-stol);
|
||||
rout = rout + t*t;
|
||||
} else if(cog > domain->subhi[p]+stol) {
|
||||
double t = cog - (domain->subhi[p]+stol);
|
||||
rout = rout + t*t;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if(rout > 0.25*rmax*rmax)
|
||||
return 1;
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
int c2_outside(const double a[3],const double b[3],
|
||||
int triclinic,const double alpha[3]) {
|
||||
int triclinic,const double alpha[3]) {
|
||||
const double stol = 1e-5;
|
||||
|
||||
if(triclinic) {
|
||||
for(int p = 0; p<3; p++) {
|
||||
double cog = 0.5*(a[p] + b[p]);
|
||||
if(cog < domain->sublo_lamda[p]-0.5*rcrit*alpha[p]-stol) return 1;
|
||||
if(cog > domain->subhi_lamda[p]+0.5*rcrit*alpha[p]+stol) return 1;
|
||||
double cog = 0.5*(a[p] + b[p]);
|
||||
if(cog < domain->sublo_lamda[p]-0.5*rcrit*alpha[p]-stol) return 1;
|
||||
if(cog > domain->subhi_lamda[p]+0.5*rcrit*alpha[p]+stol) return 1;
|
||||
}
|
||||
} else {
|
||||
double rout = 0.0;
|
||||
|
||||
for(int p = 0; p<3; p++) {
|
||||
double cog = 0.5*(a[p] + b[p]);
|
||||
if(cog < domain->sublo[p]-0.5*rcrit-stol) return 1;
|
||||
if(cog > domain->subhi[p]+0.5*rcrit+stol) return 1;
|
||||
double cog = 0.5*(a[p] + b[p]);
|
||||
if(cog < domain->sublo[p]-0.5*rcrit-stol) return 1;
|
||||
if(cog > domain->subhi[p]+0.5*rcrit+stol) return 1;
|
||||
|
||||
if(cog < domain->sublo[p]-stol) {
|
||||
double t = cog - (domain->sublo[p]-stol);
|
||||
rout = rout + t*t;
|
||||
} else if(cog > domain->subhi[p]+stol) {
|
||||
double t = cog - (domain->subhi[p]+stol);
|
||||
rout = rout + t*t;
|
||||
}
|
||||
if(cog < domain->sublo[p]-stol) {
|
||||
double t = cog - (domain->sublo[p]-stol);
|
||||
rout = rout + t*t;
|
||||
} else if(cog > domain->subhi[p]+stol) {
|
||||
double t = cog - (domain->subhi[p]+stol);
|
||||
rout = rout + t*t;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if(rout > 0.25*rcrit*rcrit)
|
||||
return 1;
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
double get_weight(const int triclinic,
|
||||
const double a[3] = 0,const double b[3] = 0,
|
||||
const double c[3] = 0,const double d[3] = 0) {
|
||||
const double a[3] = 0,const double b[3] = 0,
|
||||
const double c[3] = 0,const double d[3] = 0) {
|
||||
const double
|
||||
*s0 = triclinic ? domain->sublo_lamda : domain->sublo,
|
||||
*s1 = triclinic ? domain->subhi_lamda : domain->subhi;
|
||||
@ -498,46 +499,46 @@ public:
|
||||
}
|
||||
|
||||
void force_debug_3t(double xx[][3],
|
||||
int i0,int j0,int k0,
|
||||
int i ,int j ,int k ,
|
||||
double dfix,double dfiy,double dfiz,
|
||||
double dfjx,double dfjy,double dfjz,
|
||||
double dfkx,double dfky,double dfkz);
|
||||
int i0,int j0,int k0,
|
||||
int i ,int j ,int k ,
|
||||
double dfix,double dfiy,double dfiz,
|
||||
double dfjx,double dfjy,double dfjz,
|
||||
double dfkx,double dfky,double dfkz);
|
||||
|
||||
void force_debug_3v(double xx[][3],
|
||||
int i0,int j0,int k0,
|
||||
int i ,int j ,int k ,
|
||||
double dfix,double dfiy,double dfiz,
|
||||
double dfjx,double dfjy,double dfjz,
|
||||
double dfkx,double dfky,double dfkz);
|
||||
int i0,int j0,int k0,
|
||||
int i ,int j ,int k ,
|
||||
double dfix,double dfiy,double dfiz,
|
||||
double dfjx,double dfjy,double dfjz,
|
||||
double dfkx,double dfky,double dfkz);
|
||||
|
||||
void force_debug_4(double xx[][3],
|
||||
int i0,int j0,int k0,int m0,
|
||||
int i ,int j ,int k ,int m ,
|
||||
double dfix,double dfiy,double dfiz,
|
||||
double dfjx,double dfjy,double dfjz,
|
||||
double dfkx,double dfky,double dfkz,
|
||||
double dfmx,double dfmy,double dfmz);
|
||||
int i0,int j0,int k0,int m0,
|
||||
int i ,int j ,int k ,int m ,
|
||||
double dfix,double dfiy,double dfiz,
|
||||
double dfjx,double dfjy,double dfjz,
|
||||
double dfkx,double dfky,double dfkz,
|
||||
double dfmx,double dfmy,double dfmz);
|
||||
|
||||
double numderiv3t(double xx[][3],int i,int j,int k,int p);
|
||||
double numderiv3v(double xx[][3],int i,int j,int k,int p,int ipert);
|
||||
double numderiv4(double xx[][3],int i,int j,int k,int m,int p);
|
||||
void compute_x(const int *nnei,const int * const *nlist,
|
||||
double *e_s,double *e_p,double *e_t,double *e_q,
|
||||
int evflag,int newton_pair);
|
||||
double *e_s,double *e_p,double *e_t,double *e_q,
|
||||
int evflag,int newton_pair);
|
||||
|
||||
/* Reimplementation of bond matrix computation */
|
||||
void fl_deriv_new(double r,double ri,double xhat,double yhat,double zhat,
|
||||
double &fl_0,double &fl_x,double &fl_y,double &fl_z,
|
||||
double &fl_rp,double &fl_p1,double &fl_r0,double &fl_al);
|
||||
double &fl_0,double &fl_x,double &fl_y,double &fl_z,
|
||||
double &fl_rp,double &fl_p1,double &fl_r0,double &fl_al);
|
||||
void hamltn_5_raw(const double xin,const double yin,const double zin,
|
||||
double M [8][8],double Mx[8][8],
|
||||
double My[8][8],double Mz[8][8],
|
||||
double *fl_deriv_sum_p);
|
||||
double M [8][8],double Mx[8][8],
|
||||
double My[8][8],double Mz[8][8],
|
||||
double *fl_deriv_sum_p);
|
||||
void hamltn_7_raw(const double xin,const double yin,const double zin,
|
||||
double M [8][8],double Mx[8][8],
|
||||
double My[8][8],double Mz[8][8],
|
||||
double *fl_deriv_sum_p);
|
||||
double M [8][8],double Mx[8][8],
|
||||
double My[8][8],double Mz[8][8],
|
||||
double *fl_deriv_sum_p);
|
||||
/* * */
|
||||
// Old matrix routines, only used in force debug routines.
|
||||
|
||||
@ -546,9 +547,9 @@ public:
|
||||
Matrix h;
|
||||
for(int l = 1; l <= lmax; l++) {
|
||||
for(int n = 1; n <= lmax; n++) {
|
||||
h.m[l][n] = 0.0;
|
||||
for(int m = 1; m <= lmax; m++)
|
||||
h.m[l][n] += ha.m[l][m] * hb.m[m][n];
|
||||
h.m[l][n] = 0.0;
|
||||
for(int m = 1; m <= lmax; m++)
|
||||
h.m[l][n] += ha.m[l][m] * hb.m[m][n];
|
||||
}
|
||||
}
|
||||
return h;
|
||||
@ -560,7 +561,7 @@ public:
|
||||
for(int n = 1; n <= lmax; n++) {
|
||||
double cquan = 0.0;
|
||||
for(int m = 1; m <= lmax; m++)
|
||||
cquan += ha.m[n][m] * hb.m[m][n];
|
||||
cquan += ha.m[n][m] * hb.m[m][n];
|
||||
zquan += cquan;
|
||||
}
|
||||
return zquan;
|
||||
@ -572,32 +573,32 @@ public:
|
||||
int i,j,k;
|
||||
|
||||
if(lmax == 5) {
|
||||
const int n = 5;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(j = 1; j<=n; j++) {
|
||||
double s = 0.0;
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[j][k];
|
||||
c.m[i][j] = s;
|
||||
}
|
||||
const int n = 5;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(j = 1; j<=n; j++) {
|
||||
double s = 0.0;
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[j][k];
|
||||
c.m[i][j] = s;
|
||||
}
|
||||
} else if(lmax == 7) {
|
||||
const int n = 7;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(j = 1; j<=n; j++) {
|
||||
double s = 0.0;
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[j][k];
|
||||
c.m[i][j] = s;
|
||||
}
|
||||
const int n = 7;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(j = 1; j<=n; j++) {
|
||||
double s = 0.0;
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[j][k];
|
||||
c.m[i][j] = s;
|
||||
}
|
||||
} else {
|
||||
const int n = lmax;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(j = 1; j<=n; j++) {
|
||||
double s = 0.0;
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[j][k];
|
||||
c.m[i][j] = s;
|
||||
}
|
||||
const int n = lmax;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(j = 1; j<=n; j++) {
|
||||
double s = 0.0;
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[j][k];
|
||||
c.m[i][j] = s;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -608,7 +609,7 @@ public:
|
||||
|
||||
for(i = 0; i<n; i++)
|
||||
for(j = 1; j<=n; j++)
|
||||
s = s + A[i][j]*B[i][j];
|
||||
s = s + A[i][j]*B[i][j];
|
||||
return s;
|
||||
}
|
||||
inline double transtrace(const Matrix& a,const Matrix& b) const
|
||||
@ -617,25 +618,25 @@ public:
|
||||
double s = 0.0;
|
||||
|
||||
if(linalg.single)
|
||||
return transtrace_s((const float (*)[8]) &a.m[1][0],(const float (*)[8]) &b.m[1][0]);
|
||||
return transtrace_s((const float (*)[8]) &a.m[1][0],(const float (*)[8]) &b.m[1][0]);
|
||||
|
||||
//printf("Calling transtrace... That is shit\n");
|
||||
|
||||
if(lmax == 5) {
|
||||
const int n = 5;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[i][k];
|
||||
const int n = 5;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[i][k];
|
||||
} else if(lmax == 7) {
|
||||
const int n = 7;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[i][k];
|
||||
const int n = 7;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[i][k];
|
||||
} else {
|
||||
const int n = lmax;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[i][k];
|
||||
const int n = lmax;
|
||||
for(i = 1; i<=n; i++)
|
||||
for(k = 1; k<=n; k++)
|
||||
s = s + a.m[i][k]*b.m[i][k];
|
||||
}
|
||||
return s;
|
||||
}
|
||||
|
||||
@ -15,9 +15,9 @@
|
||||
Contributing author: Carsten Svaneborg, science@zqex.dk
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "angle_cosine_shift.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
|
||||
@ -15,9 +15,9 @@
|
||||
Contributing author: Carsten Svaneborg, science@zqex.dk
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "angle_cosine_shift_exp.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
|
||||
@ -15,9 +15,9 @@
|
||||
Contributing authors: Mario Orsi & Wei Ding (QMUL), m.orsi@qmul.ac.uk
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "angle_dipole.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
|
||||
@ -16,9 +16,9 @@
|
||||
[ based on angle_cosine_squared.cpp Naveen Michaud-Agrawal (Johns Hopkins U)]
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "angle_fourier.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
|
||||
@ -16,9 +16,9 @@
|
||||
[ based on angle_cosine_squared.cpp Naveen Michaud-Agrawal (Johns Hopkins U)]
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "angle_fourier_simple.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
|
||||
@ -16,9 +16,9 @@
|
||||
[ based on angle_harmonic.cpp]
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "angle_quartic.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
|
||||
@ -15,12 +15,11 @@
|
||||
Contributing author: Carsten Svaneborg, science@zqex.dk
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "bond_harmonic_shift.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
#include "comm.h"
|
||||
#include "force.h"
|
||||
#include "memory.h"
|
||||
|
||||
@ -15,12 +15,11 @@
|
||||
Contributing author: Carsten Svaneborg, science@zqex.dk
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "bond_harmonic_shift_cut.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
#include "comm.h"
|
||||
#include "force.h"
|
||||
#include "memory.h"
|
||||
|
||||
@ -21,11 +21,10 @@
|
||||
branicio@usc.edu
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include <cmath>
|
||||
|
||||
#include "compute_cnp_atom.h"
|
||||
#include <mpi.h>
|
||||
#include <cstring>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "modify.h"
|
||||
|
||||
@ -15,10 +15,9 @@
|
||||
Contributing author: Pablo Piaggi (EPFL Lausanne)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "compute_entropy_atom.h"
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "compute_entropy_atom.h"
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "modify.h"
|
||||
@ -28,13 +27,11 @@
|
||||
#include "force.h"
|
||||
#include "pair.h"
|
||||
#include "comm.h"
|
||||
#include "math_extra.h"
|
||||
#include "math_const.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
#include "domain.h"
|
||||
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace MathConst;
|
||||
|
||||
|
||||
@ -11,10 +11,9 @@
|
||||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "compute_pressure_cylinder.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "force.h"
|
||||
@ -22,7 +21,6 @@
|
||||
#include "neighbor.h"
|
||||
#include "neigh_request.h"
|
||||
#include "neigh_list.h"
|
||||
#include "group.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
#include "citeme.h"
|
||||
|
||||
@ -11,17 +11,13 @@
|
||||
See the README file in the top-level LAMMPS directory.
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <mpi.h>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "compute_pressure_grem.h"
|
||||
#include "atom.h"
|
||||
#include <cstring>
|
||||
#include "update.h"
|
||||
#include "domain.h"
|
||||
#include "modify.h"
|
||||
#include "fix.h"
|
||||
#include "force.h"
|
||||
#include "pair.h"
|
||||
#include "kspace.h"
|
||||
#include "error.h"
|
||||
|
||||
|
||||
@ -15,18 +15,14 @@
|
||||
Contributing Authors : Romain Vermorel (LFCR), Laurent Joly (ULyon)
|
||||
--------------------------------------------------------------------------*/
|
||||
|
||||
#include "compute_stress_mop.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
|
||||
#include "compute_stress_mop.h"
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "domain.h"
|
||||
#include "group.h"
|
||||
#include "modify.h"
|
||||
#include "fix.h"
|
||||
#include "neighbor.h"
|
||||
#include "force.h"
|
||||
#include "pair.h"
|
||||
|
||||
@ -15,18 +15,14 @@
|
||||
Contributing Authors : Romain Vermorel (LFCR), Laurent Joly (ULyon)
|
||||
--------------------------------------------------------------------------*/
|
||||
|
||||
#include "compute_stress_mop_profile.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
|
||||
#include "compute_stress_mop_profile.h"
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "domain.h"
|
||||
#include "group.h"
|
||||
#include "modify.h"
|
||||
#include "fix.h"
|
||||
#include "neighbor.h"
|
||||
#include "force.h"
|
||||
#include "pair.h"
|
||||
|
||||
@ -15,16 +15,13 @@
|
||||
Contributing author: Laurent Joly (U Lyon, France), ljoly.ulyon@gmail.com
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <mpi.h>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include "compute_temp_rotate.h"
|
||||
#include <mpi.h>
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "force.h"
|
||||
#include "group.h"
|
||||
#include "domain.h"
|
||||
#include "lattice.h"
|
||||
#include "error.h"
|
||||
#include "memory.h"
|
||||
|
||||
|
||||
@ -15,14 +15,12 @@
|
||||
Contributing author: Carsten Svaneborg, science@zqex.dk
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "dihedral_cosine_shift_exp.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "dihedral_cosine_shift_exp.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
#include "memory.h"
|
||||
|
||||
@ -16,16 +16,13 @@
|
||||
[ based on dihedral_charmm.cpp Paul Crozier (SNL) ]
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "dihedral_fourier.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "dihedral_fourier.h"
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
#include "force.h"
|
||||
#include "pair.h"
|
||||
#include "update.h"
|
||||
#include "math_const.h"
|
||||
#include "memory.h"
|
||||
|
||||
@ -16,12 +16,11 @@
|
||||
[ based on dihedral_multi_harmonic.cpp Mathias Puetz (SNL) and friends ]
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "dihedral_nharmonic.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
#include "comm.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
|
||||
@ -16,12 +16,11 @@
|
||||
[ based on dihedral_helix.cpp Paul Crozier (SNL) ]
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include "dihedral_quadratic.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
#include "comm.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
|
||||
@ -17,22 +17,19 @@
|
||||
and Paul Crozier (SNL) ]
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "dihedral_spherical.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include <cassert>
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
#include "force.h"
|
||||
#include "pair.h"
|
||||
#include "update.h"
|
||||
#include "math_const.h"
|
||||
#include "math_extra.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
#include "dihedral_spherical.h"
|
||||
|
||||
using namespace std;
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
@ -17,21 +17,20 @@
|
||||
the "tridiag.c" written by Gerard Jungman for GSL
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <mpi.h>
|
||||
#include <cctype>
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include <cassert>
|
||||
#include <string>
|
||||
#include <fstream>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
#include <sstream> // IWYU pragma: keep
|
||||
#include <fstream> // IWYU pragma: keep
|
||||
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
#include "neighbor.h"
|
||||
#include "domain.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
#include "dihedral_table.h"
|
||||
|
||||
@ -16,25 +16,23 @@
|
||||
Based on tabulated dihedral (dihedral_table.cpp) by Andrew Jewett
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "dihedral_table_cut.h"
|
||||
#include <mpi.h>
|
||||
#include <cctype>
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include <cassert>
|
||||
#include <string>
|
||||
#include <fstream>
|
||||
#include <iostream>
|
||||
#include <sstream>
|
||||
#include <fstream> // IWYU pragma: keep
|
||||
#include <sstream> // IWYU pragma: keep
|
||||
|
||||
#include "dihedral_table_cut.h"
|
||||
#include "atom.h"
|
||||
#include "neighbor.h"
|
||||
#include "update.h"
|
||||
#include "domain.h"
|
||||
#include "comm.h"
|
||||
#include "force.h"
|
||||
#include "citeme.h"
|
||||
#include "math_const.h"
|
||||
#include "math_extra.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
#include "utils.h"
|
||||
@ -42,8 +40,6 @@
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace MathConst;
|
||||
using namespace std;
|
||||
using namespace MathExtra;
|
||||
|
||||
|
||||
static const char cite_dihedral_tablecut[] =
|
||||
"dihedral_style table/cut command:\n\n"
|
||||
|
||||
@ -15,9 +15,9 @@
|
||||
Contributing author: Laurent Joly (U Lyon, France), ljoly.ulyon@gmail.com
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "fix_addtorque.h"
|
||||
#include <mpi.h>
|
||||
#include <cstring>
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "modify.h"
|
||||
@ -25,7 +25,6 @@
|
||||
#include "respa.h"
|
||||
#include "input.h"
|
||||
#include "variable.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
#include "group.h"
|
||||
#include "force.h"
|
||||
|
||||
@ -21,11 +21,12 @@
|
||||
see J. Chem. Phys. 133, 154103 (2010)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "fix_ave_correlate_long.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include <unistd.h>
|
||||
#include "fix_ave_correlate_long.h"
|
||||
#include "update.h"
|
||||
#include "modify.h"
|
||||
#include "compute.h"
|
||||
|
||||
@ -15,11 +15,10 @@ See the README file in the top-level LAMMPS directory.
|
||||
Contributing Author: Jacob Gissinger (jacob.gissinger@colorado.edu)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "fix_bond_react.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "fix_bond_react.h"
|
||||
#include "update.h"
|
||||
#include "modify.h"
|
||||
#include "respa.h"
|
||||
|
||||
@ -16,16 +16,14 @@
|
||||
Information: k.avchachov@gmail.com
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdio>
|
||||
#include <cstring>
|
||||
#include "fix_electron_stopping.h"
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include "mpi.h"
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "domain.h"
|
||||
#include "region.h"
|
||||
#include "group.h"
|
||||
#include "force.h"
|
||||
#include "fix.h"
|
||||
#include "memory.h"
|
||||
|
||||
@ -18,31 +18,21 @@
|
||||
|
||||
/* ----------------------------------------------------------------------
|
||||
Contributing authors: Lionel Constantin (EPFL), David M. Wilkins (EPFL),
|
||||
Michele Ceriotti (EPFL)
|
||||
Michele Ceriotti (EPFL)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "fix_ffl.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "fix_ffl.h"
|
||||
#include "math_extra.h"
|
||||
#include "atom.h"
|
||||
#include "atom_vec_ellipsoid.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
#include "modify.h"
|
||||
#include "compute.h"
|
||||
#include "domain.h"
|
||||
#include "region.h"
|
||||
#include "respa.h"
|
||||
#include "comm.h"
|
||||
#include "input.h"
|
||||
#include "variable.h"
|
||||
#include "random_mars.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
#include "group.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace FixConst;
|
||||
|
||||
@ -16,30 +16,25 @@
|
||||
some subroutines are from fix_shake.cpp
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "fix_filter_corotate.h"
|
||||
#include <mpi.h>
|
||||
#include <cctype>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "fix_filter_corotate.h"
|
||||
#include "atom.h"
|
||||
#include "atom_vec.h"
|
||||
#include "molecule.h"
|
||||
#include "bond.h"
|
||||
#include "comm.h"
|
||||
#include "domain.h"
|
||||
#include "angle.h"
|
||||
#include "bond.h"
|
||||
#include "math_const.h"
|
||||
#include "update.h"
|
||||
#include "modify.h"
|
||||
#include "domain.h"
|
||||
#include "region.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
#include "force.h"
|
||||
#include "comm.h"
|
||||
#include "error.h"
|
||||
#include "memory.h"
|
||||
#include "domain.h"
|
||||
#include "integrate.h"
|
||||
#include "respa.h"
|
||||
#include "neighbor.h"
|
||||
#include "citeme.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
@ -16,13 +16,12 @@
|
||||
Joel.Eaves@Colorado.edu
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include "fix_flow_gauss.h"
|
||||
#include <mpi.h>
|
||||
#include <cstring>
|
||||
#include "atom.h"
|
||||
#include "force.h"
|
||||
#include "group.h"
|
||||
#include "comm.h"
|
||||
#include "update.h"
|
||||
#include "domain.h"
|
||||
#include "error.h"
|
||||
|
||||
@ -16,28 +16,19 @@
|
||||
Axel Kohylmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "fix_gle.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "fix_gle.h"
|
||||
#include "math_extra.h"
|
||||
#include "atom.h"
|
||||
#include "atom_vec_ellipsoid.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
#include "modify.h"
|
||||
#include "compute.h"
|
||||
#include "domain.h"
|
||||
#include "region.h"
|
||||
#include "respa.h"
|
||||
#include "comm.h"
|
||||
#include "input.h"
|
||||
#include "variable.h"
|
||||
#include "random_mars.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
#include "group.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace FixConst;
|
||||
|
||||
@ -22,19 +22,14 @@
|
||||
Tom Keyes (Boston University)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include <cmath>
|
||||
#include "comm.h"
|
||||
#include "fix_grem.h"
|
||||
#include <cstring>
|
||||
#include "atom.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
#include "modify.h"
|
||||
#include "domain.h"
|
||||
#include "input.h"
|
||||
#include "compute.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
@ -15,15 +15,12 @@
|
||||
Contributing author: Michele Ceriotti (EPFL), Axel Kohlmeyer (Temple U)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <mpi.h>
|
||||
#include <cstdio>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "fix_ipi.h"
|
||||
#include <mpi.h>
|
||||
#include <cstring>
|
||||
#include "atom.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
#include "respa.h"
|
||||
#include "error.h"
|
||||
#include "kspace.h"
|
||||
#include "modify.h"
|
||||
@ -32,8 +29,6 @@
|
||||
#include "neighbor.h"
|
||||
#include "irregular.h"
|
||||
#include "domain.h"
|
||||
#include "compute_pressure.h"
|
||||
#include <errno.h>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace FixConst;
|
||||
|
||||
@ -15,18 +15,16 @@
|
||||
Contributing author: Efrem Braun (UC Berkeley)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdio>
|
||||
#include <cstring>
|
||||
#include "fix_nvk.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include "atom.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
#include "respa.h"
|
||||
#include "error.h"
|
||||
#include "compute.h"
|
||||
#include "math_extra.h"
|
||||
#include "domain.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace FixConst;
|
||||
|
||||
@ -21,10 +21,11 @@
|
||||
Version 1.0
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "fix_pimd.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "fix_pimd.h"
|
||||
#include "universe.h"
|
||||
#include "comm.h"
|
||||
#include "force.h"
|
||||
|
||||
@ -13,12 +13,11 @@
|
||||
Contributing author: Ulf R. Pedersen, ulf@urp.dk
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstdlib>
|
||||
#include "fix_rhok.h"
|
||||
#include <mpi.h>
|
||||
#include <cstring>
|
||||
#include <cmath>
|
||||
|
||||
#include "fix_rhok.h"
|
||||
#include "atom.h"
|
||||
#include "domain.h"
|
||||
#include "error.h"
|
||||
|
||||
@ -16,10 +16,10 @@
|
||||
based on fix spring by: Paul Crozier (SNL)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include "fix_smd.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
#include "update.h"
|
||||
|
||||
@ -15,9 +15,10 @@
|
||||
Contributing authors: Timothy Sirk (ARL), Pieter in't Veld (BASF)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "fix_srp.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include "atom.h"
|
||||
#include "force.h"
|
||||
#include "domain.h"
|
||||
@ -635,11 +636,11 @@ void FixSRP::restart(char *buf)
|
||||
int FixSRP::modify_param(int /*narg*/, char **arg)
|
||||
{
|
||||
if (strcmp(arg[0],"btype") == 0) {
|
||||
btype = atoi(arg[1]);
|
||||
btype = force->inumeric(FLERR,arg[1]);
|
||||
return 2;
|
||||
}
|
||||
if (strcmp(arg[0],"bptype") == 0) {
|
||||
bptype = atoi(arg[1]);
|
||||
bptype = force->inumeric(FLERR,arg[1]);
|
||||
return 2;
|
||||
}
|
||||
return 0;
|
||||
|
||||
@ -18,9 +18,9 @@
|
||||
Maurice de Koning (Unicamp/Brazil) - dekoning@ifi.unicamp.br
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include "fix_ti_spring.h"
|
||||
#include <mpi.h>
|
||||
#include <cstring>
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "domain.h"
|
||||
|
||||
@ -17,17 +17,14 @@
|
||||
Vasily Pisarev (Joint Institute for High Temperatures of RAS)
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "lmptype.h"
|
||||
#include "fix_ttm_mod.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <cstdlib>
|
||||
#include "fix_ttm_mod.h"
|
||||
#include "atom.h"
|
||||
#include "force.h"
|
||||
#include "update.h"
|
||||
#include "domain.h"
|
||||
#include "region.h"
|
||||
#include "respa.h"
|
||||
#include "comm.h"
|
||||
#include "random_mars.h"
|
||||
|
||||
@ -15,21 +15,13 @@
|
||||
Contributing author: Abdoreza Ershadinia, a.ershadinia at gmail.com
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "fix_wall_ees.h"
|
||||
#include <cmath>
|
||||
#include "math_extra.h"
|
||||
#include "fix_wall_ees.h"
|
||||
#include "atom.h"
|
||||
#include "atom_vec.h"
|
||||
#include "atom_vec_ellipsoid.h"
|
||||
#include "domain.h"
|
||||
#include "region.h"
|
||||
#include "force.h"
|
||||
#include "lattice.h"
|
||||
#include "update.h"
|
||||
#include "output.h"
|
||||
#include "respa.h"
|
||||
#include "error.h"
|
||||
#include "math_extra.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace FixConst;
|
||||
|
||||
@ -15,19 +15,16 @@
|
||||
Contributing author: Abdoreza Ershadinia, a.ershadinia at gmail.com
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include <cmath>
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
#include "fix_wall_region_ees.h"
|
||||
#include <mpi.h>
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include "atom.h"
|
||||
#include "atom_vec.h"
|
||||
#include "atom_vec_ellipsoid.h"
|
||||
#include "domain.h"
|
||||
#include "region.h"
|
||||
#include "force.h"
|
||||
#include "lattice.h"
|
||||
#include "update.h"
|
||||
#include "output.h"
|
||||
#include "respa.h"
|
||||
#include "error.h"
|
||||
#include "math_extra.h"
|
||||
|
||||
Reference in New Issue
Block a user