mrf_sim

Contents

mrf_sim#

blochsim.mrf_sim()[source]#

Simulate an unbalanced SSFP MR fingerprinting train.

MR fingerprinting with a FISP train: an inversion, then one excitation and one readout per TR, with flip angles and phases varying along the train. The readout gradient is unbalanced, and the signal is one complex sample per flip angle from the last playing of the train, simulated with extended phase graphs. Wraps MRFSimulator.

Parameters:
  • flip (array-like) – Excitation flip angles, in degrees, one per TR; their number is the train length.

  • TR (float or array-like) – Repetition time, in ms; scalar or one per TR.

  • T1 (float or array-like) – Longitudinal relaxation time, in ms.

  • T2 (float or array-like) – Transverse relaxation time, in ms.

  • diff (str or tuple of str, default=None) – Names of the properties to differentiate with respect to. None returns the signal alone.

  • B1 (float or array-like, default=1.0) – Transmit field, as a fraction of the nominal flip angle.

  • inv_efficiency (float or array-like, default=1.0) – Inversion efficiency, as a fraction of a perfect inversion.

  • M0 (float or array-like, default=1.0) – Equilibrium magnetization.

  • TI (float, default=0.0) – Delay from the inversion to the first excitation, in ms.

  • phases (float or array-like, default=0.0) – Excitation RF phases, in degrees; scalar or one per TR.

  • states (int, default=10) – Configuration orders retained by the extended-phase-graph simulation.

  • nreps (int, default=1) – Playings of the train; the last is the signal. Passed to the simulator as repetitions.

  • device (str or torch.device, default=None) – Device to run on. None follows the inputs.

  • **values – Any further property or protocol argument of the simulator, such as B0 or B1, passed to simulate(). Arguments given as None are dropped.

Returns:

  • signal (complex array-like) – Signal of shape (..., len(flip)), where ... is the broadcast shape of the tissue properties.

  • jacobian (same array type as signal) – Derivatives of the signal with respect to diff, of shape (..., len(diff), len(flip)). Returned only when diff is given; a single name omits the len(diff) axis.