LAMMPS users,
I am having a lot of trouble with the GCMC fix loosing atoms during a run.
A snippet of the code is attached below which I am testing on a box of FCC
metal, adding hydrogen, with an EAM potential.
#re-neighbor
neighbor 1.5 bin
neigh_modify every 1 delay 0
#THERMALLY EQUILIBRATE
thermo 0
log log-2.4650equ.lammps
velocity all create t {seed} mom yes rot yes dist gaussian
fix 7 all nvt temp $t t 10\.0
timestep 0\.001
run 1000
reset\_timestep 0
\#GCMC SETTINGS
\# fID gID gcmc Nmdsteps Xchange Moves attype seed T mu
maxtrans options
fix gcmc hydrogen gcmc 100 200 0 2 {seed} \{t\}\.0 {mu} 0.01
full_energy
compute_modify thermo_temp dynamic yes
thermo 5000
restart 100000 restarteq.${mu}.*
timestep 0.001
run 1000000
Unfortunately, the problem is not entirely reproducible, it occurs most of
the time, and at different time steps. The number of atoms lost is usually
1 or 2, but I have seen it as large as 100. What I¹ve noticed is that a
higher the chemical potential (closer to 0) seems to make the GCMC more
likely to crash.
I have tried numerous strategies to prevent the loss of atoms including
reducing the timestep by an order of magnitude, reneighboring every
timestep, and eliminating MC moves of atoms between MD steps (seems
redundant if I am already running MD). I have even attempted to confine
the GCMC to within a region smaller than the simulation domain itself.