The matrix formalism is a general framework for evaluating the diffusion NMR signal from restricted spins under generalised gradient waveforms. The original publications demonstrate the method for waveforms that vary only in magnitude and have fixed orientation. In this work, we extend the method to allow for variations in the direction of the gradient. This extension is necessary, for example to incorporate the effects of crusher gradients or imaging gradients in diffusion MRI, to characterise signal anisotropy in double pulsed field gradient (dPFG) experiments, or to optimise the gradient waveform for microstructure sensitivity. In particular, we show for primitive geometries (planes, cylinders and spheres), how to express the matrix operators at each time point of the gradient waveform as a linear combination of one or two fundamental matrices. Thus we obtain an efficient implementation with both the storage and CPU demands similar to the fixed-orientation case. Comparison with Monte Carlo simulations validates the implementation on three different sequences: dPFG, helical waveforms and the stimulated echo (STEAM) sequence.
Copyright © 2011 Elsevier Inc. All rights reserved.