git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@8186 f3b2605a-c512-4ea7-a41b-209d697bcdaa

This commit is contained in:
sjplimp 2012-05-25 14:33:24 +00:00
parent 233267cde6
commit c27e7ac989
6 changed files with 17 additions and 4 deletions

View File

@ -461,7 +461,8 @@ void PairLJCutCoulLong::compute_outer(int eflag, int vflag)
rsw = (r - cut_in_off)/cut_in_diff;
forcecoul += prefactor*rsw*rsw*(3.0 - 2.0*rsw);
if (factor_coul < 1.0)
forcecoul -= (1.0-factor_coul)*prefactor*rsw*rsw*(3.0 - 2.0*rsw);
forcecoul -=
(1.0-factor_coul)*prefactor*rsw*rsw*(3.0 - 2.0*rsw);
} else {
forcecoul += prefactor;
if (factor_coul < 1.0)
@ -615,7 +616,8 @@ void PairLJCutCoulLong::settings(int narg, char **arg)
void PairLJCutCoulLong::coeff(int narg, char **arg)
{
if (narg < 4 || narg > 5) error->all(FLERR,"Incorrect args for pair coefficients");
if (narg < 4 || narg > 5)
error->all(FLERR,"Incorrect args for pair coefficients");
if (!allocated) allocate();
int ilo,ihi,jlo,jhi;

View File

@ -33,7 +33,7 @@ class PairLJCutCoulLong : public Pair {
void coeff(int, char **);
virtual void init_style();
void init_list(int, class NeighList *);
double init_one(int, int);
virtual double init_one(int, int);
void write_restart(FILE *);
void read_restart(FILE *);
virtual void write_restart_settings(FILE *);

View File

@ -361,6 +361,9 @@ void PairLJCutCoulLongTIP4P::compute(int eflag, int vflag)
}
}
}
//if (comm->me == 0 && update->ntimestep == update->laststep)
// printf("Count %ld %d\n",update->ntimestep,count);
}
/* ----------------------------------------------------------------------
@ -397,6 +400,8 @@ void PairLJCutCoulLongTIP4P::settings(int narg, char **arg)
void PairLJCutCoulLongTIP4P::init_style()
{
//count = 0;
if (atom->tag_enable == 0)
error->all(FLERR,"Pair style lj/cut/coul/long/tip4p requires atom IDs");
if (!force->newton_pair)
@ -505,6 +510,8 @@ void PairLJCutCoulLongTIP4P::find_M(int i, int &iH1, int &iH2, double *xM)
xM[0] = x[i][0] + alpha * 0.5 * (delx1 + delx2);
xM[1] = x[i][1] + alpha * 0.5 * (dely1 + dely2);
xM[2] = x[i][2] + alpha * 0.5 * (delz1 + delz2);
//count++;
}
/* ---------------------------------------------------------------------- */

View File

@ -40,6 +40,8 @@ class PairLJCutCoulLongTIP4P : public PairLJCutCoulLong {
double alpha; // geometric constraint parameter for TIP4P
void find_M(int, int &, int &, double *);
//int count;
};
}

View File

@ -381,7 +381,8 @@ void Lattice::setup_transform()
primitive[0][1]*primitive[1][0]*primitive[2][2] -
primitive[0][2]*primitive[1][1]*primitive[2][0];
if (determinant == 0.0) error->all(FLERR,"Degenerate lattice primitive vectors");
if (determinant == 0.0)
error->all(FLERR,"Degenerate lattice primitive vectors");
priminv[0][0] = (primitive[1][1]*primitive[2][2] -
primitive[1][2]*primitive[2][1]) / determinant;

View File

@ -88,6 +88,7 @@ class Modify : protected Pointers {
void modify_compute(int, char **);
void delete_compute(const char *);
int find_compute(const char *);
void clearstep_compute();
void addstep_compute(bigint);
void addstep_compute_all(bigint);