spgr_sim#
- blochsim.spgr_sim()[source]#
Simulate the spoiled gradient-echo steady-state signal.
Spoiled gradient-recalled echo (SPGR, FLASH, T1-FFE) in closed form: the Ernst steady state, attenuated by
T2stardecay and rotated by the off-resonance phase accrued up to the echo time. WrapsSPGRSimulator.- Parameters:
flip (float or array-like) – Excitation flip angle, in degrees. An array adds a trailing contrast axis.
TE (float or array-like) – Echo time, in ms.
TR (float) – Repetition time, in ms.
T1 (float or array-like) – Longitudinal relaxation time, in ms.
T2star (float or array-like) – Effective transverse relaxation time, in ms.
diff (str or tuple of str, default=None) – Names of the properties to differentiate with respect to.
Nonereturns the signal alone.B0 (float or array-like, default=0.0) – Off-resonance, in Hz.
chemshift (float or array-like, default=0.0) – Chemical shift of the spins, in Hz, added to the off-resonance.
M0 (float or array-like, default=1.0) – Equilibrium magnetization.
device (str or torch.device, default=None) – Device to run on.
Nonefollows the inputs.**values – Any further property or protocol argument of the simulator, such as
B0orB1, passed tosimulate(). Arguments given asNoneare 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 todiff, of shape(..., len(diff), len(flip)). Returned only whendiffis given; a single name omits thelen(diff)axis.