how to get ewald/n working ?

Hi LAMMPS users,

I want to run fix npt with triclinic cell, with kspace_style ewald/n, it returns an error:
ERROR: Invalid kspace style (force.cpp:533)

I didn’t find other restriction about the ewald/n, probably I missed some instructions in the manual but I just cannot figure it out. Please someone give me a hint, thanks.


You need to install the USER-EWALDN package to enable ewald/n:

make yes-user-ewaldn

and then (re-)compile LAMMPS.


And the restrictions section on the doc page mentions this.

The {ewald/n} style is part of the USER-EWALDN package. It is only
enabled if LAMMPS was built with that package. See the "Making
LAMMPS"_Section_start.html#start_3 section for more info.