mirror of https://github.com/lammps/lammps.git
git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@216 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
parent
2b2eef7310
commit
9c95030827
|
@ -337,8 +337,10 @@ void MinCG::iterate(int n)
|
||||||
void MinCG::setup_vectors()
|
void MinCG::setup_vectors()
|
||||||
{
|
{
|
||||||
ndof = 3 * atom->nlocal;
|
ndof = 3 * atom->nlocal;
|
||||||
g = ((FixMinimize *) modify->fix[ifix_minimize])->gradient[0];
|
if (ndof) g = ((FixMinimize *) modify->fix[ifix_minimize])->gradient[0];
|
||||||
h = ((FixMinimize *) modify->fix[ifix_minimize])->searchdir[0];
|
else g = NULL;
|
||||||
|
if (ndof) h = ((FixMinimize *) modify->fix[ifix_minimize])->searchdir[0];
|
||||||
|
else h = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ----------------------------------------------------------------------
|
/* ----------------------------------------------------------------------
|
||||||
|
|
Loading…
Reference in New Issue