[lammps-users] boundary s s s and ensemble NPT

hello , why the boundary [ s s s ] is not imposed on the ensemble NPT?
if i want to control the press of the system whose boudary is [s s s ]
,how can i do? then const press plus boundary [ s s s } is still equal
to the ensemble NPT, isn' t it? your answer is appreciated.

From this page: http://lammps.sandia.gov/doc/fix_npt.html

we read:

“Any dimension being adjusted by this fix must be periodic. A dimension whose target pressures are specified as NULL can be non-periodic or periodic.”

You can’t use “boundary s s s” with fix npt because they would compete for control of the box dimensions. “boundary s s s” works by shrinking the box dimensions to match the minimum and maximum particle positions. fix npt works by expanding or contracting the box in response to the measured pressure. Imposing both simultaneously would make a mess, so LAMMPS doesn’t allow it.

But you can shrink wrap in one or two of the directions and use fix npt in the remaining direction(s). For example:

boundary s s p
variable x index 5
variable y index 5
variable z index 5
units lj
atom_style atomic
lattice fcc 0.8442
region box block 0 $x 0 $y 0 $z
create_box 1 box
create_atoms 1
mass 1 1.0
velocity all create 1.0 87287 loop geom
pair_style lj/cut 2.5
pair_coeff 1 1 1.0 1.0 2.5
neighbor 0.3 bin
neigh_modify delay 0 every 20 check no
fix 1 all npt 1.0 1.0 0.1 aniso NULL NULL NULL NULL 1.0 1.0 1.0
thermo 10
thermo_style custom step temp pe eng press lx ly lz
run 1000

But even this is problematic, at least in this case, since the box continuously expands in the x and y directions and contracts in the z direction.