git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@1034 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
@ -85,6 +85,15 @@ double RanPark::gaussian()
|
||||
return first;
|
||||
}
|
||||
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
void RanPark::reset(int seed_init)
|
||||
{
|
||||
if (seed_init <= 0) error->all("Invalid seed for Park random # generator");
|
||||
seed = seed_init;
|
||||
save = 0;
|
||||
}
|
||||
|
||||
/* ----------------------------------------------------------------------
|
||||
reset the seed based on atom position within box and ibase = caller seed
|
||||
combine 3 RNGs based on fractional position in box into one new seed
|
||||
@ -135,3 +144,10 @@ void RanPark::reset(int ibase, double *coord)
|
||||
uniform();
|
||||
uniform();
|
||||
}
|
||||
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
int RanPark::state()
|
||||
{
|
||||
return seed;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user