A problem with compute temp/com command

Dear all

I work on a system including two immiscible fluids, Fluid 1 and Fluid 2, which I need to measure their temperature, individually. My simulation results indicate different temperature values for the system and the fluids. However,

1-the temperature of these fluids are the same, exactly.

2-The temperature of the system using this command is exactly equal to the value I obtain using thermo command.

I would appreciate if I have your advice to figure out the above difference.

Thanks a lot,

Best,

Saly

Dear all

I work on a system including two immiscible fluids, Fluid 1 and Fluid 2, which I need to measure their temperature, individually. My simulation results indicate different temperature values for the system and the fluids. However,

in which way is this related to the temp/com command?

1-the temperature of these fluids are the same, exactly.

how did you establish this? how exact?

2-The temperature of the system using this command is exactly equal to the value I obtain using thermo command.

I would appreciate if I have your advice to figure out the above difference.

difference between what?

your inquire provides too little tangible information and is too vague to give any specific advice.

axel.

Dear Axel

Here is the part of my input file

log log.${sname}E1
fix E1 all nvt temp 298.15 298.15 100

compute TemphexaneCE1 hexane temp/com
compute TempsolCE1 sol temp/com
compute TempallCE1 all temp/com

thermo ${ThermoStepsE1}
thermo_style custom step temp press vol etotal c_TempallCE1 c_TemphexaneCE1 c_TempsolCE1

and you can see in the following what I see in my log file:
Temp and c_TempallCE1 are the same and
c_TemphexaneCE1 and c_TempsolCE1 are equal exactly.

Step Temp Press Volume TotEng c_TempallCE1 c_TemphexaneCE1 c_TempsolCE1
12000 301.18435 1143.804 214272 -26950.415 301.1842 297.56844 297.56844
12100 297.16835 1227.6803 214272 -26974.477 297.1682 287.95405 287.95405
12200 296.54164 1042.9386 214272 -26993.839 296.5415 284.29383 284.29383
12300 299.48989 1092.0651 214272 -26964.811 299.48974 289.29483 289.29483
12400 299.37652 1156.6226 214272 -26942.686 299.37637 287.58933 287.58933
12500 294.14464 1258.8248 214272 -26985.537 294.14449 282.53037 282.53037
12600 296.94217 1127.2714 214272 -26935.65 296.94202 290.27909 290.27909
12700 298.77814 1118.2273 214272 -26785.858 298.77799 288.24058 288.24058
12800 302.24164 847.85769 214272 -26699.148 302.24149 300.30467 300.30467
12900 296.3129 937.52697 214272 -26798.803 296.31275 285.01719 285.01719
13000 298.46431 733.89756 214272 -26886.525 298.46416 288.03487 288.03487
13100 293.04203 927.08726 214272 -26966.646 293.04188 283.68366 283.68366
13200 294.54606 1022.9211 214272 -26883.367 294.54591 281.36506 281.36506
13300 299.86609 1034.0098 214272 -26743.805 299.86594 286.825 286.825
13400 299.73539 858.99859 214272 -26705.369 299.73524 290.03361 290.03361
13500 299.62246 986.1455 214272 -26700.932 299.62231 290.93501 290.93501
13600 301.35497 1030.0636 214272 -26721.693 301.35482 296.6493 296.6493

I also have this problem if I use compute temp command.

Thanks,
Best
Saly

i don’t see a compelling argument here for there being a problem.

temperature for all molecules is 301.1842
but for hexane and water is 297.56844. A difference with more than 3 degrees of centigrade !!!

whether 3 degrees is a lot or not depends on the number of atoms, but more importantly, for using group “all” the temperature compute will compute the temperature based on 3N-3 degrees of freedom, however, for subgroups, it is not clear how to distribute the 3 DoFs due to translational invariance to individual groups. hence you can use compute_modify extra to adjust the degrees of freedom to be used for any temperature compute manually. by default, they are not subtracted and thus resulting in a slightly lower temperature (how much lower depends on the number of atoms, of course).

this all is expected behavior and due to standard statistical mechanics considerations.

axel.

I really appreciate your valuable advice. I will try to use compute_modify.

Thanks,
Best,
Saly