beam_weight#

anri.fwd.beam_weight(pos_lab, omega, geom)[source]#

How much of a voxel the beam illuminates: its profile integrated over the voxel.

The beam’s profile across it, horizontally (geom["width_beam"], geom["sig_beam"]) and vertically (geom["width_beam_v"], geom["sig_beam_v"]), is a flat top of that width blurred by a Gaussian of that standard deviation, and integrates to 1: a wider beam spreads the same flux. A voxel is a square of side geom["voxel_size"] in the sample xy plane, rotated by omega, centred at pos_lab, and either:

  • a column (2D map, geom["voxel_3d"] false): the whole vertical profile crosses it, so it integrates out; a beam tilted by alpha out of the horizontal plane travels 1 / cos(alpha) further through it.

  • a cube (3D map): the vertical profile is integrated over the cube’s height, measured vertically. For a tilted beam this treats the horizontal and vertical directions separately, which is exact only when it is horizontal.

A beam at psi from lab x in the horizontal plane sees the voxel rotated by omega - psi.

Parameters:
Return type:

Array