temperature profile

Dear all
I want to have a temperature distribution (temperature profile) of a group of atoms (here ‘flow’ group). I use the following way to do this (based on lammps documentation):

units real
.
.

compute ke flow ke/atom
variable tempp atom c_ke/1.5

fix Prof1 flow ave/spatial 1 10000 10000 x lower 2 y lower 2 z lower 2 v_tempp density/number units box file prof1

But the resulting temperatures seems not to be correct. i divide the temperatures by the density numbers and do some other mathematical calculations but the result is not correct.

could any one help me in calculating the true temperature?
thank u in advance

Dear all
I want to have a temperature distribution (temperature profile) of a group
of atoms (here 'flow' group). I use the following way to do this (based on
lammps documentation):

units real
.
.

compute ke flow ke/atom
variable tempp atom c_ke/1.5

fix Prof1 flow ave/spatial 1 10000 10000 x lower 2 y lower 2 z lower 2
v_tempp density/number units box file prof1

But the resulting temperatures seems not to be correct. i divide the
temperatures by the density numbers and do some other mathematical
calculations but the result is not correct.

could any one help me in calculating the true temperature?

​this is a question about fundamental statistical thermodynamics knowledge
and you should actually consult a suitable textbook to resolve your problem
(it is easy enough).
from what you provide, the example you quote seems to be meant for reduced
units, which is not what you are using. so you'll have to figure out what
the equivalent formula is to compute a temperature from the kinetic energy.
you are missing some constants that are typically chosen to be 1.0 in
reduced units.

axel.​