displacement MC

I’m doing a displacement-only MC calculation using LAMMPS through the python interface.
I’m wondering about the fastest way to do it.

So in the MC part, I want to
*calculate the energy
*displace an atom
*calculate the new energy
to get the change in energy due to a displacement.

If the jump is accepted (in my script), I will also want to know the forces on all of the atoms.

This is done millions of times, so I want to know the most efficient way to do this.

System sizes are typically hundreds to thousands of atoms, so LAMMPS is run in serial mode.

Any suggestions would be very appreciated.

Best regards,
Murray Daw

Is ASE interface an option?


Hi Murray - see the 6 Jun patch - it added an
example of doing a series of single atom
random moves and energy evaluations for a Monte
Carlo accept/reject decision. Both as a LAMMPS
input script with a loop, and as a Python script
doing the loop in Python. The latter should
be pretty efficient at doing minimal LAMMPS
setup each time the move is performed
and energy is evaluated.
If you insure the move delta is small enough
not to retrigger a neighbor list build, then
the number of neighbor builds should also
be small, i.e much less than the number of
invocations of the loop.

See if this is faster than what you are
currently doing …