LALSimulation  5.4.0.1-fe68b98
LALSimInspiralTaylorT1.c
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2008 J. Creighton, S. Fairhurst, B. Krishnan, L. Santamaria, D. Keppel, Evan Ochsner, Les Wade
3  *
4  * This program is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation; either version 2 of the License, or
7  * (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with with program; see the file COPYING. If not, write to the
16  * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
17  * MA 02110-1301 USA
18  */
19 
20 #include <math.h>
21 
22 #include <gsl/gsl_const.h>
23 #include <gsl/gsl_errno.h>
24 #include <gsl/gsl_math.h>
25 #include <gsl/gsl_odeiv.h>
26 
27 #include <lal/LALSimInspiral.h>
28 #include <lal/LALAdaptiveRungeKuttaIntegrator.h>
29 #include <lal/LALConstants.h>
30 #include <lal/LALStdlib.h>
31 #include <lal/TimeSeries.h>
32 #include <lal/Units.h>
33 
36 #include "check_series_macros.h"
37 
38 #ifdef __GNUC__
39 #define UNUSED __attribute__ ((unused))
40 #else
41 #define UNUSED
42 #endif
43 
44 /* v at isco */
45 #define LALSIMINSPIRAL_T1_VISCO 1.L/sqrt(6.L)
46 /* use error codes above 1024 to avoid conflicts with GSL */
47 #define LALSIMINSPIRAL_T1_TEST_ISCO 1025
48 /* Number of variables used for these waveforms */
49 #define LALSIMINSPIRAL_NUM_T1_VARIABLES 2
50 /* absolute and relative tolerance for adaptive Runge-Kutta ODE integrator */
51 #define LALSIMINSPIRAL_T1_ABSOLUTE_TOLERANCE 1.e-12
52 #define LALSIMINSPIRAL_T1_RELATIVE_TOLERANCE 1.e-12
53 
54 /*
55  * This structure contains the intrinsic parameters and post-newtonian
56  * co-efficients for the denergy/dv and flux expansions.
57  * These are computed by XLALSimInspiralTaylorT1Setup routine.
58  */
59 
60 typedef struct
61 {
62  /* Angular velocity coefficient */
64 
65  /* Taylor expansion coefficents in domega/dt */
67 
68  /* symmetric mass ratio and total mass */
69  REAL8 nu,m,mchirp,chi1,chi2,lambda1,lambda2;
71 
73  REAL8 v, /**< post-Newtonian parameter */
74  expnCoeffsdEnergyFlux *ak /**< Taylor expansion coefficents */
75 );
76 
78  REAL8 v, /**< post-Newtonian parameter */
79  expnCoeffsdEnergyFlux *ak /**< Taylor expansion coefficents */
80 );
81 
83  REAL8 v, /**< post-Newtonian parameter */
84  expnCoeffsdEnergyFlux *ak /**< Taylor expansion coefficents */
85 );
86 
87 /*
88  * This strucuture contains pointers to the functions for calculating
89  * the post-newtonian terms at the desired order. They can be set by
90  * XLALSimInspiralTaylorT1Setup by passing an appropriate PN order.
91  */
92 
93 typedef struct
94 tagexpnFuncTaylorT1
95 {
100 
101 typedef struct
102 {
107 
108 /*
109  * This function is used in the call to the integrator.
110  */
111 static int
112 XLALSimInspiralTaylorT1PNEvolveOrbitIntegrand(double UNUSED t, const double y[], double ydot[], void *params)
113 {
115  ydot[0] = -p->ak.av*p->flux(y[0],&p->ak.akdEF)/p->dEdv(y[0],&p->ak.akdEF);
116  ydot[1] = y[0]*y[0]*y[0]*p->ak.av;
117  return GSL_SUCCESS;
118 }
119 
120 
121 /*
122  * This function is used in the call to the integrator to determine the stopping condition.
123  */
124 static int
125 XLALSimInspiralTaylorT1StoppingTest(double UNUSED t, const double y[], double UNUSED ydot[], void UNUSED *params)
126 {
127  if (y[0] >= LALSIMINSPIRAL_T1_VISCO) /* frequency above ISCO */
129  else /* Step successful, continue integrating */
130  return GSL_SUCCESS;
131 }
132 
133 
134 /*
135  * Set up the expnCoeffsTaylorT1 and expnFuncTaylorT1 structures for
136  * generating a TaylorT1 waveform and select the post-newtonian
137  * functions corresponding to the desired order.
138  *
139  * Inputs given in SI units.
140  */
141 static int
143  expnCoeffsTaylorT1 *ak, /**< coefficients for TaylorT1 evolution [modified] */
144  expnFuncTaylorT1 *f, /**< functions for TaylorT1 evolution [modified] */
145  REAL8 m1, /**< mass of companion 1 (kg) */
146  REAL8 m2, /**< mass of companion 2 (kg) */
147  REAL8 lambda1, /**< (tidal deformability of body 1)/(mass of body 1)^5 */
148  REAL8 lambda2, /**< (tidal deformability of body 2)/(mass of body 2)^5 */
149  LALSimInspiralTidalOrder tideO, /**< twice PN order of tidal effects */
150  int O /**< twice post-Newtonian order */
151 )
152 {
153  ak->m = m1 + m2;
154  REAL8 mu = m1 * m2 / ak->m;
155  ak->nu = mu/ak->m;
156  ak->chi1 = m1/ak->m;
157  ak->chi2 = m2/ak->m;
158  ak->mchirp = ak->m * pow(ak->nu, 0.6);
159  /* convert mchirp from kg to s */
160  ak->mchirp *= LAL_G_SI / pow(LAL_C_SI, 3.0);
161 
162  /* Angular velocity co-efficient */
163  ak->av = pow(LAL_C_SI, 3.0)/(LAL_G_SI*ak->m);
164 
165  /* Taylor co-efficients for E(v). */
170 
171  /* Taylor co-efficients for dE(v)/dv. */
172  ak->akdEF.dETaN = 2.0 * ak->akdEF.ETaN;
173  ak->akdEF.dETa1 = 2.0 * ak->akdEF.ETa1;
174  ak->akdEF.dETa2 = 3.0 * ak->akdEF.ETa2;
175  ak->akdEF.dETa3 = 4.0 * ak->akdEF.ETa3;
176 
177  /* Taylor co-efficients for flux. */
186 
187  /* Tidal co-efficients for E(v), dE/dv, and flux */
188  ak->akdEF.ETa5 = 0.;
189  ak->akdEF.ETa6 = 0.;
190  ak->akdEF.FTa10 = 0.;
191  ak->akdEF.FTa12 = 0.;
192  switch( tideO )
193  {
198 #if __GNUC__ >= 7 && !defined __INTEL_COMPILER
199  __attribute__ ((fallthrough));
200 #endif
204 #if __GNUC__ >= 7 && !defined __INTEL_COMPILER
205  __attribute__ ((fallthrough));
206 #endif
208  break;
209  default:
210  XLALPrintError("XLAL Error - %s: Invalid tidal PN order %d\nSee LALSimInspiralTidalOrder enum in LALSimInspiralWaveformFlags.h for valid tidal orders.\n",
211  __func__, tideO );
213  break;
214  }
215  ak->akdEF.dETa5 = 6.0 * ak->akdEF.ETa5;
216  ak->akdEF.dETa6 = 7.0 * ak->akdEF.ETa6;
217 
218  switch (O)
219  {
220  case 0:
223  f->flux = &XLALSimInspiralFt0;
224  break;
225  case 1:
226  XLALPrintError("XLAL Error - %s: PN approximant not supported for PN order %d\n", __func__,O);
228  break;
229  case 2:
232  f->flux = &XLALSimInspiralFt2;
233  break;
234  case 3:
237  f->flux = &XLALSimInspiralFt3;
238  break;
239  case 4:
242  f->flux = &XLALSimInspiralFt4;
243  break;
244  case 5:
247  f->flux = &XLALSimInspiralFt5;
248  break;
249  case 6:
252  f->flux = &XLALSimInspiralFt6;
253  break;
254  case 7:
255  case -1:
258  f->flux = &XLALSimInspiralFt7;
259  break;
260  case 8:
261  XLALPrintError("XLAL Error - %s: PN approximant not supported for PN order %d\n", __func__,O);
263  break;
264  default:
265  XLALPrintError("XLAL Error - %s: Unknown PN order in switch\n", __func__);
267  }
268 
269  return 0;
270 }
271 
272 /**
273  * @addtogroup LALSimInspiralTaylorXX_c
274  * @brief Routines to produce Taylor -T1, -T2, -T3, -T4, -F2, and -Et inspiral
275  * waveforms.
276  * @{
277  * @name Routines for TaylorT1 Waveforms
278  * @sa
279  * Section IIIA of Alessandra Buonanno, Bala R Iyer, Evan
280  * Ochsner, Yi Pan, and B S Sathyaprakash, "Comparison of post-Newtonian
281  * templates for compact binary inspiral signals in gravitational-wave
282  * detectors", Phys. Rev. D 80, 084043 (2009), arXiv:0907.0700v1
283  * @{
284  */
285 
286 /**
287  * Evolves a post-Newtonian orbit using the Taylor T1 method.
288  *
289  * See Section IIIA: Alessandra Buonanno, Bala R Iyer, Evan
290  * Ochsner, Yi Pan, and B S Sathyaprakash, "Comparison of post-Newtonian
291  * templates for compact binary inspiral signals in gravitational-wave
292  * detectors", Phys. Rev. D 80, 084043 (2009), arXiv:0907.0700v1
293  */
295  REAL8TimeSeries **V, /**< post-Newtonian parameter [returned] */
296  REAL8TimeSeries **phi, /**< orbital phase [returned] */
297  REAL8 phiRef, /**< reference orbital phase (rad) */
298  REAL8 deltaT, /**< sampling interval (s) */
299  REAL8 m1, /**< mass of companion 1 (kg) */
300  REAL8 m2, /**< mass of companion 2 (kg) */
301  REAL8 f_min, /**< starting GW frequency (Hz) */
302  REAL8 fRef, /**< reference GW frequency (Hz) */
303  REAL8 lambda1, /**< (tidal deformability of body 1)/(mass of body 1)^5 */
304  REAL8 lambda2, /**< (tidal deformability of body 2)/(mass of body 2)^5 */
305  LALSimInspiralTidalOrder tideO, /**< flag to control spin and tidal effects */
306  int O /**< twice post-Newtonian order */
307  )
308 {
309  double lengths, VRef = 0.;
310  int len, intreturn, idx, idxRef = 0;
312  LALAdaptiveRungeKuttaIntegrator *integrator = NULL;
313  expnFuncTaylorT1 expnfunc;
315 
316  if(XLALSimInspiralTaylorT1Setup(&ak,&expnfunc,m1,m2,lambda1,lambda2,tideO,O))
318 
319  params.flux=expnfunc.flux;
320  params.dEdv=expnfunc.dEnergy;
321  params.ak=ak;
322 
324  double yinit[LALSIMINSPIRAL_NUM_T1_VARIABLES];
325  REAL8Array *yout;
326 
327  /* length estimation (Newtonian) */
328  /* since integration is adaptive, we could use a better estimate */
329  lengths = (5.0/256.0) * pow(LAL_PI, -8.0/3.0) * pow(f_min * ak.mchirp, -5.0/3.0) / f_min;
330 
331  yinit[0] = cbrt(LAL_PI * LAL_G_SI * ak.m * f_min) / LAL_C_SI;
332  yinit[1] = 0.;
333 
334  /* initialize the integrator */
339  if( !integrator )
340  {
341  XLALPrintError("XLAL Error - %s: Cannot allocate integrator\n", __func__);
343  }
344 
345  /* stop the integration only when the test is true */
346  integrator->stopontestonly = 1;
347 
348  /* run the integration */
349  len = XLALAdaptiveRungeKutta4Hermite(integrator, (void *) &params, yinit, 0.0, lengths, deltaT, &yout);
350 
351  intreturn = integrator->returncode;
352  XLALAdaptiveRungeKuttaFree(integrator);
353 
354  if (!len)
355  {
356  XLALPrintError("XLAL Error - %s: integration failed with errorcode %d.\n", __func__, intreturn);
358  }
359 
360  /* Adjust tStart so last sample is at time=0 */
361  XLALGPSAdd(&tc, -1.0*(len-1)*deltaT);
362 
363  /* allocate memory for output vectors */
364  *V = XLALCreateREAL8TimeSeries( "ORBITAL_VELOCITY_PARAMETER", &tc, 0., deltaT, &lalDimensionlessUnit, len);
365  *phi = XLALCreateREAL8TimeSeries( "ORBITAL_PHASE", &tc, 0., deltaT, &lalDimensionlessUnit, len);
366 
367  if ( !V || !phi )
368  {
369  XLALDestroyREAL8Array(yout);
371  }
372 
373  /* Do a constant phase shift to get desired value of phiRef */
374  /* For fRef==0, phiRef is phase of last sample */
375  if( fRef == 0. )
376  phiRef -= yout->data[3*len-1];
377  /* For fRef==fmin, phiRef is phase of first sample */
378  else if( fRef == f_min )
379  phiRef -= yout->data[2*len];
380  /* phiRef is phase when f==fRef */
381  else
382  {
383  VRef = pow(LAL_PI * LAL_G_SI*(m1+m2) * fRef, 1./3.) / LAL_C_SI;
384  idx = 0;
385  do {
386  idxRef = idx;
387  idx++;
388  } while (yout->data[len+idx] <= VRef);
389  phiRef -= yout->data[2*len+idxRef];
390  }
391 
392  /* Copy time series of dynamical variables */
393  /* from yout array returned by integrator to output time series */
394  /* Note the first 'len' members of yout are the time steps */
395  for( idx = 0; idx < len; idx++ )
396  {
397  (*V)->data->data[idx] = yout->data[len+idx];
398  (*phi)->data->data[idx] = yout->data[2*len+idx] + phiRef;
399  }
400 
401  XLALDestroyREAL8Array(yout);
402 
403  return (int)(*V)->data->length;
404 }
405 
406 
407 /**
408  * Driver routine to compute the post-Newtonian inspiral waveform.
409  *
410  * This routine allows the user to specify different pN orders
411  * for phasing calcuation vs. amplitude calculations.
412  */
414  REAL8TimeSeries **hplus, /**< +-polarization waveform */
415  REAL8TimeSeries **hcross, /**< x-polarization waveform */
416  REAL8 phiRef, /**< reference orbital phase (rad) */
417  REAL8 v0, /**< tail-term gauge choice (default = 1) */
418  REAL8 deltaT, /**< sampling interval (s) */
419  REAL8 m1, /**< mass of companion 1 (kg) */
420  REAL8 m2, /**< mass of companion 2 (kg) */
421  REAL8 f_min, /**< starting GW frequency (Hz) */
422  REAL8 fRef, /**< reference GW frequency (Hz) */
423  REAL8 r, /**< distance of source (m) */
424  REAL8 i, /**< inclination of source (rad) */
425  REAL8 lambda1, /**< (tidal deformability of body 1)/(mass of body 1)^5 */
426  REAL8 lambda2, /**< (tidal deformability of body 2)/(mass of body 2)^5 */
427  LALSimInspiralTidalOrder tideO, /**< flag to control spin and tidal effects */
428  int amplitudeO, /**< twice post-Newtonian amplitude order */
429  int phaseO /**< twice post-Newtonian phase order */
430  )
431 {
432  /* The Schwarzschild ISCO frequency - for sanity checking fRef */
433  REAL8 fISCO = pow(LAL_C_SI,3) / (pow(6.,3./2.)*LAL_PI*(m1+m2)*LAL_G_SI);
434 
435  /* Sanity check fRef value */
436  if( fRef < 0. )
437  {
438  XLALPrintError("XLAL Error - %s: fRef = %f must be >= 0\n",
439  __func__, fRef);
441  }
442  if( fRef != 0. && fRef < f_min )
443  {
444  XLALPrintError("XLAL Error - %s: fRef = %f must be > fStart = %f\n",
445  __func__, fRef, f_min);
447  }
448  if( fRef >= fISCO )
449  {
450  XLALPrintError("XLAL Error - %s: fRef = %f must be < Schwar. ISCO=%f\n",
451  __func__, fRef, fISCO);
453  }
454 
456  REAL8TimeSeries *phi;
457  int status;
458  int n;
459  n = XLALSimInspiralTaylorT1PNEvolveOrbit(&V, &phi, phiRef, deltaT,
460  m1, m2, f_min, fRef, lambda1, lambda2, tideO, phaseO);
461  if ( n < 0 )
463  status = XLALSimInspiralPNPolarizationWaveforms(hplus, hcross, V, phi,
464  v0, m1, m2, r, i, amplitudeO);
467  if ( status < 0 )
469  return n;
470 }
471 
473  UNUSED REAL8 v0, /**< tail-term gauge choice (default = 1) */
474  REAL8 deltaT, /**< sampling interval (s) */
475  REAL8 m1, /**< mass of companion 1 (kg) */
476  REAL8 m2, /**< mass of companion 2 (kg) */
477  REAL8 f_min, /**< starting GW frequency (Hz) */
478  REAL8 fRef, /**< reference GW frequency (Hz) */
479  REAL8 r, /**< distance of source (m) */
480  REAL8 lambda1, /**< (tidal deformability of body 1)/(individual mass of body 1)^5 */
481  REAL8 lambda2, /**< (tidal deformability of body 2)/(individual mass of body 2)^5 */
482  LALSimInspiralTidalOrder tideO, /**< flag to control spin and tidal effects */
483  int amplitudeO, /**< twice post-Newtonian amplitude order */
484  int phaseO, /**< twice post-Newtonian phase order */
485  int lmax /**< generate all modes with l <= lmax */
486  )
487 {
488  SphHarmTimeSeries *hlm = NULL;
489  /* The Schwarzschild ISCO frequency - for sanity checking fRef */
490  REAL8 fISCO = pow(LAL_C_SI,3) / (pow(6.,3./2.)*LAL_PI*(m1+m2)*LAL_G_SI);
491 
492  /* Sanity check fRef value */
493  if( fRef < 0. )
494  {
495  XLALPrintError("XLAL Error - %s: fRef = %f must be >= 0\n",
496  __func__, fRef);
498  }
499  if( fRef != 0. && fRef < f_min )
500  {
501  XLALPrintError("XLAL Error - %s: fRef = %f must be > fStart = %f\n",
502  __func__, fRef, f_min);
504  }
505  if( fRef >= fISCO )
506  {
507  XLALPrintError("XLAL Error - %s: fRef = %f must be < Schwar. ISCO=%f\n",
508  __func__, fRef, fISCO);
510  }
511 
513  REAL8TimeSeries *phi;
514  int n;
516  m1, m2, f_min, fRef, lambda1, lambda2, tideO, phaseO);
517  if ( n < 0 )
519  int m, l;
520  COMPLEX16TimeSeries *hxx;
521  for(l=2; l<=lmax; l++){
522  for(m=-l; m<=l; m++){
524  m1, m2, r, amplitudeO, l, m);
525  if ( !hxx ){
527  }
528  hlm = XLALSphHarmTimeSeriesAddMode(hlm, hxx, l, m);
530  }
531  }
534  return hlm;
535 }
536 
537 /**
538  * Driver routine to compute the -2 spin-weighted spherical harmonic mode
539  * using TaylorT1 phasing.
540  */
542  UNUSED REAL8 v0, /**< tail-term gauge choice (default = 1) */
543  REAL8 deltaT, /**< sampling interval (s) */
544  REAL8 m1, /**< mass of companion 1 (kg) */
545  REAL8 m2, /**< mass of companion 2 (kg) */
546  REAL8 f_min, /**< starting GW frequency (Hz) */
547  REAL8 fRef, /**< reference GW frequency (Hz) */
548  REAL8 r, /**< distance of source (m) */
549  REAL8 lambda1, /**< (tidal deformability of body 1)/(individual mass of body 1)^5 */
550  REAL8 lambda2, /**< (tidal deformability of body 2)/(individual mass of body 2)^5 */
551  LALSimInspiralTidalOrder tideO, /**< flag to control spin and tidal effects */
552  int amplitudeO, /**< twice post-Newtonian amplitude order */
553  int phaseO, /**< twice post-Newtonian phase order */
554  int l, /**< l index of mode */
555  int m /**< m index of mode */
556  )
557 {
558  COMPLEX16TimeSeries *hlm;
559  /* The Schwarzschild ISCO frequency - for sanity checking fRef */
560  REAL8 fISCO = pow(LAL_C_SI,3) / (pow(6.,3./2.)*LAL_PI*(m1+m2)*LAL_G_SI);
561 
562  /* Sanity check fRef value */
563  if( fRef < 0. )
564  {
565  XLALPrintError("XLAL Error - %s: fRef = %f must be >= 0\n",
566  __func__, fRef);
568  }
569  if( fRef != 0. && fRef < f_min )
570  {
571  XLALPrintError("XLAL Error - %s: fRef = %f must be > fStart = %f\n",
572  __func__, fRef, f_min);
574  }
575  if( fRef >= fISCO )
576  {
577  XLALPrintError("XLAL Error - %s: fRef = %f must be < Schwar. ISCO=%f\n",
578  __func__, fRef, fISCO);
580  }
581 
583  REAL8TimeSeries *phi;
584  int n;
586  m1, m2, f_min, fRef, lambda1, lambda2, tideO, phaseO);
587  if ( n < 0 )
590  m1, m2, r, amplitudeO, l, m);
591  if ( !hlm )
595  return hlm;
596 }
597 
598 
599 /**
600  * Driver routine to compute the post-Newtonian inspiral waveform.
601  *
602  * This routine uses the same pN order for phasing and amplitude
603  * (unless the order is -1 in which case the highest available
604  * order is used for both of these -- which might not be the same).
605  *
606  * Constant log term in amplitude set to 1. This is a gauge choice.
607  */
609  REAL8TimeSeries **hplus, /**< +-polarization waveform */
610  REAL8TimeSeries **hcross, /**< x-polarization waveform */
611  REAL8 phiRef, /**< reference orbital phase (rad) */
612  REAL8 deltaT, /**< sampling interval (s) */
613  REAL8 m1, /**< mass of companion 1 (kg) */
614  REAL8 m2, /**< mass of companion 2 (kg) */
615  REAL8 f_min, /**< starting GW frequency (Hz) */
616  REAL8 fRef, /**< reference GW frequency (Hz) */
617  REAL8 r, /**< distance of source (m) */
618  REAL8 i, /**< inclination of source (rad) */
619  REAL8 lambda1, /**< (tidal deformability of body 1)/(mass of body 1)^5 */
620  REAL8 lambda2, /**< (tidal deformability of body 2)/(mass of body 2)^5 */
621  LALSimInspiralTidalOrder tideO, /**< flag to control spin and tidal effects */
622  int O /**< twice post-Newtonian order */
623  )
624 {
625  /* set v0 to default value 1 */
626  return XLALSimInspiralTaylorT1PNGenerator(hplus, hcross, phiRef, 1.0,
627  deltaT, m1, m2, f_min, fRef, r, i, lambda1, lambda2,
628  tideO, O, O);
629 }
630 
631 
632 /**
633  * Driver routine to compute the restricted post-Newtonian inspiral waveform.
634  *
635  * This routine computes the phasing to the specified order, but
636  * only computes the amplitudes to the Newtonian (quadrupole) order.
637  *
638  * Constant log term in amplitude set to 1. This is a gauge choice.
639  */
641  REAL8TimeSeries **hplus, /**< +-polarization waveform */
642  REAL8TimeSeries **hcross, /**< x-polarization waveform */
643  REAL8 phiRef, /**< reference orbital phase (rad) */
644  REAL8 deltaT, /**< sampling interval (s) */
645  REAL8 m1, /**< mass of companion 1 (kg) */
646  REAL8 m2, /**< mass of companion 2 (kg) */
647  REAL8 f_min, /**< starting GW frequency (Hz) */
648  REAL8 fRef, /**< reference GW frequency (Hz) */
649  REAL8 r, /**< distance of source (m)*/
650  REAL8 i, /**< inclination of source (rad) */
651  REAL8 lambda1, /**< (tidal deformability of body 1)/(mass of body 1)^5 */
652  REAL8 lambda2, /**< (tidal deformability of body 2)/(mass of body 2)^5 */
653  LALSimInspiralTidalOrder tideO, /**< flag to control spin and tidal effects */
654  int O /**< twice post-Newtonian phase order */
655  )
656 {
657  /* use Newtonian order for amplitude */
658  /* set v0 to default value 1 */
659  return XLALSimInspiralTaylorT1PNGenerator(hplus, hcross, phiRef, 1.0,
660  deltaT, m1, m2, f_min, fRef, r, i, lambda1, lambda2,
661  tideO, 0, O);
662 }
663 
664 /** @} */
665 /** @} */
666 
667 #if 0
668 #include <lal/PrintFTSeries.h>
669 #include <lal/PrintFTSeries.h>
670 int main(void)
671 {
672  LIGOTimeGPS tc = { 888888888, 222222222 };
673  REAL8 phic = 1.0;
674  REAL8 deltaT = 1.0/16384.0;
675  REAL8 m1 = 1.4*LAL_MSUN_SI;
676  REAL8 m2 = 1.4*LAL_MSUN_SI;
677  REAL8 r = 1e6*LAL_PC_SI;
678  REAL8 i = 0.5*LAL_PI;
679  REAL8 f_min = 100.0;
680  REAL8 fRef = 0.;
681  int O = -1;
682  REAL8TimeSeries *hplus;
683  REAL8TimeSeries *hcross;
684  XLALSimInspiralTaylorT1PN(&hplus, &hcross, &tc, phic, deltaT, m1, m2, f_min, fRef, r, i, lambda1, lambda2, tideO, O);
685  LALDPrintTimeSeries(hplus, "hp.dat");
686  LALDPrintTimeSeries(hcross, "hc.dat");
690  return 0;
691 }
692 #endif
void LALCheckMemoryLeaks(void)
static REAL8 UNUSED XLALSimInspiralPNFlux_5PNCoeff(REAL8 eta)
static REAL8 UNUSED XLALSimInspiralPNEnergy_4PNCoeff(REAL8 eta)
static REAL8 UNUSED XLALSimInspiralPNFlux_0PNCoeff(REAL8 eta)
Computes the flux PN Coefficients.
static REAL8 UNUSED XLALSimInspiralPNEnergy_10PNTidalCoeff(REAL8 mByM)
static REAL8 UNUSED XLALSimInspiralPNFlux_12PNTidalCoeff(REAL8 mByM)
static REAL8 UNUSED XLALSimInspiralPNFlux_3PNCoeff(REAL8 UNUSED eta)
static REAL8 UNUSED XLALSimInspiralPNEnergy_2PNCoeff(REAL8 eta)
static REAL8 UNUSED XLALSimInspiralPNFlux_4PNCoeff(REAL8 eta)
static REAL8 UNUSED XLALSimInspiralPNEnergy_0PNCoeff(REAL8 eta)
Computes the PN Coefficients for using in the PN energy equation.
static REAL8 UNUSED XLALSimInspiralPNFlux_10PNTidalCoeff(REAL8 mByM)
static REAL8 UNUSED XLALSimInspiralPNFlux_2PNCoeff(REAL8 eta)
static REAL8 UNUSED XLALSimInspiralPNEnergy_12PNTidalCoeff(REAL8 mByM)
static REAL8 UNUSED XLALSimInspiralPNFlux_7PNCoeff(REAL8 eta)
static REAL8 UNUSED XLALSimInspiralPNFlux_6PNCoeff(REAL8 eta)
static REAL8 UNUSED XLALSimInspiralPNFlux_6PNLogCoeff(REAL8 UNUSED eta)
static REAL8 UNUSED XLALSimInspiralPNEnergy_6PNCoeff(REAL8 eta)
REAL8() SimInspiralTaylorT1Energy(REAL8 v, expnCoeffsdEnergyFlux *ak)
REAL8() SimInspiralTaylorT1dEnergy(REAL8 v, expnCoeffsdEnergyFlux *ak)
static int XLALSimInspiralTaylorT1StoppingTest(double UNUSED t, const double y[], double UNUSED ydot[], void UNUSED *params)
#define LALSIMINSPIRAL_T1_ABSOLUTE_TOLERANCE
static int XLALSimInspiralTaylorT1Setup(expnCoeffsTaylorT1 *ak, expnFuncTaylorT1 *f, REAL8 m1, REAL8 m2, REAL8 lambda1, REAL8 lambda2, LALSimInspiralTidalOrder tideO, int O)
#define LALSIMINSPIRAL_T1_VISCO
static int XLALSimInspiralTaylorT1PNEvolveOrbitIntegrand(double UNUSED t, const double y[], double ydot[], void *params)
#define LALSIMINSPIRAL_NUM_T1_VARIABLES
REAL8() SimInspiralTaylorT1Flux(REAL8 v, expnCoeffsdEnergyFlux *ak)
#define LALSIMINSPIRAL_T1_RELATIVE_TOLERANCE
#define LALSIMINSPIRAL_T1_TEST_ISCO
Module containing the energy and flux functions for waveform generation.
static REAL8 UNUSED XLALSimInspiralFt0(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiralEt6(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiralFt2(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiralEt0(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiralEt4(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiraldEt4(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiralFt4(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiraldEt2(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiralEt2(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiraldEt0(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiralFt7(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiraldEt6(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiralFt6(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiralFt5(REAL8 v, expnCoeffsdEnergyFlux *ak)
static REAL8 UNUSED XLALSimInspiralFt3(REAL8 v, expnCoeffsdEnergyFlux *ak)
int main(int argc, char *argv[])
Definition: bh_qnmode.c:226
int l
Definition: bh_qnmode.c:135
double i
Definition: bh_ringdown.c:118
#define __attribute__(x)
void XLALDestroyREAL8Array(REAL8Array *)
void XLALAdaptiveRungeKuttaFree(LALAdaptiveRungeKuttaIntegrator *integrator)
int XLALAdaptiveRungeKutta4Hermite(LALAdaptiveRungeKuttaIntegrator *integrator, void *params, REAL8 *yinit, REAL8 tinit, REAL8 tend_in, REAL8 deltat, REAL8Array **yout)
LALAdaptiveRungeKuttaIntegrator * XLALAdaptiveRungeKutta4Init(int dim, int(*dydt)(double t, const double y[], double dydt[], void *params), int(*stop)(double t, const double y[], double dydt[], void *params), double eps_abs, double eps_rel)
#define LAL_C_SI
#define LAL_MSUN_SI
#define LAL_PI
#define LAL_PC_SI
#define LAL_G_SI
#define LIGOTIMEGPSZERO
double REAL8
int XLALSimInspiralPNPolarizationWaveforms(REAL8TimeSeries **hplus, REAL8TimeSeries **hcross, REAL8TimeSeries *V, REAL8TimeSeries *Phi, REAL8 v0, REAL8 m1, REAL8 m2, REAL8 r, REAL8 i, int ampO)
Given time series for a binary's orbital dynamical variables, construct the waveform polarizations h+...
LALSimInspiralTidalOrder
Enumeration of allowed PN orders of tidal effects.
@ LAL_SIM_INSPIRAL_TIDAL_ORDER_5PN
@ LAL_SIM_INSPIRAL_TIDAL_ORDER_6PN
@ LAL_SIM_INSPIRAL_TIDAL_ORDER_ALL
@ LAL_SIM_INSPIRAL_TIDAL_ORDER_0PN
COMPLEX16TimeSeries * XLALCreateSimInspiralPNModeCOMPLEX16TimeSeriesLALConvention(REAL8TimeSeries *v, REAL8TimeSeries *phi, REAL8 m1, REAL8 m2, REAL8 r, int O, int l, int m)
Computes h(l,m) mode timeseries of spherical harmonic decomposition of the post-Newtonian inspiral wa...
int XLALSimInspiralTaylorT1PNEvolveOrbit(REAL8TimeSeries **V, REAL8TimeSeries **phi, REAL8 phiRef, REAL8 deltaT, REAL8 m1, REAL8 m2, REAL8 f_min, REAL8 fRef, REAL8 lambda1, REAL8 lambda2, LALSimInspiralTidalOrder tideO, int O)
Evolves a post-Newtonian orbit using the Taylor T1 method.
int XLALSimInspiralTaylorT1PN(REAL8TimeSeries **hplus, REAL8TimeSeries **hcross, REAL8 phiRef, REAL8 deltaT, REAL8 m1, REAL8 m2, REAL8 f_min, REAL8 fRef, REAL8 r, REAL8 i, REAL8 lambda1, REAL8 lambda2, LALSimInspiralTidalOrder tideO, int O)
Driver routine to compute the post-Newtonian inspiral waveform.
COMPLEX16TimeSeries * XLALSimInspiralTaylorT1PNMode(UNUSED REAL8 v0, REAL8 deltaT, REAL8 m1, REAL8 m2, REAL8 f_min, REAL8 fRef, REAL8 r, REAL8 lambda1, REAL8 lambda2, LALSimInspiralTidalOrder tideO, int amplitudeO, int phaseO, int l, int m)
Driver routine to compute the -2 spin-weighted spherical harmonic mode using TaylorT1 phasing.
int XLALSimInspiralTaylorT1PNGenerator(REAL8TimeSeries **hplus, REAL8TimeSeries **hcross, REAL8 phiRef, REAL8 v0, REAL8 deltaT, REAL8 m1, REAL8 m2, REAL8 f_min, REAL8 fRef, REAL8 r, REAL8 i, REAL8 lambda1, REAL8 lambda2, LALSimInspiralTidalOrder tideO, int amplitudeO, int phaseO)
Driver routine to compute the post-Newtonian inspiral waveform.
SphHarmTimeSeries * XLALSimInspiralTaylorT1PNModes(UNUSED REAL8 v0, REAL8 deltaT, REAL8 m1, REAL8 m2, REAL8 f_min, REAL8 fRef, REAL8 r, REAL8 lambda1, REAL8 lambda2, LALSimInspiralTidalOrder tideO, int amplitudeO, int phaseO, int lmax)
int XLALSimInspiralTaylorT1PNRestricted(REAL8TimeSeries **hplus, REAL8TimeSeries **hcross, REAL8 phiRef, REAL8 deltaT, REAL8 m1, REAL8 m2, REAL8 f_min, REAL8 fRef, REAL8 r, REAL8 i, REAL8 lambda1, REAL8 lambda2, LALSimInspiralTidalOrder tideO, int O)
Driver routine to compute the restricted post-Newtonian inspiral waveform.
SphHarmTimeSeries * XLALSphHarmTimeSeriesAddMode(SphHarmTimeSeries *appended, const COMPLEX16TimeSeries *inmode, UINT4 l, INT4 m)
Prepend a node to a linked list of SphHarmTimeSeries, or create a new head.
void LALDPrintTimeSeries(REAL8TimeSeries *series, const CHAR *filename)
static const INT4 r
static const INT4 m
REAL8TimeSeries * XLALCreateREAL8TimeSeries(const CHAR *name, const LIGOTimeGPS *epoch, REAL8 f0, REAL8 deltaT, const LALUnit *sampleUnits, size_t length)
void XLALDestroyCOMPLEX16TimeSeries(COMPLEX16TimeSeries *series)
void XLALDestroyREAL8TimeSeries(REAL8TimeSeries *series)
const LALUnit lalDimensionlessUnit
#define XLAL_ERROR_NULL(...)
#define XLAL_ERROR(...)
int XLALPrintError(const char *fmt,...) _LAL_GCC_PRINTF_FORMAT_(1
XLAL_EFUNC
XLAL_EINVAL
LIGOTimeGPS * XLALGPSAdd(LIGOTimeGPS *epoch, REAL8 dt)
list p
list y
list mu
string status
REAL8 * data
Structure to carry a collection of spherical harmonic modes in COMPLEX16 time series.
expnCoeffsdEnergyFlux akdEF
SimInspiralTaylorT1Energy * energy
SimInspiralTaylorT1dEnergy * dEnergy
SimInspiralTaylorT1Flux * flux
Definition: burst.c:245
double V
Definition: unicorn.c:25
double f_min
Definition: unicorn.c:22
double deltaT
Definition: unicorn.c:24