[lammps-users] compute pressure

Dear Friends

I want to know about compute pressure. If I want to compute pxx and pxy how should I write this command?

Best Regards

Saly

If you mean the global pxx and pxy, LAMMPS already computes these for you. Take a look for thermo_press in the online documentation for more details for how to use it.

–AEI

Dear Ahmed Esmael

I run my simulation box in NPT ensemble, but I need pxx and pxy of a group of atoms not all of them. I need pxx and pxy for the group not for all of the atoms.

Would you please help me?

Thanks

Saly

Dear Saly:

Post responses to the mailing list, not to individuals.

If you need the pxx and pxy for a group of atoms, first you need to create the group of atoms. Then you need to assign the computation to the group using compute pressure, and then output it with a thermo, fix, or dump command (which you pick depends on your needs).

You’ll learn more if you look these commands up in the manual and try to use them. If it’s not working, we can try to point you in the correct direction. But we’re not here to do your thinking for you!

–AEI

What does pxx mean for a group of atoms?

The only thing LAMMPS does in this regard is calculate a per-atom
stress via compute stress/atom. You can then sum
this to get a value, but it may not be what you are talking
about.

Steve