Explanation of create_atom output

I am very new to LAMMPS and have been trying to figure out how to use the create_atoms. I am just trying to define a 3d region and then fill it with particles, ideally at a specified packing fraction or with a specific number of particles. I have just been using the example given in the documentation but the output of the coordinates doesn’t match the picture provided in the documentation (sinusoidal wave).

units lj
dimension 2
region box block 0 50 0 50 -0.5 0.5
create_box 1 box
create_atoms 1 random 2000 13487 NULL overlap 1.0 maxtry 50
pair_style lj/cut 2.5
pair_coeff 1 1 1.0 1.0 2.5
write_dump all atom coords2.txt

The output looks like the following

ITEM: TIMESTEP
0
ITEM: NUMBER OF ATOMS
2000
ITEM: BOX BOUNDS pp pp pp
-5.0000000000000000e+01 5.0000000000000000e+01
-5.0000000000000000e+01 5.0000000000000000e+01
-5.0000000000000000e-01 5.0000000000000000e-01
ITEM: ATOMS id type xs ys zs
1 1 0.497041 0.764961 0.5
2 1 0.153896 0.536377 0.5
3 1 0.396365 0.708224 0.5
4 1 0.322652 0.81345 0.5
5 1 0.520825 0.510146 0.5
6 1 0.314503 0.857443 0.5
7 1 0.0393217 0.880628 0.5
8 1 0.168315 0.863787 0.5
9 1 0.406776 0.682612 0.5

The entire output file shows the coordinates as being within 0 and 1, but to my mind at least the x-coordinates should extend across the entire domain (0-50). Is this an issue with the write_dump statement or is this correct and there is implicitly some kind of transform that needs to be performed on the output?

All you need to do is to read the documentation and observe what you see in the dump file.
https://docs.lammps.org/dump.html

Please pay special attention to the following line:

This tells you what information each column carries. The legend for that is in the docs:

  • id: atom ID
  • type: atom type
  • xs: scaled x coordinate
  • ys: scaled y coordinate
  • zs: scaled z coordinate

effictively, you have the information as fractional coordinates. This is the default for dump style atom. You can chance it using the dump_modify <dump ID> scale yes/no command.

The alternative is to use a custom dump style (which many people use) and then you can add other per-atom data as well.

Again, the information is all there in the LAMMPS manual.

Sorry, the documentation is dense and I have found it hard to follow. Thank you for the response.

Part of learning to use a software is learning how to read its documentation. Remember, that you are looking at a reference, so it has to be complete. For commands with many variants and options, like the dump command, that means large and sometimes convoluted documentation pages. The better you learn to deal with that, the easier it will be to use it well.

I’m well aware of that, like I said I am very new to LAMMPS and just getting a few pointers at the start is always helpful. The documentation structure and thoroughness is simply different what I have seen in other code documentation. Thank you for your suggestion.