scipp / scippneutron

Neutron scattering toolkit built using scipp for Data Reduction. Not facility or instrument specific.
https://scipp.github.io/scippneutron/
BSD 3-Clause "New" or "Revised" License
4 stars 3 forks source link

Compute time at sample #489

Closed SimonHeybrock closed 7 months ago

SimonHeybrock commented 7 months ago

This is required for event data filtering for fast sample environment parameters, e.g., in ESSsans.

Should this be added to the regular coord transform graphs that ScippNeutron provides?

jokasimr commented 7 months ago

Is the time at the sample $t_s = L_1/v$ where $v = (L_1 + L2) / t{d}$ where $t_d$ is the time of flight?

SimonHeybrock commented 7 months ago

Almost, this is about the absolute time at the sample, so $t_0 + t_s$ in your notation. It is probably easiest to calculate backwards from the detector position (i.e., we do not require $L_1$).

jokasimr commented 7 months ago

Okay I see, so we should compute the absolute time like $t_{abs,\ s} = t_0 + t_s = t_0 + t_d - L_2 / v$?

SimonHeybrock commented 7 months ago

Okay I see, so we should compute the absolute time like tabs, s=t0+ts=t0+td−L2/v?

Yes, and we might go via wavelength, since $v$ is generally not required, but wavelength is computed in many cases already.

jokasimr commented 7 months ago

Where do we get $t_0$ (the time when the neutron passes the point where L=0)?

SimonHeybrock commented 7 months ago

We must assume we have it, it is generally called pulse_time in our workflows, though that is subject to change.