[lammps-users] Some questions about the Temerature

Dear All,

I tried several test about NVT system by lammps. I separated the whole system into 2 parts: mobile-which is inner region the atoms inside move freely, and constrain-which is boundary region the atoms inside are not allowed to move at all. I initialized the system with velocity-Boltzmann distribution under 30K, then to run NVT molecular dynamics (MD) simulation under 30K with “fix 1 mobile nvt 30.0 30.0 0.5” command. The output of thermo_information showes that the temperature oscillated at the beginning and then converged to 21.3K. I know that this is because the constrain on the outer region. But how can I calculate the temperature excluding the degree-of-freedom in constrain-region? I tried “compute” command but it didn’t work. The following is my input file:

Molecular Dynamics with thermal equilibrium

units metal
boundary s s p

atom_style atomic
read_data Fe_Cu15_000MPa.atoms
lattice sc 1.0
pair_style eam/alloy
pair_coeff * * fe04_cu97_setfl Fe Cu

neighbor 0.2 bin
neigh_modify delay 10
region inner block -38.0 38.0 -41.0 42.0 INF INF

group mobile region inner
group constrain subtract all mobile

equilibrate

velocity all create 30.0 74329830
velocity constrain set 0.0 0.0 0.0
compute OnlyMV mobile temp
fix 1 mobile nvt 30.0 30.0 0.5 drag 0.8
fix 2 constrain setforce 0.0 0.0 0.0
fix_modify 1 temp OnlyMV

thermo 500
thermo_style custom step temp pe ke etotal

log log.Fe_0MPa
dump mydump all xyz 3000 Fe_Dis.dump.*

run 15000

The thermo output is:

Step Temp PotEng KinEng TotEng

0 21.417039 -148085.64 103.64499 -147982
500 13.132045 -148028.99 63.550833 -147965.44
1000 16.24554 -148014.48 78.61819 -147935.87
1500 19.197051 -148002.66 92.901643 -147909.76
2000 20.694864 -147993.88 100.15012 -147893.73
2500 21.235056 -147989.56 102.76431 -147886.79
3000 21.397317 -147988.48 103.54955 -147884.93
3500 21.411517 -147988.57 103.61826 -147884.95
4000 21.460852 -147989.16 103.85702 -147885.31
4500 21.46432 -147989.48 103.8738 -147885.6
5000 21.303044 -147988.86 103.09332 -147885.77
5500 21.313366 -147988.97 103.14327 -147885.83
6000 21.289193 -147988.89 103.02629 -147885.86
6500 21.392548 -147989.35 103.52647 -147885.82
7000 21.574808 -147990.2 104.40849 -147885.79
7500 21.303878 -147988.89 103.09736 -147885.79
8000 21.364471 -147989.19 103.39059 -147885.8
8500 21.196899 -147988.41 102.57965 -147885.83
9000 21.216708 -147988.5 102.67551 -147885.83
9500 21.357345 -147989.17 103.3561 -147885.81
10000 21.379386 -147989.26 103.46277 -147885.8
10500 21.264036 -147988.7 102.90455 -147885.8
11000 21.279523 -147988.79 102.9795 -147885.81
11500 21.432892 -147989.53 103.72171 -147885.81
12000 21.290906 -147988.85 103.03459 -147885.82
12500 21.378968 -147989.28 103.46075 -147885.82
13000 21.409486 -147989.41 103.60844 -147885.81
13500 21.324627 -147989 103.19777 -147885.8
14000 21.291054 -147988.83 103.0353 -147885.8
14500 21.486539 -147989.78 103.98133 -147885.8
15000 21.279486 -147988.78 102.97932 -147885.8

Would you please help me to find out the way to compute the temperature correctly? or this constrain-included estimation of temperature is no problem at all? Thank you so much.

Best Regards

Zhengzheng Chen

Visiting Scholar
Department of Physics & Astronomy
California State University, Northridge
18111 Nordhoff Steet, Northridge, California, 91330
Tel: (818)677-5613 (o)
(818)826-0632 (h)
e-mail: satchel1979@…24…
chenz@…731…

Read the thermo_style doc page. The default temp used by thermo
is for all the atoms. You need to define a compute that is on
just the mobile atoms, then use thermo_modify to use that compute
with thermo (or the one defined internally by NVT) to display
your temps.

Steve