Fqt with and without calculate_incoherent

Hello,

There is an other point I do not understand in obtained result. If I compute the dynamic structure factor using calculate_incoherent=True, it does not give the same result for F(\boldsymbol{q}, t) as if I use calculate_incoherent=False.

If your try, on dump.xyz in dynasor/tests/trajectory_reader/trajectory_files :

from dynasor import compute_dynamic_structure_factors, Trajectory
from dynasor.qpoints import get_spherical_qpoints
from dynasor.post_processing import compute_spherical_qpoint_average

traj = Trajectory('./dump.xyz', trajectory_format='extxyz')
q_points = get_spherical_qpoints(traj.cell, q_max=3)
res = compute_dynamic_structure_factors(traj, q_points, dt=25, window_size=100)

res.Fqt[0,:] is the number of particles which is correct from the definition.

But if compute with:

traj = Trajectory('./dump.xyz', trajectory_format='extxyz')
res_2 = compute_dynamic_structure_factors(traj, q_points, dt=25, window_size=100, calculate_incoherent=True)

Now res_2.Fqt[0,:] is the number of particles plus one ; res_2.Fqt_coh[0,:] is the number of particles ; res_2.Fqt_incoh[0,:] is one.

Is there a problem on the assignement of total, coherent and incoherent values ?

Best,

Fqt refers to the sum of the coherent and incoherent, see this table.
With this in mind it sounds like your results make sense?

Yes it makes sense. I think I expressed myself badly. I wonder if starting definitions are correct. Given that the notions of self/coherent and distinct/coherent defines the same observables, and given than distinct Van-Hove functions sums over i \neq j.

Isn’t that the correct definition :

F_\mathrm{self}(\boldsymbol{q},t)=\frac{1}{N} \sum _i ^N \left < \mathrm{exp}\left[i\boldsymbol{q}\cdot(\boldsymbol{r}_i(t)-\boldsymbol{r}_i(0))\right] \right >,
F_\mathrm{distinct}(\boldsymbol{q},t)=\frac{1}{N} \sum _{i \neq j} ^N \left < \mathrm{exp}\left[i\boldsymbol{q}\cdot(\boldsymbol{r}_i(t)-\boldsymbol{r}_j(0))\right] \right >,
F(\boldsymbol{q},t) = F_\mathrm{self}(\boldsymbol{q},t) + F_\mathrm{distinct}(\boldsymbol{q},t),

Hence F(\boldsymbol{q} = 0, t=0) = N, equivalent to S(\boldsymbol{q} = 0)

So in Dynasor, Fqt would refer to the total ISF, and if one computes the coherent (self) part, you can obtain the incoherent (distinct) part calculating the difference.

I can’t find where I’m wrong.

Yea I think the definitions differ a bit.
Dynasor only computes the coherent and incoherent parts, the sum of these two are stored as sample.Fqt.

In dynasor the coherent part is
F_{coh} = \sum_i \sum_j ....
where the double sum runs over all i and j, including terms with i=j.
And the incoherent (self) part is a single sum
F_{incoh} = \sum_i ....
But dynasor doesnt not (directly) compute F_{distinct} as you define it. (see here for more details)

So with these definitions if I understand correctly we have F_{coh} = F_{distinct} + F_{self} .
Hopefully this clarifies it.


@esmee In the docs I think we do write F(q, t) when we mean F_{coh}(q, t), maybe something one should fix to avoid confusion, since Fqt does not necessarily refer to the coherent in the Sample.

Thank you for the clarification Erik.