diff --git a/src/improper.cpp b/src/improper.cpp index 3476bcdb50..136e913dd0 100644 --- a/src/improper.cpp +++ b/src/improper.cpp @@ -30,6 +30,7 @@ Improper::Improper(LAMMPS *_lmp) : Pointers(_lmp) { energy = 0.0; writedata = 0; + reinitflag = 1; for (int i = 0; i < 4; i++) symmatoms[i] = 0; allocated = 0; @@ -421,3 +422,15 @@ double Improper::memory_usage() bytes += (double) comm->nthreads * maxvatom * 6 * sizeof(double); return bytes; } + +/* ----------------------------------------------------------------------- + reset all type-based improper params via init() +-------------------------------------------------------------------------- */ + +void Improper::reinit() +{ + if (!reinitflag) + error->all(FLERR, "Fix adapt interface to this improper style not supported"); + + init(); +}