Analyzer

class nexus.Analyzer(efficiency=0, mixing_angle=0, canting_angle=0, id='')

Bases: NxObject

Constructor for the Analyzer class. Analyzer objects are only considered in polarization dependent nuclear calculations. In pure electronic calculations the beam has no polarization information. The default arguments set unpolarized detection. See Eq.(9), [Sturhahn2000], however, the canting angle given in Nexus is multiplied by 2 to give a polarization of \(\pi\) at 90 degree.

Parameters:
  • efficiency (float) – Polarization efficiency of the detection process, 0 to 1.

  • mixing_angle (float) –

    Mixing angle (deg).

    • 0 degree linear polarization.

    • +90 degree circular left polarization.

    • -90 degree circular right polarization.

  • canting_angle (float) – Canting angle of the analyzer with respect to \(\sigma\) direction (deg).

  • id (string) – User identifier.

scattering_factor

Electronic scattering factor of the object. The default value is 1+0j. This value should only be changed if you know what you are doing.

Type:

complex

matrix

2x2 complex Jones matrix of the analyzer.

Type:

ndarray

id

User identifier.

Type:

string

CircularLeft()

Set the analyzer to detection of circular left polarized light.

CircularRight()

Set the analyzer to detection of circular right polarized light.

ElectronicAmplitude(energy)

Electronic scattering amplitude of the analyzer. This is always one, i.e. no absorption is considered in pure electronic calculations. In order to calculate polarization effect, use the fully polarization dependent nuclear calculations.

Parameters:

energy (float) – Not used.

Returns:

1+0j.

Return type:

complex

ElectronicAmplitudeMatrix(energy)

Electronic scattering matrix of the analyzer. Same as the matrix.

Parameters:

energy (float) – Not used.

Returns:

2x2 scattering matrix.

Return type:

list

LinearPi()

Set the analyzer to polarized detection along \(\pi\) direction.

LinearSigma()

Set the analyzer to polarized detection along \(\sigma\) direction.

ObjectMatrix(isotope, detuning, calc_transitions)

Scattering matrix of the analyzer. Returns the constant matrix on the given detuning values.

Parameters:
  • isotope (MoessbauerIsotope) – Not used.

  • detuning (list or ndarray) – Detuning values.

  • calc_transitions (bool) – not used.

Returns:

List of the complex 2x2 analyzer matrix.

Return type:

list

Rotate(angle)

Rotate the analyzer by the given angle.

Parameters:

angle (float) – angle of rotation (degree).

SetJonesMatrix(matrix)

Set the Jones matrix directly by a complex 2x2 array.

Parameters:

matrix (ndarray) – a complex 2x2 Jones matrix.

Unpolarized()

Set the analyzer to unpolarized detection.

Different ways to define an Analyzer.

# initialize analyzer
analyzer = nx.Analyzer()

# set to linear polarizer analysis along sigma direction
analyzer.LinearSigma()

print(analyzer.matrix)

# redefine analyzer matrix to unpolarized detection
analyzer.Unpolarized()
# set polarizer along sigma polarization via initialization parameters
analyzer = nx.Analyzer(efficiency = 1, mixing_angle = 0)
# set polarizer along pi polarization via initialization parameters
analyzer = nx.Analyzer(efficiency = 1, mixing_angle = 0, canting_angle = 90)
analyzer = nx.Analyzer()

# set Jones matrix directly to unpolarized detection
analyzer.SetJonesMatrix(np.array([[1,0], [0, 1]], dtype=complex))