iqm.pulse.playlist.fast_drag.solve_fast_coefficients_for_given_weights_and_ranges

iqm.pulse.playlist.fast_drag.solve_fast_coefficients_for_given_weights_and_ranges#

iqm.pulse.playlist.fast_drag.solve_fast_coefficients_for_given_weights_and_ranges(number_of_cosines, pulse_duration, weights_tuple, suppressed_freq_ranges_2d_tuple, n_points_for_integration=60)#

Solve for optimal coefficients of the basis functions in a FAST DRAG pulse.

Computes the optimal coefficients {cn}n=1N for a FAST DRAG pulse with N basis functions such that the pulse spectrum is suppressed across the given frequency ranges according to the provided weights. The computation is based on Eqs. (A5), (A7), (A12) and (A13) of [1].

Note that this function essentially computes the mapping from frequency-domain parameters of a FAST DRAG pulse to time-domain parameters.

The results must be cached to allow efficient generation of playlists containing a large number of pulses with same parameters, as in RB.

Parameters:
  • number_of_cosines (int) – Number of cosine basis functions used in the FAST DRAG pulse

  • pulse_duration (float) – Pulse duration (in s) without zero padding.

  • weights_tuple (tuple[float, ...]) – 1d tuple of weights for each suppressed frequency interval used in the objective function

  • suppressed_freq_ranges_2d_tuple (tuple[tuple[float, ...], ...]) – 2d tuple describing the frequency ranges (in Hz), over which we want to suppress the Fourier transform. Each element of the outer tuple should be a tuple of two floats, the first setting the starting frequency for the given range and the second setting the ending frequency for the given range.

  • n_points_for_integration (int) – Number of points at which the integrand is evaluated for each interval. At least 50 points are recommended for the numerical approximation error to be low.

Returns:

Coefficients of the basis functions as a 1d array.

Return type:

ndarray