I have this loop:
# --- Gradual Heating (300K to 2000K) ---
label heating_loop
fix mynpt all npt temp ${T} ${T} ${damp} iso 1.0 1.0 ${pdamp}
fix equil2 all ave/time 100 10 1000 v_pe v_ke file Melt_energy_equil.dat
run 20000
print "Equilibrated at ${T} K"
variable T equal ${T} + ${dT}
if "${T} < ${Tm}" then "jump SELF heating_loop"
But the output show this error:
Equilibrated at 300 K
ERROR: Illegal variable command: expected 3 arguments but found 5 (src/variable.cpp:449)
Last command: variable T equal ${T} + ${dT}
I did a test script just for the loop and it worked fine with the same sintaxis.
variable T equal 300
variable dT equal 50 # Incrementos de 50
variable Tm equal 2000
# --- Gradual Heating test (300K to 2000K) ---
label heating_loop
print "Actual Temperature is: ${T}"
variable T equal ${T} + ${dT}
if "${T} < ${Tm}" then "jump SELF heating_loop"
Why could this happen?
If you are interested, here is the complete script
in_melt.lmp (2.0 KB)