System enclosed between walls

Dear Ray,

Thank you for your quick response. However, I still have the same problem. I do not understand why “units box” should be a problem,because I define

units lj

boundary f f f

atom_style sphere

If I do not understand wrong, the command “units box” should consider Lennard-Jones units.
Maybe I need to consider something more because my atom_style is “sphere”?
Because it is strange to have particles inside of the wall, due to the parameter k
is high (in particular, k=1e8).

Thank you for your time.

Jose.

Please read the doc page: https://lammps.sandia.gov/doc/fix_wall.html

Ray

I admit I am new to this thread, so the following suggestion may not
be relevant.
There was a discussion about how to use fix wall/region recently:

https://sourceforge.net/p/lammps/mailman/message/36520768/

I do not understand why "units box" should be a problem

I agree. But did you mean "units lj"?

I've attached a file containing LAMMPS input script commands that
define a cylindrical region enclosed by a wall. (This example works
with "units lj". It's the same example from the post above.) You
will have to modify the shape of the region if you want two plates.
(Try creating a region which is the intersection of two planar
regions.)

Last, I checked (years ago) the documentation could be improved. I
think I had to step through the code with a debugger to figure out how
to get "fix region/wall" to work the way I expected. But fix
wall/region does work (as long as the shape of your region is not
convex, I think). I use it frequently.

I hope this helps.

Andrew
P.S. You can also try building your wall out of immobile particles.
If you don't mind using moltemplate, then there are several examples
of how to do this located below:
http://moltemplate.org/visual_examples.html#translocation
http://moltemplate.org/visual_examples.html#nanotube+water
https://github.com/jewettaij/moltemplate/tree/master/examples/coarse_grained/abstract_lennard_jones_tube
https://sourceforge.net/p/lammps/mailman/message/36408810/ (input
files included)
https://sourceforge.net/p/lammps/mailman/attachment/CAEbHWTTVod54tOJCXAknYxeA51OmbLR%2B5WSjbzOekuofC2dyeA%40mail.gmail.com/2/

confinement_cylinder_R=60.in|attachment (2.36 KB)