Pulse.FromPowerSpectrum#

classmethod Pulse.FromPowerSpectrum(p_v, n, v_min, v_max, v0=None, e_p=None, phi_v=None, **kwargs)[source]#

Initialize a pulse using existing spectral data.

Parameters:
p_vcallable -> array_like of float

The power spectrum.

nint, optional

The number of grid points.

v_minfloat, optional

The target minimum frequency.

v_maxfloat, optional

The target maximum frequency.

v0float, optional

The comoving-frame reference frequency. The default value is the center of the resulting frequency grid.

e_pfloat, optional

The pulse energy. The default inherits the pulse energy of the input spectrum.

phi_vcallable -> array_like of float, optional

The phase of the power spectrum. The default initializes a transform limited pulse.