[lammps-users] Printing thermodynamic data of each region to the screen and log file

Dear LAMMPS user,

I work on a simulation box which is divided into different regions. Now the question is: How to print thermodynamic data of each region (e.g. region 1’s length in x, y, z or region 2’s length in x, y, z or whatever ) to the screen and log file?

Sincerely,
Lili

The geometry of a “region” (as defined by the region command in LAMMPS) is an input parameter. So you should already know its lengths and dimensions and there should be no need to output that to the screen (again and again).

If you want to partition your system dynamically, you will first have to define and explain how those “regions” could be determined. What may seem straightforward for you as a person, may be difficult to determine in a computer program.

Now other thermodynamic data can be computed for groups and groups can be defined for regions (statically or dynamically) and thus you can also access their data. Some properties, however, are not so well defined by a group (e.g. pressure) in that case you will first compute the stress/atom, then compute the sum and divide by the volume for that group.

There is an entire HOWTO section in the LAMMPS manual devoted to creating custom output.

Dear Dr.Axel,
Thanks for your comprehensive answer. I totally agree with you. But there is a tiny tiny ambiguity…
The geometry of a “box” is an input parameter but we can print its lengths in x,y,z. What is the difference?

Sincerely,
Lili

The size of the box can change, if you use fix npt or fix nph or fix deform or fix press/berendsen or fix box/relax or the change_box command or have shrink-wrap boundaries.