Added atom map into example, enforce atom map added to fix_numdiff, added error statement to fix_numdiff.h

This commit is contained in:
Sievers
2020-03-09 10:33:04 -06:00
parent 606eaf61f7
commit 903e33d86e
3 changed files with 8 additions and 0 deletions

View File

@ -72,6 +72,9 @@ FixNumDiff::FixNumDiff(LAMMPS *lmp, int narg, char **arg) :
temp_x = NULL;
temp_f = NULL;
if (atom->map_style == 0)
error->all(FLERR,"Fix_numdiff requires an atom map, see atom_modify");
// perform initial allocation of atom-based arrays
// zero numdiff_forces since dump may access it on timestep 0
// zero numdiff_forces since a variable may access it before first run