[lammps-users] "dimension 2" vs. ("boundary p p f" and "fix enforce2d")

Hi all.

I was wondering if someone could fill me in on what the differences are supposed to be between running a 2d simulation with "dimension 2" vs running with "boundary p p f" and using an additional "fix enforce2d" to prevent, e.g. a Langevin force, from moving the particles off of z=0.

Thanks,
Craig

If you really want a 2d simulation, you should use “dimension 2”.
This will insure temperature is computed w/ the correct # of degrees
of freedom, that neighbor lists get computed efficiently, etc. The
fix langevin command has extra options to keep it from changing
the z velocity. You should still use fix enforce2d with dimension 2.

Steve