class qctrlopencontrols.DynamicDecouplingSequence(duration, offsets, rabi_rotations, azimuthal_angles, detuning_rotations, name=None)

Creates a dynamic decoupling sequence.


  • duration (float) – The total time in seconds for the sequence τ\tau
  • offsets (np.ndarray) – The times offsets {tj}\{t_j\}
  • rabi_rotations (np.ndarray) – The Rabi rotation ωj\omega_j at each time offset tjt_j
  • azimuthal_angles (np.ndarray) – The azimuthal angle ϕj\phi_j at each time offset tjt_j
  • detuning_rotations (np.ndarray) – The detuning rotation δj\delta_j at each time offset tjt_j
  • name (str , optional) – Name of the sequence. Defaults to None.


Dynamical decoupling sequence (DDS) is canonically defined as a series of nn-instantaneous unitary operations, often π\pi-pulses, executed at time offsets {tj}j=1n\{t_j\}_{j=1}^n over the time interval with a total duration τ\tau. The jj-th operation applied at time tjt_j

Uj=exp[i2(ωjcosϕjσx+ωjsinϕjσy+δjσz)]  , U_j = \exp\left[-\frac{i}{2}(\omega_j \cos \phi_j \sigma_x + \omega_j\sin \phi_j\sigma_y + \delta_j\sigma_z)\right] \;,

Note that in practice all DDSs typically have a Xπ/2X_{\pi/2} operation at the start t=0t = 0 and end t=τt = \tau of the sequence. This is because it is assumed that the qubit is initially in the state 0|0\rangle


exportReturns a dictionary for plotting using the Q-CTRL Visualizer package.
export_to_filePrepares and saves the dynamical decoupling sequence in a file.

Was this useful?