some questions about "kspace ewald"

Can i use it in 2D?If i want to use it in 2d,what should i do?It seems that i cannot use it in 2d in lammps?

Can i use it in 2D?

not as such.

If i want to use it in 2d,what should i do?

you would have to program a 2d ewald algorithm into LAMMPS. it would
be a nice addition to LAMMPS.

It seems that i cannot use it in 2d in lammps?

the only option available that is readily implemented into LAMMPS is
to use the slab feature which simulates a 2d system as a 3d system and
then corrects for the (net) interaction across periodic boundaries
using a poisson solver. that is, of course, only an approximation of a
real 2-d ewald.

axel.