Initializing my positions within a specified region

Hello, I have a simulation box of a specified dimension and I want to simulate a binary mixture of atom types of mass 1 and 5. However, I want my initial coordinate for the y positions to start within a particular range of coordinates. Example, my simulation box is of dimension -5.29 5.29 -10.58 10.58 -5.29 5.29. I want the initial configuration of the two atoms to randomly be anywhere in the x and z coordinates however, for the y coordinate I want it randomly to start anywhere between -10.58 and -10.22. This condition applies only to the starting configuration and would want the atoms to explore all possible places in the simulation box for the x,y, and z. This is the script that I came with, but it seems not to be working, any help will be appreciated.

region box block -5.29 5.29 -10.58 10.58 -5.29 5.29 side in box move v_x v_y v_z
create_box 2 box
region myregion block -5.29 5.29 -10.58 -10.22 -5.29 5.29
create_atoms 1 random 1000 25673 myregion
create_atoms 2 random 1000 3456 myregion

Not to be working how?

Lammps does not put the starting atoms in the defined coordinate that I specified for the y-direction.

You need to explain how exactly you determine this and provide a complete input that this can be checked independently. Your quoted command reference variables without showing how they are defined.

Hi @Ansah, the syntax of your region command is also wrong, beside the move commands and the variables that look like a bad copy/paste (tip: avoid doing that) @akohlmey mentioned, the box keyword appears bogus to me. For a more detailed explanation, please read the region command manual page.

Removing the end of the line starting with the side argument (kind of useless, it is the default setting) makes the command valid and it should work with the last version. As far as my quick test went, everything was fine.

If not, you would get more help by posting both your full input script and the error message or output you get from LAMMPS as well as the version used, and what differs compared to what you expected.