git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@15364 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
@ -1931,6 +1931,17 @@ void Neighbor::set(int narg, char **arg)
|
|||||||
if (style == MULTI && lmp->citeme) lmp->citeme->add(cite_neigh_multi);
|
if (style == MULTI && lmp->citeme) lmp->citeme->add(cite_neigh_multi);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* ----------------------------------------------------------------------
|
||||||
|
reset timestamps in all NeighList classes
|
||||||
|
so that neighbor lists will rebuild properly with timestep change
|
||||||
|
------------------------------------------------------------------------- */
|
||||||
|
|
||||||
|
void Neighbor::reset_timestep(bigint ntimestep)
|
||||||
|
{
|
||||||
|
for (int i = 0; i < nlist; i++)
|
||||||
|
lists[i]->last_build = -1;
|
||||||
|
}
|
||||||
|
|
||||||
/* ----------------------------------------------------------------------
|
/* ----------------------------------------------------------------------
|
||||||
modify parameters of the pair-wise neighbor build
|
modify parameters of the pair-wise neighbor build
|
||||||
------------------------------------------------------------------------- */
|
------------------------------------------------------------------------- */
|
||||||
|
|||||||
@ -86,6 +86,7 @@ class Neighbor : protected Pointers {
|
|||||||
void build_one(class NeighList *list,
|
void build_one(class NeighList *list,
|
||||||
int preflag=0); // create a single one-time neigh list
|
int preflag=0); // create a single one-time neigh list
|
||||||
void set(int, char **); // set neighbor style and skin distance
|
void set(int, char **); // set neighbor style and skin distance
|
||||||
|
void reset_timestep(bigint); // reset of timestep counter
|
||||||
void modify_params(int, char**); // modify parameters that control builds
|
void modify_params(int, char**); // modify parameters that control builds
|
||||||
bigint memory_usage();
|
bigint memory_usage();
|
||||||
int exclude_setting();
|
int exclude_setting();
|
||||||
|
|||||||
@ -448,10 +448,9 @@ void Update::reset_timestep(bigint newstep)
|
|||||||
for (int i = 0; i < modify->ncompute; i++)
|
for (int i = 0; i < modify->ncompute; i++)
|
||||||
if (modify->compute[i]->timeflag) modify->compute[i]->clearstep();
|
if (modify->compute[i]->timeflag) modify->compute[i]->clearstep();
|
||||||
|
|
||||||
// set last_build of all neigh lists to -1 to force rebuild
|
// Neighbor Bin/Stencil/Pair classes store timestamps that need to be cleared
|
||||||
|
|
||||||
for (int i = 0; i < neighbor->nlist; i++)
|
neighbor->reset_timestep(ntimestep);
|
||||||
neighbor->lists[i]->last_build = -1;
|
|
||||||
|
|
||||||
// NOTE: 7Jun12, adding rerun command, don't think this is required
|
// NOTE: 7Jun12, adding rerun command, don't think this is required
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user