c3.libraries.envelopes

Library of envelope functions.

All functions assume the input of a time vector and return complex amplitudes.

Module Contents

c3.libraries.envelopes.env_reg_deco(func)[source]

Decorator for making registry of functions

c3.libraries.envelopes.no_drive(t, params=None)[source]

Do nothing.

c3.libraries.envelopes.pwc(t, params)[source]

Piecewise constant pulse.

c3.libraries.envelopes.pwc_shape(t, params)[source]

Piecewise constant pulse while defining only a given number of samples, while interpolating linearly between those. :param t: :param params: t_bin_start/t_bin_end can be used to specify specific range. e.g. timepoints taken from awg.

c3.libraries.envelopes.pwc_symmetric(t, params)[source]

symmetic PWC pulse This works only for inphase component

c3.libraries.envelopes.delta_pulse(t, params)[source]

Pulse shape which gives an output only at a given time bin

c3.libraries.envelopes.fourier_sin(t, params)[source]

Fourier basis of the pulse constant pulse (sin).

Parameters

params (dict) –

ampslist

Weights of the fourier components

freqslist

Frequencies of the fourier components

c3.libraries.envelopes.fourier_cos(t, params)[source]

Fourier basis of the pulse constant pulse (cos).

Parameters

params (dict) –

ampslist

Weights of the fourier components

freqslist

Frequencies of the fourier components

c3.libraries.envelopes.rect(t, params=None)[source]

Rectangular pulse. Returns 1 at every time step.

c3.libraries.envelopes.trapezoid(t, params)[source]

Trapezoidal pulse. Width of linear slope.

Parameters

params (dict) –

t_finalfloat

Total length of pulse.

risefallfloat

Length of the slope

c3.libraries.envelopes.flattop_risefall(t, params)[source]

Flattop gaussian with width of length risefall, modelled by error functions.

Parameters

params (dict) –

t_finalfloat

Total length of pulse.

risefallfloat

Length of the ramps. Position of ramps is so that the pulse starts with the start of the ramp-up and ends at the end of the ramp-down

c3.libraries.envelopes.flattop(t, params)[source]

Flattop gaussian with width of length risefall, modelled by error functions.

Parameters

params (dict) –

t_upfloat

Center of the ramp up.

t_downfloat

Center of the ramp down.

risefallfloat

Length of the ramps.

c3.libraries.envelopes.flattop_cut(t, params)[source]

Flattop gaussian with width of length risefall, modelled by error functions.

Parameters

params (dict) –

t_upfloat

Center of the ramp up.

t_downfloat

Center of the ramp down.

risefallfloat

Length of the ramps.

c3.libraries.envelopes.flattop_cut_center(t, params)[source]

Flattop gaussian with width of length risefall, modelled by error functions.

Parameters

params (dict) –

t_upfloat

Center of the ramp up.

t_downfloat

Center of the ramp down.

risefallfloat

Length of the ramps.

c3.libraries.envelopes.slepian_fourier(t, params)[source]
c3.libraries.envelopes.flattop_risefall_1ns(t, params)[source]

Flattop gaussian with fixed width of 1ns.

c3.libraries.envelopes.gaussian_sigma(t, params)[source]

Normalized gaussian. Total area is 1, maximum is determined accordingly.

Parameters

params (dict) –

t_finalfloat

Total length of the Gaussian.

sigma: float

Width of the Gaussian.

c3.libraries.envelopes.gaussian(t, params)

Normalized gaussian with fixed time/sigma ratio.

Parameters

params (dict) –

t_finalfloat

Total length of the Gaussian.

c3.libraries.envelopes.cosine(t, params)[source]

Cosine-shaped envelope. Maximum value is 1, area is given by length.

Parameters

params (dict) –

t_finalfloat

Total length of the Gaussian.

sigma: float

Width of the Gaussian.

c3.libraries.envelopes.cosine_flattop(t, params)[source]

Cosine-shaped envelope. Maximum value is 1, area is given by length.

Parameters

params (dict) –

t_finalfloat

Total length of the Gaussian.

sigma: float

Width of the Gaussian.

c3.libraries.envelopes.gaussian_nonorm(t, params)[source]

Non-normalized gaussian. Maximum value is 1, area is given by length.

Parameters

params (dict) –

t_finalfloat

Total length of the Gaussian.

sigma: float

Width of the Gaussian.

c3.libraries.envelopes.gaussian_der_nonorm(t, params)[source]

Derivative of the normalized gaussian (ifself not normalized).

c3.libraries.envelopes.gaussian_der(t, params)[source]

Derivative of the normalized gaussian (ifself not normalized).

c3.libraries.envelopes.drag_sigma(t, params)[source]

Second order gaussian.

c3.libraries.envelopes.drag(t, params)

Second order gaussian with fixed time/sigma ratio.

c3.libraries.envelopes.drag_der(t, params)[source]

Derivative of second order gaussian.

c3.libraries.envelopes.flattop_variant(t, params)[source]

Flattop variant.