[lammps-users] How to accomplish the relax in a fixed direction by using Minimize command

Dear everyone,

I would like to use the minimize command to relax my system. Either the conjugate gradient (CG) or steepest descent (sd) algorithm in LAMMPS will make the system in a more stable state by searching the pathway in a 3-dimensional space. However, for my present work, I only would like to relax the system in a given direction, such as along z direction and do not relax in the other two (x, y) directions.
Is there any other one has done the similar work or give me some hints.
Thank you very much.

Best Regards,
Li Suzhi

Haven't tried this, but you might be able to use
fix id all setforce 0 0 NULL to only allow relaxation in z.

Steve