git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@2693 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
@ -548,7 +548,7 @@ int DumpCustom::count()
|
|||||||
dchoose[i] = (image[i] >> 10 & 1023) - 512;
|
dchoose[i] = (image[i] >> 10 & 1023) - 512;
|
||||||
ptr = dchoose;
|
ptr = dchoose;
|
||||||
nstride = 1;
|
nstride = 1;
|
||||||
} else if (thresh_array[ithresh] == IX) {
|
} else if (thresh_array[ithresh] == IZ) {
|
||||||
int *image = atom->image;
|
int *image = atom->image;
|
||||||
for (i = 0; i < nlocal; i++)
|
for (i = 0; i < nlocal; i++)
|
||||||
dchoose[i] = (image[i] >> 20) - 512;
|
dchoose[i] = (image[i] >> 20) - 512;
|
||||||
|
|||||||
@ -169,7 +169,6 @@ void MinCG::run()
|
|||||||
// normalize energy if thermo PE does
|
// normalize energy if thermo PE does
|
||||||
|
|
||||||
setup();
|
setup();
|
||||||
setup_vectors();
|
|
||||||
|
|
||||||
// setup any extra dof due to fixes
|
// setup any extra dof due to fixes
|
||||||
// can't be done until now b/c update init() comes before modify init()
|
// can't be done until now b/c update init() comes before modify init()
|
||||||
@ -807,7 +806,7 @@ int MinCG::linemin_quadratic(int n, double *x, double *dir,
|
|||||||
}
|
}
|
||||||
|
|
||||||
// check if ready for quadratic projection, equivalent to secant method
|
// check if ready for quadratic projection, equivalent to secant method
|
||||||
// alpha0 = projected alpha, perform step, exit with success
|
// alpha0 = projected alpha
|
||||||
|
|
||||||
relerr = fabs(1.0+(0.5*alpha*(alpha-alphaprev)*(fh+fhprev)-eng)/engprev);
|
relerr = fabs(1.0+(0.5*alpha*(alpha-alphaprev)*(fh+fhprev)-eng)/engprev);
|
||||||
alpha0 = alpha - (alpha-alphaprev)*fh/delfh;
|
alpha0 = alpha - (alpha-alphaprev)*fh/delfh;
|
||||||
@ -825,11 +824,9 @@ int MinCG::linemin_quadratic(int n, double *x, double *dir,
|
|||||||
|
|
||||||
de_ideal = -BACKTRACK_SLOPE*alpha0*fdotdirall;
|
de_ideal = -BACKTRACK_SLOPE*alpha0*fdotdirall;
|
||||||
de = eng - eoriginal;
|
de = eng - eoriginal;
|
||||||
if (de <= de_ideal || de_ideal >= -IDEAL_TOL) {
|
if (de <= de_ideal || de_ideal >= -IDEAL_TOL) return 0;
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Drop back from alpha0 to alpha
|
// drop back from alpha0 to alpha
|
||||||
|
|
||||||
if (nextra) modify->min_step(0.0,hextra);
|
if (nextra) modify->min_step(0.0,hextra);
|
||||||
for (i = 0; i < n; i++) x[i] = x0[i];
|
for (i = 0; i < n; i++) x[i] = x0[i];
|
||||||
|
|||||||
@ -110,7 +110,7 @@ void Run::command(int narg, char **arg)
|
|||||||
|
|
||||||
// adjust nsteps if upto was specified
|
// adjust nsteps if upto was specified
|
||||||
|
|
||||||
if (uptoflag) nsteps = nsteps - update->ntimestep;
|
if (uptoflag) nsteps -= update->ntimestep;
|
||||||
|
|
||||||
// error check
|
// error check
|
||||||
|
|
||||||
|
|||||||
@ -273,7 +273,7 @@ void Temper::command(int narg, char **arg)
|
|||||||
if (swap) {
|
if (swap) {
|
||||||
new_temp = set_temp[partner_set_temp];
|
new_temp = set_temp[partner_set_temp];
|
||||||
modify->fix[whichfix]->reset_target(new_temp);
|
modify->fix[whichfix]->reset_target(new_temp);
|
||||||
}
|
}
|
||||||
|
|
||||||
// update my_set_temp and temp2world on every proc
|
// update my_set_temp and temp2world on every proc
|
||||||
// root procs update their value if swap took place
|
// root procs update their value if swap took place
|
||||||
|
|||||||
Reference in New Issue
Block a user