Full TDI Waveforms
TDI observable waveforms are produced in three main parts:
Produce a waveform in the frequency-domain amplitude (\(A(f)\)) and phase (\(\phi(f)\)) representation at the solar system barycenter (SSB). This also must include the time-frequency correspondence. This gives:
\[\tilde{h}_{lm}(f) = A_{lm}(f)e^{-i\phi(f)}.\]
Use the time frequency correspondence to compute the LISA response transfer functions: \(\mathcal{T}(f, t_{lm}(f))\), where \(t_{lm}(f)\) is the time-frequency correspondence.
\(A(f)\), \(\phi(f)\), and \(\mathcal{T}(f, t_{lm}(f))\) are computed on the same sparse grid in frequencies. The final step is interpolating to the frequencies of the Fourier transform of the data stream, producing the TDI observables (\(AET\)):
\[\tilde{h}^{AET}(f) = \sum_{lm}\mathcal{T}^{AET}(f, t_{lm}(f))\tilde{h}_{lm}(f).\]
- class bbhx.waveformbuild.BBHWaveformFD(amp_phase_kwargs={}, response_kwargs={}, interp_kwargs={}, use_gpu=False)
Bases:
object
Generate waveforms put through response functions
This class generates waveforms put through the LISA response function. In the future, ground-based analysis may be added. Therefore, it currently returns the TDI variables according the response keyword arguments given.
If you use this class, please cite arXiv:2005.01827 and arXiv:2111.01064, as well as the papers listed for the waveform and response given just below.
Right now, it is hard coded to produce the waveform with
PhenomHMAmpPhase
. This can also be used to produce PhenomD. See the docs for that waveform. The papers describing PhenomHM/PhenomD waveforms are here: arXiv:1708.00404, arXiv:1508.07250, and arXiv:1508.07253.The response function is the fast frequency domain response function from arXiv:1806.10734 and arXiv:2003.00357. It is implemented in
LISATDIResponse <bbhx.response.fastfdresponse.LISATDIResponse
.This class is GPU accelerated.
- Parameters:
amp_phase_kwargs (dict, optional) – Keyword arguments for the initialization of the ampltidue-phase waveform class:
PhenomHMAmpPhase
.response_kwargs (dict, optional) – Keyword arguments for the initialization of the response class:
LISATDIResponse <bbhx.response.fastfdresponse.LISATDIResponse
.interp_kwargs (dict, optional) – Keyword arguments for the initialization of the interpolation class:
TemplateInterpFD
.use_gpu (bool, optional) – If
True
, use a GPU. (Default:False
)
- amp_phase_gen
Waveform generation class.
- Type:
obj
- data_length
Length of the final output data.
- Type:
int
- interp_response
Interpolation class.
- Type:
obj
- length
Length of initial evaluations of waveform and response.
- Type:
int
- num_bin_all
Total number of binaries analyzed.
- Type:
int
- num_interp_params
Number of parameters to interpolate (9).
- Type:
int
- num_modes
Number of harmonic modes.
- Type:
int
- out_buffer_final
Array with buffer information with shape:
(self.num_interp_params, self.num_bin_all, self.num_modes, self.length)
. The order of the parameters is amplitude, phase, t-f, transferL1re, transferL1im, transferL2re, transferL2im, transferL3re, transferL3im.- Type:
xp.ndarray
- property use_gpu: bool
Whether to use a GPU.
- property xp: object
Numpy or Cupy
- property waveform_gen: callable
C/CUDA wrapped function for computing waveforms
- property citation
Citations for this class
- __call__(m1, m2, chi1z, chi2z, distance, phi_ref, f_ref, inc, lam, beta, psi, t_ref, t_obs_start=0.0, t_obs_end=1.0, freqs=None, length=None, modes=None, shift_t_limits=True, direct=False, compress=True, squeeze=False, fill=False, combine=False)
Generate the binary black hole frequency-domain TDI waveforms
- Parameters:
m1 (double scalar or np.ndarray) – Mass 1 in Solar Masses \((m1 > m2)\).
m2 (double or np.ndarray) – Mass 2 in Solar Masses \((m1 > m2)\).
chi1z (double or np.ndarray) – Dimensionless spin 1 (for Mass 1) in Solar Masses.
chi2z (double or np.ndarray) – Dimensionless spin 2 (for Mass 1) in Solar Masses.
distance (double or np.ndarray) – Luminosity distance in m.
phi_ref (double or np.ndarray) – Phase at
f_ref
.f_ref (double or np.ndarray) – Reference frequency at which
phi_ref
andt_ref
are set. Iff_ref == 0
, it will be set internally by the PhenomHM code to \(f_\text{max} = \text{max}(f^2A_{22}(f))\).inc (double or np.ndarray) – Inclination of the binary in radians \((\iota\in[0.0, \pi])\).
lam (double or np.ndarray) – Ecliptic longitude \((\lambda\in[0.0, 2\pi])\).
beta (double or np.ndarray) – Ecliptic latitude \((\beta\in[-\pi/2, \pi/2])\).
psi (double or np.ndarray) – Polarization angle in radians \((\psi\in[0.0, \pi])\).
t_ref (double or np.ndarray) – Reference time in seconds. It is set at
f_ref
.t_obs_start (double, optional) – Start time of observation in years in the LISA constellation reference frame. This is with reference to \(t=0\). (Default: 0.0)
t_obs_end (double, optional) – End time of observation in years in the LISA constellation reference frame. This is with reference to \(t=0\). (Default: 1.0)
freqs (np.ndarray, optional) – Frequencies at which to evaluate the final waveform. If
length
is also given, the interpolants interpolate to these frequencies. Iflength
is not given, the waveform amplitude, phase, and response will be directly evaluated at these frequencies. In this case, a 2D np.ndarray can also be provided. (Default:None
)length (int, optional) – Number of frequencies to use in sparse array for interpolation.
modes (list, optional) – Harmonic modes to use. If not given, they will default to those available in the waveform model. For PhenomHM: [(2,2), (3,3), (4,4), (2,1), (3,2), (4,3)]. For PhenomD: [(2,2)]. (Default:
None
)shift_t_limits (bool, optional) – If
False
,t_obs_start
andt_obs_end
are relative tot_ref
counting backwards in time. IfTrue
, those quantities are relative to \(t=0\). (Default:False
)direct (bool, optional) – If
True
, directly compute the waveform without interpolation. (Default:False
)compress (bool, optional) – If
True
, combine harmonics into single channel waveforms. (Default:True
)squeeze (bool, optional) – If
True
, remove any axes of length 1 from the final return information. (Default:False
)fill (bool, optional) – If
True
, fill data streams according to thecombine
keyword argument. If ``False, returns information for the fast likelihood functions.combine (bool, optional) – If
True
, combine all waveforms into the same output data stream. (Default:False
)
- Returns:
- Shape
(3, self.length, self.num_bin_all)
. Final waveform for each binary. If
direct==True
andcompress==True
. # TODO: switch dimensions?- xp.ndarray: Shape
(3, self.num_modes, self.length, self.num_bin_all)
. Final waveform for each binary. If
direct==True
andcompress==False
.- xp.ndarray: Shape
(3, self.data_length)
. Final waveform of all binaries in the same data stream. If
fill==True
andcombine==True
.- xp.ndarray: Shape
(self.num_bin_all, 3, self.data_length)
. Final waveform of all binaries in the same data stream. If
fill==True
andcombine==False
.- tuple: Information for fast likelihood functions.
First entry is
template_channels
property fromTemplateInterpFD
. Second entry isstart_inds
attribute fromself.interp_response
. Third entry islengths
attribute fromself.interp_response
.
- Shape
- Return type:
xp.ndarray
- Raises:
ValueError –
length
andfreqs
not given. Modes are given but not in a list.