Event

class mrsimulator.Event(*, property_units: Dict = {'magnetic_flux_density': 'T', 'rotor_angle': 'rad', 'rotor_frequency': 'Hz'}, fraction: float = 1.0, magnetic_flux_density: mrsimulator.method.event.ConstrainedFloatValue = 9.4, rotor_frequency: mrsimulator.method.event.ConstrainedFloatValue = 0.0, rotor_angle: mrsimulator.method.event.ConstrainedFloatValue = 0.955316618, freq_contrib: List[mrsimulator.method.frequency_contrib.FrequencyEnum] = [<FrequencyEnum.Shielding1_0: 'Shielding1_0'>, <FrequencyEnum.Shielding1_2: 'Shielding1_2'>, <FrequencyEnum.Quad1_2: 'Quad1_2'>, <FrequencyEnum.Quad2_0: 'Quad2_0'>, <FrequencyEnum.Quad2_2: 'Quad2_2'>, <FrequencyEnum.Quad2_4: 'Quad2_4'>], transition_query: mrsimulator.method.transition_query.TransitionQuery = TransitionQuery(P={'channel-1': [[-1.0]]}, D=None, F=None, transitions=None))

Bases: mrsimulator.utils.parseable.Parseable

Base Event class defines the spin environment and the transition query for a segment of the transition pathway.

fraction

The weight of the frequency contribution from the event. The default is 1.

Type

float

magnetic_flux_density

The macroscopic magnetic flux density, \(H_0\), of the applied external magnetic field during the event in units of T. The default value is 9.4.

Type

float

rotor_frequency

The sample spinning frequency \(\nu_r\), during the event in units of Hz. The default value is 0.

Type

float

rotor_angle

The angle between the sample rotation axis and the applied external magnetic field vector, \(\theta\), during the event in units of rad. The default value is 0.9553166, i.e. the magic angle.

Type

float

freq_contrib

A list of FrequencyEnum enumeration. The default is all frequency enumerations.

Type

List[mrsimulator.method.frequency_contrib.FrequencyEnum]

transition_query

A TransitionQuery or an equivalent dict object listing the queries used in selecting the active transitions during the event. Only the active transitions from this query will contribute to the net frequency.

Type

mrsimulator.method.transition_query.TransitionQuery

Method Documentation

classmethod parse_dict_with_units(py_dict: dict)

Parse the physical quantities of an Event object from a python dictionary object.

Parameters

py_dict (dict) – Dict object

json() dict

Parse the class object to a JSON compliant python dictionary object, where the attribute value with physical quantity is expressed as a string with a value and a unit.