[lammps-users] involk the PE variable during minimization

Dear Ajing

#label
variable mype equal “pe*1.”
label tloop
variable t loop 20

displace_atoms upper move -0.1108394108 0 0 units box
#thermo_style custom step pe pxy pxz pyz pxy pyz pxz

dump 1 all custom 1000 dump.* id type x y z

print “t" #print "{pe}”
print “${mype}”
minimize 0.00001 0.00001 1000 1000
undump 1
next t
jump in.10x2x2_300k_1e9 tloop

first thing as “{pe}" is not a variable so directly we can not print "{pe}”.

and as “mype” is a variable, and if I run this program i got the following error:

Total # of neighbors = 5213
Ave neighs/atom = 15.4231
Neighbor list builds = 46
Dangerous builds = 0
System init for displace_atoms …
Displacing atoms …
1
ERROR: Compute used in variable thermo keyword between runs is not current

and this error list one ll check in lammps manual, it says
"Compute used in variable thermo keyword between runs is not current

Some thermo keywords rely on a compute to calculate their value(s). Computes cannot be invoked by a variable in between runs. Thus they must have been evaluated on the last timestep of the previous run in order for their value(s) to be accessed. See the doc page for the variable command for more info."

Hope so this will clear your doubt. but anyway you can dump pe after each jump in different file,

regards

Vijay