Merge pull request #495 from akohlmey/doc-fixes

Collected small updates and bugfixes
This commit is contained in:
sjplimp
2017-05-30 10:48:57 -06:00
committed by GitHub
50 changed files with 153 additions and 113 deletions

View File

@ -111,26 +111,26 @@ Coefficients parameterized by "(Fox)"_#Fox are assigned for each
atom type designating the chemical symbol and charge of each atom
type. Valid chemical symbols for compute saed are:
H: He: Li: Be: B:
C: N: O: F: Ne:
Na: Mg: Al: Si: P:
S: Cl: Ar: K: Ca:
Sc: Ti: V: Cr: Mn:
Fe: Co: Ni: Cu: Zn:
Ga: Ge: As: Se: Br:
Kr: Rb: Sr: Y: Zr:
Nb: Mo: Tc: Ru: Rh:
Pd: Ag: Cd: In: Sn:
Sb: Te: I: Xe: Cs:
Ba: La: Ce: Pr: Nd:
Pm: Sm: Eu: Gd: Tb:
Dy: Ho: Er: Tm: Yb:
Lu: Hf: Ta: W: Re:
Os: Ir: Pt: Au: Hg:
Tl: Pb: Bi: Po: At:
Rn: Fr: Ra: Ac: Th:
Pa: U: Np: Pu: Am:
Cm: Bk: Cf:tb(c=5,s=:)
H: He: Li: Be: B:
C: N: O: F: Ne:
Na: Mg: Al: Si: P:
S: Cl: Ar: K: Ca:
Sc: Ti: V: Cr: Mn:
Fe: Co: Ni: Cu: Zn:
Ga: Ge: As: Se: Br:
Kr: Rb: Sr: Y: Zr:
Nb: Mo: Tc: Ru: Rh:
Pd: Ag: Cd: In: Sn:
Sb: Te: I: Xe: Cs:
Ba: La: Ce: Pr: Nd:
Pm: Sm: Eu: Gd: Tb:
Dy: Ho: Er: Tm: Yb:
Lu: Hf: Ta: W: Re:
Os: Ir: Pt: Au: Hg:
Tl: Pb: Bi: Po: At:
Rn: Fr: Ra: Ac: Th:
Pa: U: Np: Pu: Am:
Cm: Bk: Cf:tb(c=5,s=:)
If the {echo} keyword is specified, compute saed will provide extra

View File

@ -18,6 +18,7 @@ dihedral_coeff 1 1 286.1 1 124 1 1 90.0 0 1 90.0 0
dihedral_coeff 1 3 69.3 1 93.9 1 1 90 0 1 90 0 &
49.1 0 0.00 0 1 74.4 1 0 0.00 0 &
25.2 0 0.00 0 0 0.00 0 1 48.1 1
:pre
[Description:]

View File

@ -68,7 +68,7 @@ matrix that gives canonical sampling for a given A is computed automatically.
However, the GLE framework also allow for non-equilibrium sampling, that
can be used for instance to model inexpensively zero-point energy
effects "(Ceriotti2)"_#Ceriotti2. This is achieved specifying the {noneq}
keyword followed by the name of the file that contains the static covariance
keyword followed by the name of the file that contains the static covariance
matrix for the non-equilibrium dynamics. Please note, that the covariance
matrix is expected to be given in [temperature units].

View File

@ -67,11 +67,11 @@ The Langevin forces are computed as
\(F_r'\) is a random force proportional to
\(\sqrt \{ \frac \{2\, k_B \mathtt\{Tcom\}\, m'\}
\{\mathrm dt\, \mathtt\{damp\_com\} \}
\} \). :b
\} \).
\(f_r'\) is a random force proportional to
\(\sqrt \{ \frac \{2\, k_B \mathtt\{Tdrude\}\, m'\}
\{\mathrm dt\, \mathtt\{damp\_drude\} \}
\} \). :b
\} \).
Then the real forces acting on the particles are computed from the inverse
transform:
\begin\{equation\} F = \frac M \{M'\}\, F' - f' \end\{equation\}

View File

@ -30,8 +30,8 @@ plane @ a b c x0 y0 z0 @ a*(x-x0) + b*(y-y0) + c*(z-z0) = 0 @ A plane with norma
plane_wiggle @ a w @ z - a*sin(w*x) = 0 @ A plane with a sinusoidal modulation on z along x.
sphere @ R @ x^2 + y^2 + z^2 - R^2 = 0 @ A sphere of radius R
supersphere @ R q @ | x |^q + | y |^q + | z |^q - R^q = 0 @ A supersphere of hyperradius R
spine @ a, A, B, B2, c @ -(x^2 + y^2)*(a^2 - z^2/f(z)^2)*(1 + (A*sin(g(z)*z^2))^4), f(z) = c if z > 0, 1 otherwise; g(z) = B if z > 0, B2 otherwise @ An approximation to a dendtritic spine
spine_two @ a, A, B, B2, c @ -(x^2 + y^2)*(a^2 - z^2/f(z)^2)*(1 + (A*sin(g(z)*z^2))^2), f(z) = c if z > 0, 1 otherwise; g(z) = B if z > 0, B2 otherwise @ Another approximation to a dendtritic spine
spine @ a, A, B, B2, c @ -(x^2 + y^2) + (a^2 - z^2/f(z)^2)*(1 + (A*sin(g(z)*z^2))^4), f(z) = c if z > 0, 1 otherwise; g(z) = B if z > 0, B2 otherwise @ An approximation to a dendtritic spine
spine_two @ a, A, B, B2, c @ -(x^2 + y^2) + (a^2 - z^2/f(z)^2)*(1 + (A*sin(g(z)*z^2))^2), f(z) = c if z > 0, 1 otherwise; g(z) = B if z > 0, B2 otherwise @ Another approximation to a dendtritic spine
thylakoid @ wB LB lB @ Various, see "(Paquay)"_#Paquay1 @ A model grana thylakoid consisting of two block-like compartments connected by a bridge of width wB, length LB and taper length lB
torus @ R r @ (R - sqrt( x^2 + y^2 ) )^2 + z^2 - r^2 @ A torus with large radius R and small radius r, centered on (0,0,0) :tb(s=@)

View File

@ -574,9 +574,9 @@ is used. If it is not used, you must invoke the package intel
command in your input script or or via the "-pk intel" "command-line
switch"_Section_start.html#start_7.
For the KOKKOS package, the option defaults neigh = full, neigh/qeq
= full, newton = off, binsize = 0.0, and comm = device. These settings
are made automatically by the required "-k on" "command-line
For the KOKKOS package, the option defaults neigh = full,
neigh/qeq = full, newton = off, binsize = 0.0, and comm = device.
These settings are made automatically by the required "-k on" "command-line
switch"_Section_start.html#start_7. You can change them bu using the
package kokkos command in your input script or via the "-pk kokkos"
"command-line switch"_Section_start.html#start_7.

View File

@ -26,7 +26,7 @@ args = list of arguments for a particular style :ul
{morse/smooth/linear} args = cutoff
cutoff = global cutoff for Morse interactions (distance units)
{morse/soft} args = n lf cutoff
n = soft-core parameter
n = soft-core parameter
lf = transformation range is lf < lambda < 1
cutoff = global cutoff for Morse interactions (distance units)
:pre
@ -36,7 +36,7 @@ args = list of arguments for a particular style :ul
pair_style morse 2.5
pair_style morse/smooth/linear 2.5
pair_coeff * * 100.0 2.0 1.5
pair_coeff 1 1 100.0 2.0 1.5 3.0
pair_coeff 1 1 100.0 2.0 1.5 3.0 :pre
pair_style morse/soft 4 0.9 10.0
pair_coeff * * 100.0 2.0 1.5 1.0

View File

@ -74,7 +74,7 @@ placeholders for atom types that will be used with other potentials.
The python potential file has to start with the following code:
from __future__ import print_function
#
class LAMMPSPairPotential(object):
def __init__(self):
self.pmap=dict()
@ -163,9 +163,10 @@ pair_write 1 1 2000 rsq 0.01 2.5 lj1_lj2.table lj :pre
Note that it is strongly recommended to try to [delete] the potential
table file before generating it. Since the {pair_write} command will
always append to a table file, which pair style table will use the
first match. Thus when changing the potential function in the python
class, the table pair style will still read the old variant.
always [append] to a table file, while pair style table will use the
[first match]. Thus when changing the potential function in the python
class, the table pair style will still read the old variant unless the
table file is first deleted.
After switching the pair style to {table}, the potential tables need
to be assigned to the LAMMPS atom types like this:

View File

@ -10,7 +10,8 @@ pair_style snap command :h3
[Syntax:]
pair_style snap :pre
pair_style snap
:pre
[Examples:]
@ -19,11 +20,11 @@ pair_coeff * * InP.snapcoeff In P InP.snapparam In In P P :pre
[Description:]
Style {snap} computes interactions
Pair style {snap} computes interactions
using the spectral neighbor analysis potential (SNAP)
"(Thompson)"_#Thompson20142. Like the GAP framework of Bartok et al.
"(Bartok2010)"_#Bartok20102, "(Bartok2013)"_#Bartok2013
it uses bispectrum components
which uses bispectrum components
to characterize the local neighborhood of each atom
in a very general way. The mathematical definition of the
bispectrum calculation used by SNAP is identical

View File

@ -14,7 +14,7 @@ pair_style zero cutoff {nocoeff} :pre
zero = style name of this pair style
cutoff = global cutoff (distance units)
nocoeff = ignore all pair_coeff parameters (optional) :l
nocoeff = ignore all pair_coeff parameters (optional) :ul
[Examples:]

View File

@ -10,6 +10,7 @@ PyLammps Tutorial :h1
<!-- RST
.. contents::
END_RST -->
Overview :h2

View File

@ -82,6 +82,7 @@ PPPM::PPPM(LAMMPS *lmp, int narg, char **arg) : KSpace(lmp, narg, arg),
pppmflag = 1;
group_group_enable = 1;
triclinic = domain->triclinic;
accuracy_relative = fabs(force->numeric(FLERR,arg[0]));

View File

@ -161,6 +161,8 @@ void PairComb3::allocate()
void PairComb3::settings(int narg, char **arg)
{
if (narg != 1) error->all(FLERR,"Illegal pair_style command");
if (strcmp(arg[0],"polar_on") == 0) {
pol_flag = 1;
if (comm->me == 0 && screen) fprintf(screen,

View File

@ -429,6 +429,7 @@ double PairEAM::init_one(int i, int j)
// for funcfl could be multiple files
// for setfl or fs, just one file
if (setflag[i][j] == 0) scale[i][j] = 1.0;
scale[j][i] = scale[i][j];
if (funcfl) {

View File

@ -93,9 +93,9 @@ void PairDSMC::compute(int eflag, int vflag)
int ycell = static_cast<int>((x[i][1] - domain->boxlo[1])/celly);
int zcell = static_cast<int>((x[i][2] - domain->boxlo[2])/cellz);
if ((xcell < 0) or (xcell > ncellsx-1) or
(ycell < 0) or (ycell > ncellsy-1) or
(zcell < 0) or (zcell > ncellsz-1)) continue;
if ((xcell < 0) || (xcell > ncellsx-1) ||
(ycell < 0) || (ycell > ncellsy-1) ||
(zcell < 0) || (zcell > ncellsz-1)) continue;
int icell = xcell + ycell*ncellsx + zcell*ncellsx*ncellsy;
itype = type[i];
@ -146,7 +146,7 @@ void PairDSMC::compute(int eflag, int vflag)
double num_of_collisions_double = number_of_A * number_of_B *
weighting * Vs_max * update->dt / vol;
if ((itype == jtype) and number_of_B)
if ((itype == jtype) && number_of_B)
num_of_collisions_double *=
0.5 * double(number_of_B - 1) / double(number_of_B);
@ -161,8 +161,8 @@ void PairDSMC::compute(int eflag, int vflag)
// perform collisions on pairs of particles in icell
for (int k = 0; k < num_of_collisions; k++) {
if ((number_of_A < 1) or (number_of_B < 1)) break;
if ((itype == jtype) and (number_of_A < 2)) break;
if ((number_of_A < 1) || (number_of_B < 1)) break;
if ((itype == jtype) && (number_of_A < 2)) break;
int ith_A = static_cast<int>(random->uniform()*number_of_A);
int jth_B = static_cast<int>(random->uniform()*number_of_B);
int i = particle_list[itype][ith_A];

View File

@ -110,18 +110,18 @@ void FixNVESphereOMP::initial_integrate(int vflag)
matrix Q, Q_temp, R;
if (mask[i] & groupbit && mu[i][3] > 0.0) {
// Construct Q from dipole:
// Q is the rotation matrix from space frame to body frame
// i.e. v_b = Q.v_s
// Define mu to lie along the z axis in the body frame
// We take the unit dipole to avoid getting a scaling matrix
const double inv_len_mu = 1.0/mu[i][3];
a[0] = mu[i][0]*inv_len_mu;
a[1] = mu[i][1]*inv_len_mu;
a[2] = mu[i][2]*inv_len_mu;
// v = a x [0 0 1] - cross product of mu in space and body frames
// s = |v|
// c = a.[0 0 1] = a[2]
@ -130,11 +130,11 @@ void FixNVESphereOMP::initial_integrate(int vflag)
// -v[1] v[0] 0 ]
// then
// Q = I + vx + vx^2 * (1-c)/s^2
const double s2 = a[0]*a[0] + a[1]*a[1];
if (s2 != 0.0){ // i.e. the vectors are not parallel
const double scale = (1.0 - a[2])/s2;
Q[0][0] = 1.0 - scale*a[0]*a[0]; Q[0][1] = -scale*a[0]*a[1]; Q[0][2] = -a[0];
Q[1][0] = -scale*a[0]*a[1]; Q[1][1] = 1.0 - scale*a[1]*a[1]; Q[1][2] = -a[1];
Q[2][0] = a[0]; Q[2][1] = a[1]; Q[2][2] = 1.0 - scale*(a[0]*a[0] + a[1]*a[1]);
@ -143,62 +143,62 @@ void FixNVESphereOMP::initial_integrate(int vflag)
Q[1][0] = 0.0; Q[1][1] = 1.0/a[2]; Q[1][2] = 0.0;
Q[2][0] = 0.0; Q[2][1] = 0.0; Q[2][2] = 1.0/a[2];
}
// Local copy of this particle's angular velocity (in space frame)
w[0] = omega[i][0]; w[1] = omega[i][1]; w[2] = omega[i][2];
// Transform omega into body frame: w_temp= Q.w
matvec(Q,w,w_temp);
// Construct rotation R1
BuildRxMatrix(R, dtf/force->ftm2v*w_temp[0]);
// Apply R1 to w: w = R.w_temp
matvec(R,w_temp,w);
// Apply R1 to Q: Q_temp = R^T.Q
transpose_times3(R,Q,Q_temp);
// Construct rotation R2
BuildRyMatrix(R, dtf/force->ftm2v*w[1]);
// Apply R2 to w: w_temp = R.w
matvec(R,w,w_temp);
// Apply R2 to Q: Q = R^T.Q_temp
transpose_times3(R,Q_temp,Q);
// Construct rotation R3
BuildRzMatrix(R, 2.0*dtf/force->ftm2v*w_temp[2]);
// Apply R3 to w: w = R.w_temp
matvec(R,w_temp,w);
// Apply R3 to Q: Q_temp = R^T.Q
transpose_times3(R,Q,Q_temp);
// Construct rotation R4
BuildRyMatrix(R, dtf/force->ftm2v*w[1]);
// Apply R4 to w: w_temp = R.w
matvec(R,w,w_temp);
// Apply R4 to Q: Q = R^T.Q_temp
transpose_times3(R,Q_temp,Q);
// Construct rotation R5
BuildRxMatrix(R, dtf/force->ftm2v*w_temp[0]);
// Apply R5 to w: w = R.w_temp
matvec(R,w_temp,w);
// Apply R5 to Q: Q_temp = R^T.Q
transpose_times3(R,Q,Q_temp);
// Transform w back into space frame w_temp = Q^T.w
transpose_matvec(Q_temp,w,w_temp);
omega[i][0] = w_temp[0]; omega[i][1] = w_temp[1]; omega[i][2] = w_temp[2];
// Set dipole according to updated Q: mu = Q^T.[0 0 1] * |mu|
mu[i][0] = Q_temp[2][0] * mu[i][3];
mu[i][1] = Q_temp[2][1] * mu[i][3];

View File

@ -15,7 +15,7 @@
NPairStyle(full/bin/ghost/omp,
NPairFullBinGhostOmp,
NP_FULL | NP_BIN | NP_GHOST | NP_OMP | NP_NEWTON | NP_NEWTOFF |
NP_FULL | NP_BIN | NP_GHOST | NP_OMP | NP_NEWTON | NP_NEWTOFF |
NP_ORTHO | NP_TRI)
#else

View File

@ -15,7 +15,7 @@
NPairStyle(full/bin/omp,
NPairFullBinOmp,
NP_FULL | NP_BIN | NP_OMP | NP_NEWTON | NP_NEWTOFF |
NP_FULL | NP_BIN | NP_OMP | NP_NEWTON | NP_NEWTOFF |
NP_ORTHO | NP_TRI)
#else

View File

@ -15,7 +15,7 @@
NPairStyle(full/multi/omp,
NPairFullMultiOmp,
NP_FULL | NP_MULTI | NP_OMP |
NP_FULL | NP_MULTI | NP_OMP |
NP_NEWTON | NP_NEWTOFF | NP_ORTHO | NP_TRI)
#else

View File

@ -15,7 +15,7 @@
NPairStyle(full/nsq/ghost/omp,
NPairFullNsqGhostOmp,
NP_FULL | NP_NSQ | NP_GHOST | NP_OMP | NP_NEWTON | NP_NEWTOFF |
NP_FULL | NP_NSQ | NP_GHOST | NP_OMP | NP_NEWTON | NP_NEWTOFF |
NP_ORTHO | NP_TRI)
#else

View File

@ -15,7 +15,7 @@
NPairStyle(full/nsq/omp,
NPairFullNsqOmp,
NP_FULL | NP_NSQ | NP_OMP | NP_NEWTON | NP_NEWTOFF |
NP_FULL | NP_NSQ | NP_OMP | NP_NEWTON | NP_NEWTOFF |
NP_ORTHO | NP_TRI)
#else

View File

@ -26,7 +26,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfBinNewtoffGhostOmp::NPairHalfBinNewtoffGhostOmp(LAMMPS *lmp) :
NPairHalfBinNewtoffGhostOmp::NPairHalfBinNewtoffGhostOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -15,7 +15,7 @@
NPairStyle(half/bin/newtoff/ghost/omp,
NPairHalfBinNewtoffGhostOmp,
NP_HALF | NP_BIN | NP_NEWTOFF | NP_GHOST | NP_OMP |
NP_HALF | NP_BIN | NP_NEWTOFF | NP_GHOST | NP_OMP |
NP_ORTHO | NP_TRI)
#else

View File

@ -26,7 +26,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfMultiNewtonTriOmp::NPairHalfMultiNewtonTriOmp(LAMMPS *lmp) :
NPairHalfMultiNewtonTriOmp::NPairHalfMultiNewtonTriOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -27,7 +27,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfNsqNewtoffGhostOmp::NPairHalfNsqNewtoffGhostOmp(LAMMPS *lmp) :
NPairHalfNsqNewtoffGhostOmp::NPairHalfNsqNewtoffGhostOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -15,7 +15,7 @@
NPairStyle(half/nsq/newtoff/ghost/omp,
NPairHalfNsqNewtoffGhostOmp,
NP_HALF | NP_NSQ | NP_NEWTOFF | NP_GHOST | NP_OMP |
NP_HALF | NP_NSQ | NP_NEWTOFF | NP_GHOST | NP_OMP |
NP_ORTHO | NP_TRI)
#else

View File

@ -26,7 +26,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfRespaBinNewtoffOmp::NPairHalfRespaBinNewtoffOmp(LAMMPS *lmp) :
NPairHalfRespaBinNewtoffOmp::NPairHalfRespaBinNewtoffOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -15,7 +15,7 @@
NPairStyle(half/respa/bin/newtoff/omp,
NPairHalfRespaBinNewtoffOmp,
NP_HALF | NP_RESPA | NP_BIN | NP_NEWTOFF | NP_OMP |
NP_HALF | NP_RESPA | NP_BIN | NP_NEWTOFF | NP_OMP |
NP_ORTHO | NP_TRI)
#else

View File

@ -26,7 +26,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfRespaBinNewtonOmp::NPairHalfRespaBinNewtonOmp(LAMMPS *lmp) :
NPairHalfRespaBinNewtonOmp::NPairHalfRespaBinNewtonOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -26,7 +26,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfRespaBinNewtonTriOmp::NPairHalfRespaBinNewtonTriOmp(LAMMPS *lmp) :
NPairHalfRespaBinNewtonTriOmp::NPairHalfRespaBinNewtonTriOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -27,7 +27,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfRespaNsqNewtoffOmp::NPairHalfRespaNsqNewtoffOmp(LAMMPS *lmp) :
NPairHalfRespaNsqNewtoffOmp::NPairHalfRespaNsqNewtoffOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -15,7 +15,7 @@
NPairStyle(half/respa/nsq/newtoff/omp,
NPairHalfRespaNsqNewtoffOmp,
NP_HALF | NP_RESPA | NP_NSQ | NP_NEWTOFF | NP_OMP |
NP_HALF | NP_RESPA | NP_NSQ | NP_NEWTOFF | NP_OMP |
NP_ORTHO | NP_TRI)
#else

View File

@ -27,7 +27,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfRespaNsqNewtonOmp::NPairHalfRespaNsqNewtonOmp(LAMMPS *lmp) :
NPairHalfRespaNsqNewtonOmp::NPairHalfRespaNsqNewtonOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -15,7 +15,7 @@
NPairStyle(half/respa/nsq/newton/omp,
NPairHalfRespaNsqNewtonOmp,
NP_HALF | NP_RESPA | NP_NSQ | NP_NEWTON | NP_OMP |
NP_HALF | NP_RESPA | NP_NSQ | NP_NEWTON | NP_OMP |
NP_ORTHO | NP_TRI)
#else

View File

@ -28,7 +28,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfSizeBinNewtoffOmp::NPairHalfSizeBinNewtoffOmp(LAMMPS *lmp) :
NPairHalfSizeBinNewtoffOmp::NPairHalfSizeBinNewtoffOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -15,7 +15,7 @@
NPairStyle(half/size/bin/newtoff/omp,
NPairHalfSizeBinNewtoffOmp,
NP_HALF | NP_SIZE | NP_BIN | NP_NEWTOFF | NP_OMP |
NP_HALF | NP_SIZE | NP_BIN | NP_NEWTOFF | NP_OMP |
NP_ORTHO | NP_TRI)
#else

View File

@ -28,7 +28,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfSizeBinNewtonOmp::NPairHalfSizeBinNewtonOmp(LAMMPS *lmp) :
NPairHalfSizeBinNewtonOmp::NPairHalfSizeBinNewtonOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------
@ -202,7 +202,7 @@ void NPairHalfSizeBinNewtonOmp::build(NeighList *list)
nn += dnum;
}
}
n++;
}
}

View File

@ -26,7 +26,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfSizeBinNewtonTriOmp::NPairHalfSizeBinNewtonTriOmp(LAMMPS *lmp) :
NPairHalfSizeBinNewtonTriOmp::NPairHalfSizeBinNewtonTriOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -29,7 +29,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfSizeNsqNewtoffOmp::NPairHalfSizeNsqNewtoffOmp(LAMMPS *lmp) :
NPairHalfSizeNsqNewtoffOmp::NPairHalfSizeNsqNewtoffOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -15,7 +15,7 @@
NPairStyle(half/size/nsq/newtoff/omp,
NPairHalfSizeNsqNewtoffOmp,
NP_HALF | NP_SIZE | NP_NSQ | NP_NEWTOFF | NP_OMP |
NP_HALF | NP_SIZE | NP_NSQ | NP_NEWTOFF | NP_OMP |
NP_ORTHO | NP_TRI)
#else

View File

@ -29,7 +29,7 @@ using namespace LAMMPS_NS;
/* ---------------------------------------------------------------------- */
NPairHalfSizeNsqNewtonOmp::NPairHalfSizeNsqNewtonOmp(LAMMPS *lmp) :
NPairHalfSizeNsqNewtonOmp::NPairHalfSizeNsqNewtonOmp(LAMMPS *lmp) :
NPair(lmp) {}
/* ----------------------------------------------------------------------

View File

@ -15,7 +15,7 @@
NPairStyle(half/size/nsq/newton/omp,
NPairHalfSizeNsqNewtonOmp,
NP_HALF | NP_SIZE | NP_NSQ | NP_NEWTON | NP_OMP |
NP_HALF | NP_SIZE | NP_NSQ | NP_NEWTON | NP_OMP |
NP_ORTHO | NP_TRI)
#else

View File

@ -15,9 +15,13 @@
NPairStyle(halffull/newtoff/omp,
NPairHalffullNewtoffOmp,
NP_HALF_FULL | NP_NEWTOFF | NP_OMP | NP_HALF |
NP_NSQ | NP_BIN | NP_MULTI | NP_ORTHO | NP_TRI)
NP_HALF_FULL | NP_NEWTOFF | NP_NSQ | NP_BIN | NP_MULTI | NP_HALF |
NP_ORTHO | NP_TRI |NP_OMP)
NPairStyle(halffull/newtoff/skip/omp,
NPairHalffullNewtoffOmp,
NP_HALF_FULL | NP_NEWTOFF | NP_NSQ | NP_BIN | NP_MULTI | NP_HALF |
NP_ORTHO | NP_TRI | NP_SKIP | NP_OMP)
#else
#ifndef LMP_NPAIR_HALFFULL_NEWTOFF_OMP_H

View File

@ -15,8 +15,13 @@
NPairStyle(halffull/newton/omp,
NPairHalffullNewtonOmp,
NP_HALF_FULL | NP_NEWTON | NP_OMP | NP_HALF |
NP_NSQ | NP_BIN | NP_MULTI | NP_ORTHO | NP_TRI)
NP_HALF_FULL | NP_NEWTON | NP_HALF | NP_NSQ | NP_BIN | NP_MULTI |
NP_ORTHO | NP_TRI| NP_OMP)
NPairStyle(halffull/newton/skip/omp,
NPairHalffullNewtonOmp,
NP_HALF_FULL | NP_NEWTON | NP_HALF | NP_NSQ | NP_BIN | NP_MULTI |
NP_ORTHO | NP_TRI | NP_SKIP | NP_OMP)
#else

View File

@ -1907,7 +1907,7 @@ double PairAIREBOOMP::bondorderLJ_thr(int i, int j, double rij[3], double rijmag
realrij[0] = x[atomi][0] - x[atomj][0];
realrij[1] = x[atomi][1] - x[atomj][1];
realrij[2] = x[atomi][2] - x[atomj][2];
realrijmag = sqrt(realrij[0] * realrij[0] + realrij[1] * realrij[1]
realrijmag = sqrt(realrij[0] * realrij[0] + realrij[1] * realrij[1]
+ realrij[2] * realrij[2]);
REBO_neighs = REBO_firstneigh[i];

View File

@ -44,7 +44,7 @@ using namespace MathConst;
/* ---------------------------------------------------------------------- */
PairLJCutTholeLongOMP::PairLJCutTholeLongOMP(LAMMPS *lmp) :
PairLJCutTholeLongOMP::PairLJCutTholeLongOMP(LAMMPS *lmp) :
PairLJCutTholeLong(lmp), ThrOMP(lmp, THR_PAIR)
{
suffix_flag |= Suffix::OMP;
@ -108,9 +108,9 @@ void PairLJCutTholeLongOMP::eval(int iifrom, int iito, ThrData * const thr)
const tagint * _noalias const drudeid = fix_drude->drudeid;
double xtmp,ytmp,ztmp,delx,dely,delz,fxtmp,fytmp,fztmp;
const int nlocal = atom->nlocal;
int j,jj,jnum,jtype,itable;
double ecoul,fpair,evdwl;
double r,rsq,r2inv,forcecoul,factor_coul,forcelj,factor_lj,r6inv;
@ -137,7 +137,7 @@ void PairLJCutTholeLongOMP::eval(int iifrom, int iito, ThrData * const thr)
const double * _noalias const lj2i = lj2[itype];
const double * _noalias const lj3i = lj3[itype];
const double * _noalias const lj4i = lj4[itype];
xtmp = x[i].x;
ytmp = x[i].y;
ztmp = x[i].z;

View File

@ -500,8 +500,16 @@ void FixReaxCSpecies::Output_ReaxC_Bonds(bigint ntimestep, FILE *fp)
AtomCoord FixReaxCSpecies::chAnchor(AtomCoord in1, AtomCoord in2)
{
if (in1.x <= in2.x)
if (in1.x < in2.x)
return in1;
else if (in1.x == in2.x) {
if (in1.y < in2.y)
return in1;
else if (in1.y == in2.y) {
if (in1.z < in2.z)
return in1;
}
}
return in2;
}

View File

@ -271,9 +271,15 @@ void DisplaceAtoms::command(int narg, char **arg)
int *body = atom->body;
int *mask = atom->mask;
int nlocal = atom->nlocal;
imageint *image = atom->image;
for (i = 0; i < nlocal; i++) {
if (mask[i] & groupbit) {
// unwrap coordinate and reset image flags accordingly
domain->unmap(x[i],image[i]);
image[i] = ((imageint) IMGMAX << IMG2BITS) |
((imageint) IMGMAX << IMGBITS) | IMGMAX;
d[0] = x[i][0] - point[0];
d[1] = x[i][1] - point[1];
d[2] = x[i][2] - point[2];

View File

@ -389,7 +389,7 @@ void FixShearHistory::pre_exchange_newton()
maxtouch = 0;
for (i = 0; i < nlocal_neigh; i++) maxtouch = MAX(maxtouch,npartner[i]);
comm->maxexchange_fix = MAX(comm->maxexchange_fix,4*maxtouch+1);
comm->maxexchange_fix = MAX(comm->maxexchange_fix,(dnum+1)*maxtouch+1);
// zero npartner values from previous nlocal_neigh to current nlocal
@ -590,7 +590,7 @@ int FixShearHistory::pack_reverse_comm_size(int n, int first)
last = first + n;
for (i = first; i < last; i++)
m += 1 + 4*npartner[i];
m += 1 + (dnum+1)*npartner[i];
return m;
}

View File

@ -277,12 +277,21 @@ void lammps_commands_string(void *ptr, char *str)
BEGIN_CAPTURE
{
char *ptr = strtok(copy,"\n");
if (ptr) concatenate_lines(ptr);
while (ptr) {
lmp->input->one(ptr);
ptr = strtok(NULL,"\n");
if (ptr) concatenate_lines(ptr);
char *ptr = copy;
for (int i=0; i < n-1; ++i) {
// handle continuation character as last character in line or string
if ((copy[i] == '&') && (copy[i+1] == '\n'))
copy[i+1] = copy[i] = ' ';
else if ((copy[i] == '&') && (copy[i+1] == '\0'))
copy[i] = ' ';
if (copy[i] == '\n') {
copy[i] = '\0';
lmp->input->one(ptr);
ptr = copy + i+1;
} else if (copy[i+1] == '\0')
lmp->input->one(ptr);
}
}
END_CAPTURE