Dear Steve, German, Vikas and other LAMMPS users,

I have a few doubts regarding the contents of some previous posts on heat flux calculation,

as well as with the heat flux calculations in LAMMPS:

--------------------------------------[Questions for German:]-----------------------------------------------------

Dear German,

1>

In your script, as a step to calculate flux, you have used:

variable VX atom -(c_SA[][1]*vx[]+c_SA[][4]*vy[]+c_SA[][5]*vz[])/1.6021765e6

Could you please tell me why you have divided by 1.602…?

This division is only for the Jv component and not the Jc component.

2>

Could you please share the code you have to include electrostatic effects in heat flux calculations?

--------------------------------------[Question for Vikas/Everyone]-----------------------------------------------------

Dear Vikas,

3>

I am not too familiar with C++. I was looking at the compute_heat_flux.cpp file:

Line

148 xtmp = x[i][0];

149 ytmp = x[i][1];

150 ztmp = x[i][2];

167 delx = xtmp - x[j][0];

168 dely = ytmp - x[j][1];

169 delz = ztmp - x[j][2];

174 eng = pair->single(i,j,itype,jtype,rsq,factor_coul,factor_lj,fpair);

181 double vx = 0.5*(v[i][0]+v[j][0]);

182 double vy = 0.5*(v[i][1]+v[j][1]);

183 double vz = 0.5*(v[i][2]+v[j][2]);

184 fdotv = factor * fpair * (delx*vx + dely*vy + delz*vz)

186 Jv[0] += fdotv*delx;
187 Jv[1] += fdotv*dely;

188 Jv[2] += fdotv*delz;

Is it that, for the value of the force between a pair of atoms,

the magnitude of the total force has been used, instead of the vector components?

The reason I am asking this is:

I was trying to compare the values of the heat flux obtained by two methods:

viz using compute heat/flux v/s compute stress/atom.

I am expecting the flux values to be exactly the same,

but the values differ.

The kinetic contributions to the flux are identical, but the potential contributions differ.

I am trying to understand why the values are different.

The input script used for this comparison (in.gktc_comparison) is attached.

--------------------------------------[Question for Everyone]-----------------------------------------------------

4>

Has anyone tried to calculate the thermal conductivity using the Einstein formula?

(Similar to MSD being used to calculate diffusivity)

i.e. Lamda_x = 0.5 * 1/(V*kB*T^2) d/dt < [e_x(t) - e_x(0)]^2 >

-for long t.

This would require unwrapped coordinates to be available as a variable.

I can currently find unwrapped variables only in the dump command.

Is it possible to access these as variables?

To handle charged systems, this would also require pe/atom to include long range contributions.

[German:

Since you have obtained long range contributions for the flux calculations,

would it also be possible to obtain the contributions to PE?]

Awaiting your reply and thanks in advance.

Warm regards,

Mario

in.gktc_comparison (2.36 KB)