magneticScattering.scatter.Beam#

class Beam(wavelength, fwhm, pol)#

Bases: object

Describes the properties of the beam.

Parameters:
wavelengthfloat

The wavelength of the beam in meters.

fwhmnp.ndarray | 2-tuple | 2-list

The full width at half maximum of the beam in the x and y directions.

pol4-list of float

The polarization of the beam in Stokes parameters.

Methods

calc_density_matrix

Converts the Stokes polarization vector to a density matrix

Attributes

degree_of_pol

The degree of polarisation.

density_matrix

Polarization density matrix.

fwhm

The full width at half maximum of the beam.

pol

The polarisation of the beam.

sigma

The spread of the beam.

tracker

Function to notify parent of any changes to the class.

wavelength

The wavelength of the beam.

calc_density_matrix()#

Converts the Stokes polarization vector to a density matrix

Returns:
np.ndarray

The density matrix of the beam.

np.ndarray

The degree of polarization.

Notes

The expression for converting the Strokes polarization “vector” to a density matrix is:

\[\rho = \frac{1}{2}(\vec{P} \cdot \vec{\sigma})\]

where \(\vec{P}\) is the Stokes polarization vector and \(\sigma\) is the vector containing the Pauli spin matrices and the identity matrix \((\sigma_0 = \mathbf{I})\).

property degree_of_pol#

The degree of polarisation.

property density_matrix#

Polarization density matrix.

property fwhm#

The full width at half maximum of the beam.

property pol#

The polarisation of the beam.

property sigma#

The spread of the beam.

property tracker#

Function to notify parent of any changes to the class.

property wavelength#

The wavelength of the beam.