Page 1 of 1
Dimension of ML_HEAT output
Posted: Mon Oct 13, 2025 7:03 pm
by akretschmer
Hi,
I have a question regarding the units of the ML_HEAT file containing the local heat flux.
I have written some python code to compute the thermal conductivity using the Green-Kubo formalism. When I load the ML_HEAT files using my code and convert the units from eV*A/fs, as specified in the documentation, to W*m I get a thermal conductivity 4 orders of magnitude too high. Moreover, when I simulate SPC/E water using LAMMPS, output the heat flux in the same units and then use the same code to compute the thermal conductivity of this water I get a correct result, the same as in literature.
I would get results around the correct value if I suppose that the units I convert from are eV*pm/fs, i.e. I use a conversion factor of 1.602e-16 instead of 1.602e-14 when I convert from eV*A/fs to W*m.
My question is if it is possible that the units in the documentation are incorrect, i.e. that they should be eV*pm/fs instead of eV*A/fs?
Re: Dimension of ML_HEAT output
Posted: Tue Oct 14, 2025 8:55 am
by martin.schlipf
I will inquire whether users need to be careful with converting ML_HEAT to SI units. Looking just at the code it seems that eVA/fs is correct
Code: Select all
WRITE(IU,1) NSTEP,(QHEAT(IXYZ)*EUNIT*AUTOA/TUNIT,IXYZ=1, 3)
where EUNIT, AUTOA, and TUNIT convert atomic units to eV, A, and fs, respectively (check ml_ff_iohandle.F and ml_ff_constant.F).
[Edit: removed incorrect statement about LAMMPS interface]
Re: Dimension of ML_HEAT output
Posted: Tue Oct 14, 2025 9:27 am
by martin.schlipf
Perhaps you can share the Python code if you think that would help.
Another alternative is to compute the thermal conductivity with a the Müller-Plathe method.
Re: Dimension of ML_HEAT output
Posted: Fri Oct 17, 2025 9:17 am
by martin.schlipf
As a correction to the earlier post: The LAMMPS interface will actually not work to compute the thermal transport. Some quantities required are not communicated via the force-field interface so LAMMPS cannot compute the heat flux.
The Müller-Plathe method is therefore the best alternative. It usually also shows a better convergence behavior with the required sample data.