Refocusing trains

Refocusing trains#

Refocusing flip angles designed from the echo signal they are to give. The functions take and return NumPy arrays in degrees and ms, run on the host in double precision, and do not import PyTorch: import blochsim.trains costs what NumPy costs.

prescribed_flips() inverts the extended phase graph of a CPMG train one echo at a time: the flip angle of each pulse is the smallest whose echo has the prescribed amplitude, with or without relaxation. busse_flips() builds on it the variable-flip-angle trains of long 3D fast spin echo readouts, and busse_centre_echo() places their centre echo for a contrast-equivalent echo time, which effective_te() computes for any train. A batch of trains is solved in one call, across threads.

Each of them also gives exact derivatives, for designing a train against a cost: prescribed_flips() along changes of the prescribed signal and of the first angle, effective_te() along changes of the flip angles, and busse_flips() with respect to its three angles. They are carried through the same echo-by-echo recursion in forward mode, one extra set of states per direction, so a few directions cost a few inversions.

Object

Description

prescribed_flips

Flip angles whose echoes take prescribed amplitudes, and the echoes they give.

effective_te

Contrast-equivalent echo time of every echo of a train.

busse_flips

Variable flip angles with a prescribed lowest, centre and highest angle.

busse_centre_echo

Centre echo whose contrast-equivalent echo time is nearest a target.