peak_lab_to_k_out#

anri.diffract.peak_lab_to_k_out(peak_lab, origin_lab, wavelength)[source]#

Convert from vector of peak in lab frame to normalised scaled \(\vec{k_{\text{out}}}\) in the lab frame.

If peak_lab is an observed peak position in the lab frame, we subtract the origin_lab to get the scattering vector, then normalise it.

Parameters:
  • peak_lab (Array) – [3] Vector in the lab frame

  • origin_lab (Array) – [3] Origin of diffraction in the lab frame

  • wavelength (float) – wavelength in angstroms

Returns:

k_out (jax.Array) – [3] Outgoing scaled normalised wave-vector