Property/atom Command

Submitted by govind on Sat, 09/30/2017 - 13:29

Hi All,

I want to know id of an atom during computation for that I am using property/atom command like this

compute ID impactor property/atom id
variable aID equal c_ID[1]

here impactor group only has one atom. And I access this with v_aID. But it throws an error :

ERROR: Compute used in variable between runs is not current. Use the update_on_run_end option for computes to avoid this.

After following this error message I change the compute command

compute ID impactor property/atom update_on_run_end yes id

and run the simulation. I get the same error message again.

Govind

JoG | Fri, 04/27/2018 - 14:20

I also get this error message, even though I inserted the update_on_run_end keyword. Also for my case, the compute did not accept the keyword when I put it on the end.

fix tr all property/atom/tracer region_mark innerRegion mark_step 0 marker_style dirac check_mark_every 10000000
compute nparticles all nparticles/tracer/region update_on_run_end yes region_count innerRegion tracer tr
variable test equal c_nparticles[1]
print "number of particles in inner region: "${test}

I receive the error message
ERROR: Compute used in variable between runs is not current. Use the update_on_run_end option for computes to avoid this. (../variable.cpp:997)

And by the way, there is a typo in the message itself ("cuurent" instead of "correct").

richti83's picture

richti83 | Mon, 05/07/2018 - 08:31

FYI: The error message is spelled correctly, from variable.h:

E: Compute used in variable between runs is not current
#
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.

Sometimes it helps to add a run 1 between the compute and the variable to invoke the compute once before the variable is accessed.

I'm not an associate of DCS GmbH and not a core developer of LIGGGHTS®
ResearchGate | Contact