[lammps-users] question about change atom type during the run and npt

Hi all,

I am using the set command to change atom type every 5000 steps during my NPT fix, and i notice everytime i change the atom type, of course the energy changed and my system temperature would increase by a fair amount and then bounce back. This behavior makes my system temperature in NPT stage increase non-linearly.

Even during the early stage of my run, I am simply changing atoms from type 1 to type 1 because type 2 hasnt appear yet, the system temperature is still affected heavily.

I am wonder how does the set atom type work, because it shouldnt affect the system in any way if i am just changing atoms from type 1 to type 1.

Thanks,
Yixin

I you set 1 to 1, you haven't changed anything, so I agree that
the command has no effect.

Steve

Hi Steve,

But in my run, the system temperature jumps up everytime i “set type”…i really cant seem to track down what is wrong.

here is my script:

fix 0 mobile npt temp 300 1750 2 aniso 0 0 2
run 1000000 every 5000 &
“group lreservoir delete” &
“group rreservoir delete” &
“group lreservoir region left” &
“set group lreservoir type 1” &
“group rreservoir region right” &
“set group rreservoir type 2”
unfix 0

I command out the lines one by one and I found that its the “set group lreservoir type 1” & “set group rreservoir type 2” are causing the problem; however, in the early stage of my run, as i already stated, im just changing atom types from 1 to 1…

Do you have any idea why is this?

Thanks,
Yixin

Do you have any idea why is this?

No. I suggest you debug what is going on.
First, get rid of the run every construct.
Just do a run, do a set, do a 2nd run. And
verify that the behavior is different with or w/out
the set command. If it is then verify the
set command is really changing nothing, by
staring at dump files or other statistics about
your system before and after the set command.
Do all of this for a very simple, small system
on 1 processor.

If you are 100% convinced that the set command
changed nothing and you still got different behavior,
then post your example to the maillist.

Steve