Merge branch 'fix-valgrind-issues' of github.com:akohlmey/lammps into fix-valgrind-issues
This commit is contained in:
@ -57,7 +57,7 @@ If *class2* is one of the dihedral hybrid styles, the same rule holds
|
||||
for specifying additional AngleTorsion (and EndBondTorsion, etc)
|
||||
coefficients either via the input script or in the data file.
|
||||
I.e. *class2* must be added to each line after the dihedral type. For
|
||||
lines in the AngleTorsion (or EndBondTorsion, etc) section of the data
|
||||
lines in the AngleTorsion (or EndBondTorsion, etc) Coeffs section of the data
|
||||
file for dihedral types that are not *class2*, you must use an
|
||||
dihedral style of *skip* as a placeholder, e.g.
|
||||
|
||||
|
||||
@ -40,13 +40,38 @@ potential with coefficients 120.0, 30 for :math:`K`, :math:`\chi_0`.
|
||||
Improper type 2 would be computed with a *cvff* potential with coefficients
|
||||
20.0, -1, 2 for K, d, and n, respectively.
|
||||
|
||||
If the improper *class2* potential is one of the hybrid styles, it
|
||||
requires additional AngleAngle coefficients be specified in the data
|
||||
file. These lines must also have an additional "class2" argument
|
||||
added after the improper type. For improper types which are assigned
|
||||
to other hybrid styles, use the style name (e.g. "harmonic")
|
||||
appropriate to that style. The AngleAngle coeffs for that improper
|
||||
type will then be ignored.
|
||||
If improper coefficients are specified in the data file read via the
|
||||
:doc:`read_data <read_data>` command, then the same rule applies.
|
||||
E.g. "harmonic" or "cvff", must be added after the improper type, for
|
||||
each line in the "Improper Coeffs" section, e.g.
|
||||
|
||||
.. parsed-literal::
|
||||
|
||||
Improper Coeffs
|
||||
|
||||
1 harmonic 120.0 30
|
||||
2 cvff 20.0 -1 2
|
||||
...
|
||||
|
||||
If *class2* is one of the improper hybrid styles, the same rule holds
|
||||
for specifying additional AngleAngle coefficients either via the input
|
||||
script or in the data file. I.e. *class2* must be added to each line
|
||||
after the improper type. For
|
||||
lines in the AngleAngle Coeffs section of the data
|
||||
file for dihedral types that are not *class2*, you must use an
|
||||
improper style of *skip* as a placeholder, e.g.
|
||||
|
||||
.. parsed-literal::
|
||||
|
||||
AngleAngle Coeffs
|
||||
|
||||
1 skip
|
||||
2 class2 0.0 0.0 0.0 115.06 130.01 115.06
|
||||
...
|
||||
|
||||
Note that it is not necessary to use the improper style *skip* in the
|
||||
input script, since AngleAngle coefficients
|
||||
need not be specified at all for improper types that are not *class2*.
|
||||
|
||||
An improper style of *none* can be specified as the second argument to
|
||||
the improper_coeff command, if you desire to turn off certain improper
|
||||
|
||||
@ -30,6 +30,7 @@ class Pair : protected Pointers {
|
||||
friend class FixOMP;
|
||||
friend class FixQEq;
|
||||
friend class PairHybrid;
|
||||
friend class PairHybridScaled;
|
||||
friend class ThrOMP;
|
||||
friend class Info;
|
||||
|
||||
|
||||
@ -569,7 +569,7 @@ void PairHybrid::init_style()
|
||||
// same style must not be used multiple times
|
||||
|
||||
for (istyle = 0; istyle < nstyles; istyle++) {
|
||||
bool is_gpu = (((PairHybrid *)styles[istyle])->suffix_flag & Suffix::GPU);
|
||||
bool is_gpu = styles[istyle]->suffix_flag & Suffix::GPU;
|
||||
if (multiple[istyle] && is_gpu)
|
||||
error->all(FLERR,"GPU package styles must not be used multiple times");
|
||||
}
|
||||
|
||||
@ -340,8 +340,7 @@ void PairHybridScaled::settings(int narg, char **arg)
|
||||
special_lj[nstyles] = special_coul[nstyles] = nullptr;
|
||||
compute_tally[nstyles] = 1;
|
||||
|
||||
if ((((PairHybridScaled *)styles[nstyles])->suffix_flag
|
||||
& (Suffix::INTEL|Suffix::GPU|Suffix::OMP)) != 0)
|
||||
if ((styles[nstyles]->suffix_flag & (Suffix::INTEL|Suffix::GPU|Suffix::OMP)) != 0)
|
||||
error->all(FLERR,"Pair style hybrid/scaled does not support "
|
||||
"accelerator styles");
|
||||
|
||||
|
||||
@ -5122,7 +5122,7 @@ int VarReader::read_scalar(char *str)
|
||||
if (n == 1) continue; // skip if blank line
|
||||
break;
|
||||
}
|
||||
memmove(str,ptr,n); // move trimmed string back
|
||||
if (n > 0) memmove(str,ptr,n); // move trimmed string back
|
||||
}
|
||||
MPI_Bcast(&n,1,MPI_INT,0,world);
|
||||
if (n == 0) return 1;
|
||||
|
||||
Reference in New Issue
Block a user