RE: [lammps-users] stress tensor dump

The following is my understanding.

In the standard output, the total kinetic energy is calculated by the temperature.
Hence, in each diagonal component, the kinetic energy is the total/3.

But, in the atom dump, the kinetic energy of each atom is calculated directly based on the difinition, i.e.,

k = vi*vj/2

Yong

Thanks to Yong!

I think that the pressure output and the constant pressure control is ok for the isotropic bulk system because the sum of kinetic part is related to the temperature and the pressure is averaged over three diagonal component. But if one wants to calculate the shear viscosity bulk viscosity or to get them for the anisotropic system, some changes are required.

So I want to make use of the atom stress dump code to get the right pressure tensor of the system and print it out to the log file instead of dumpping stress tensor for every atom. At present, I am not familiar with lammps code and helps from all the users are appreciated! Thank you!

Best regards!

Zhimin Xiong

I think that Steve is working on changes to LAMMPS to
make it more flexible in what it reports to the log
file. The changes should allow output of the
individual pressure tensor elements for the entire
system, including the virial and kinetic portions.
This would be useful, for example, in viscosity
calculations.

Paul

yes - I should have a patch ready to post sometime this
week - it will compute pressure components correctly
(vx*vy for kinetic_xy term) and allow you to print
them as part of thermodynami output.

Steve

Good news! Thanks to Steve for your continuous work!