Hi all,
I am having troubles with using restarting using fix property/atom with write/read_restart.
If I use the fix property/tom [properites] in input file 0:
Simulation box
[…]
Adding a new property - need to be added before simulation box
fix prop all property/atom d_foo ghost yes
[…]
write_restart restart.mpiio
and then redefine it in input file 1 with:
read_restart restart.mpiio
Adding a new property - need to be added before simulation box
fix prop all property/atom d_foo
[…]
I always get the error:
ERROR: Atom style was redefined after using fix property/atom.
Reading the manuals lead me to: http://lammps.sandia.gov/doc/read_restart.html
As indicated in the above list, the fixes used for a simulation are not stored in the restart file. This means the new input script should specify all fixes it will use. However, note that some fixes store an internal “state” which is written to the restart file. This allows the fix to continue on with its calculations in a restarted simulation. To re-enable such a fix, the fix command in the new input script must be of the same style and use the same fix-ID as was used in the input script that wrote the restart file.
in which I tried to re-enable the fix from the previous file which is not working. Any suggestions on how should I get around it?
Thanks,
Quang
Hi all,
I am having troubles with using restarting using fix property/atom with
write/read_restart.
If I use the fix property/tom [properites] in input file 0:
# Simulation box
[...]
# Adding a new property - need to be added before simulation box
fix prop all property/atom d_foo ghost yes
[...]
write_restart restart.mpiio
and then redefine it in input file 1 with:
read_restart restart.mpiio
# Adding a new property - need to be added before simulation box
fix prop all property/atom d_foo
[...]
I always get the error:
ERROR: Atom style was redefined after using fix property/atom.
Reading the manuals lead me to: http://lammps.sandia.gov/d
oc/read_restart.html
As indicated in the above list, the fixes
<http://lammps.sandia.gov/doc/fix.html> used for a simulation are not
stored in the restart file. This means the new input script should specify
all fixes it will use. However, note that some fixes store an internal
“state” which is written to the restart file. This allows the fix to
continue on with its calculations in a restarted simulation. To re-enable
such a fix, the fix command in the new input script must be of the same
style and use the same fix-ID as was used in the input script that wrote
the restart file.
in which I tried to re-enable the fix from the previous file which is not
working. Any suggestions on how should I get around it?
i seriously doubt, that you are analyzing the issue correctly. the only
way, i can see this error happening if you do exactly what the error
message is telling you: you changed the atom style after you defined fix
property/atom. since the atom style is encoded in the restart file, you can
only do this *before* writing the restart.
check your input *very* carefully.
axel.