the manual file in “fix thermal/conductivity command” suggests averaging ke/atom for determining the temperature profile.
but according to the statistical definition of temperature (temp. is proportional to the variance of atoms velocities)
it seems that at first the average velocity of each bin should be subtracted and then we can determine the spatial average of (V(i)-V(ave))^2.

the formula mentioned in documentation of “compute temp” means that
if we have a glass of water, walking with the glass will increase the temp
of water and sitting in a high speed train will make the water to boil !

the formula mentioned in documentation of "compute temp" means that
if we have a glass of water, walking with the glass will increase the temp
of water and sitting in a high speed train will make the water to boil !

but if you factor in, that due to periodic boundary conditions an MD simulation
should be invariant to translation and, in fact, it would be a problem
if you had
a net momentum (see discussions in the mailing list archives on the so-called
"flying icecube syndrom"), then there is no problem with this and that the
average kinetic energy *is* proportional to the temperature. the bias that you
worry about is already zero by construction.

I don’t want to use “fix thermal/conductivity”
but the question was about the method of determining the temperature profile
that has been discussed meanwhile that section of the manual file.

thanks Axel !
but I couldn’t find “flying icecube syndrom”. is it be archived?

Then there are several different compute temp options in
LAMMPS, many of which subtract off "biases" of one sort
or another, before calculating the temperature. See
compute temp/com or compute temp/profile for example.

yes those commands are the case. of course they deliver a global scalar useless for
averaging spatially to determining the temp profile.
however the temp/region seems the best choice.