I have calculated in two different ways the temperature profile of my system (liquid which is in x- and y- direction periodic and has surfaces from above and below it along z-direction).
Firstly, I used “compute temp/profile” which I then averaged using “fix ave/time”. The result looks awkward. Firstly the temperature values are higher than the reference temperature and secondly the temperature values oscillate one to one as the density profile (along z-direction) of my liquid.
Second way was via post processing. I just wrote a simple program that analyzes the particle velocities from the dump file. The temperature in every bin was calculated like:
T_bin = 2/(3k_b) * <E_k>_bin / _bin, where _bin is the average number of the particles in the bin and <E_k>_bin is respectively the average kinetic energy in the bin. If there was no single particle in the bin over the whole period of averaging than T_bin was set simply to zero. At the attached graph of the temperature profiles one can notice that in such a way calculated temperature profile is quite reasonable and the temperature fluctuates around the reference temperature.
My question is the following.
What might be the reason that “compute temp/profile” yields such a strange temperature profile?
Temperature rescaling was used for the thermostating, but in the the case of the Nose-Hoover thermostat one gets the similar behaviour from “compute temp/profile”.
in.nodd (1.38 KB)
temperatur.eps (27.8 KB)
data.Hg.dp.N1000.lxlz.d13.69.relaxed (49.3 KB)