LALInspiral 5.0.3.1-eeff03c
LALEOBGetFactorizedWaveform.c
Go to the documentation of this file.
1/*
2* Copyright (C) 2010 Craig Robinson
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
21/**
22 * \author Craig Robinson
23 *
24 * \brief The functions contained within this file pre-compute the various
25 * coefficients which are required for calculating the factorized waveform
26 * in EOBNRv2. Note that for some of the higher modes, the coefficients
27 * are changed for the generation of the waveform compared to the generation
28 * of the flux. Thus we have a function which adds these additional
29 * contributions to the already computed coefficients.
30 */
31
32
33#include <math.h>
34#include <lal/LALEOBNRv2Waveform.h>
35
37 FacWaveformCoeffs * const coeffs,
38 const REAL8 eta
39 )
40{
41
42 REAL8 eta2 = eta*eta;
43 REAL8 eta3 = eta2 * eta;
44
45 REAL8 dM, dM2, dM3;
46
47 REAL8 a = 0;
48 REAL8 a2 = 0;
49 REAL8 a3 = 0;
50 REAL8 chiS = 0;
51 REAL8 chiA = 0;
52
53 REAL8 chiAPlusChiSdM;
54
55 /* Combination which appears a lot */
56 REAL8 m1Plus3eta, m1Plus3eta2, m1Plus3eta3;
57
58 dM2 = 1. - 4.*eta;
59
60 /* Check that deltaM has a reasonable value */
61 if ( dM2 < 0 )
62 {
63 XLALPrintError( "eta seems to be < 0.25 - this isn't allowed!\n" );
65 }
66
67 dM = sqrt( dM2 );
68 dM3 = dM2 * dM;
69
70 chiAPlusChiSdM = chiA + chiS*dM;
71
72 m1Plus3eta = - 1. + 3.*eta;
73 m1Plus3eta2 = m1Plus3eta * m1Plus3eta;
74 m1Plus3eta3 = m1Plus3eta * m1Plus3eta2;
75
76 /* Initialize all coefficients to zero */
77 /* This is important, as we will not set some if dM is zero */
78 memset( coeffs, 0, sizeof( FacWaveformCoeffs ) );
79
80
81 /* l = 2 */
82
83 coeffs->delta22vh3 = 7./3.;
84 coeffs->delta22vh6 = (-4.*a)/3. + (428.*LAL_PI)/105.;
85 coeffs->delta22vh8 = (20.*a)/63.;
86 coeffs->delta22vh9 = -2203./81. + (1712.*LAL_PI*LAL_PI)/315.;
87 coeffs->delta22v5 = - 24.*eta;
88
89 coeffs->rho22v2 = -43./42. + (55.*eta)/84.;
90 coeffs->rho22v3 = (-2.*(chiS + chiA*dM - chiS*eta))/3.;
91 coeffs->rho22v4 = -20555./10584. + (chiS*chiS + 2.*chiA*chiS*dM + chiA*chiA*dM2)/2.
92 - (33025.*eta)/21168. + (19583.*eta2)/42336.;
93 coeffs->rho22v5 = (-34.*a)/21.;
94 coeffs->rho22v6 = 1556919113./122245200. + (89.*a2)/252. - (48993925.*eta)/9779616.
95 - (6292061.*eta2)/3259872. + (10620745.*eta3)/39118464.
96 + (41.*eta*LAL_PI*LAL_PI)/192.;
97 coeffs->rho22v6l = - 428./105.;
98 coeffs->rho22v7 = (18733.*a)/15876. + a*a2/3.;
99 coeffs->rho22v8 = -387216563023./160190110080. + (18353.*a2)/21168. - a2*a2/8.;
100 coeffs->rho22v8l = 9202./2205.;
101 coeffs->rho22v10 = -16094530514677./533967033600.;
102 coeffs->rho22v10l = 439877./55566.;
103
104
105 if ( dM2 )
106 {
107 coeffs->delta21vh3 = 2./3.;
108 coeffs->delta21vh6 = (-17.*a)/35. + (107.*LAL_PI)/105.;
109 coeffs->delta21vh7 = (3.*a2)/140.;
110 coeffs->delta21vh9 = -272./81. + (214.*LAL_PI*LAL_PI)/315.;
111 coeffs->delta21v5 = - 493. * eta /42.;
112
113 coeffs->rho21v1 = (-3.*chiAPlusChiSdM)/(4.*dM);
114 coeffs->rho21v2 = -59./56 - (9.*chiAPlusChiSdM*chiAPlusChiSdM)/(32.*dM2) + (23.*eta)/84.;
115 coeffs->rho21v3 = (-567.*chiA*chiA*chiA - 1701.*chiA*chiA*chiS*dM
116 + chiA*(-4708. + 1701.*chiS*chiS - 2648.*eta)*(-1. + 4.*eta)
117 + chiS* dM3 *(4708. - 567.*chiS*chiS
118 + 1816.*eta))/(2688.*dM3);
119 coeffs->rho21v4 = -47009./56448.- (865.*a2)/1792. - (405.*a2*a2)/2048. - (10993.*eta)/14112.
120 + (617.*eta2)/4704.;
121 coeffs->rho21v5 = (-98635.*a)/75264. + (2031.*a*a2)/7168. - (1701.*a2*a3)/8192.;
122 coeffs->rho21v6 = 7613184941./2607897600.+ (9032393.*a2)/1806336. + (3897.*a2*a2)/16384.
123 - (15309.*a3*a3)/65536.;
124 coeffs->rho21v6l = - 107./105.;
125 coeffs->rho21v7 = (-3859374457.*a)/1159065600. - (55169.*a3)/16384.
126 + (18603.*a2*a3)/65536. - (72171.*a2*a2*a3)/262144.;
127 coeffs->rho21v7l = 107.*a/140.;
128 coeffs->rho21v8 = -1168617463883./911303737344.;
129 coeffs->rho21v8l = 6313./5880.;
130 coeffs->rho21v10 = -63735873771463./16569158860800.;
131 coeffs->rho21v10l = 5029963./5927040.;
132 }
133
134 /* l = 3 */
135 if ( dM2 )
136 {
137 coeffs->delta33vh3 = 13./10.;
138 coeffs->delta33vh6 = (-81.*a)/20. + (39.*LAL_PI)/7.;
139 coeffs->delta33vh9 = -227827./3000. + (78.*LAL_PI*LAL_PI)/7.;
140 coeffs->delta33v5 = - 80897.*eta / 2430.;
141
142 coeffs->rho33v2 = -7./6. + (2.*eta)/3.;
143 coeffs->rho33v3 = (chiS*dM*(-4. + 5.*eta) + chiA*(-4. + 19.*eta))/(6.*dM);
144 coeffs->rho33v4 = -6719./3960. + a2/2. - (1861.*eta)/990. + (149.*eta2)/330.;
145 coeffs->rho33v5 = (-4.*a)/3.;
146 coeffs->rho33v6 = 3203101567./227026800. + (5.*a2)/36.;
147 coeffs->rho33v6l = - 26./7.;
148 coeffs->rho33v7 = (5297.*a)/2970. + a*a2/3.;
149 coeffs->rho33v8 = -57566572157./8562153600.;
150 coeffs->rho33v8l = 13./3.;
151 }
152
153 coeffs->delta32vh3 = (10. + 33.*eta)/(-15.*m1Plus3eta);
154 coeffs->delta32vh4 = 4.*a;
155 coeffs->delta32vh6 = (-136.*a)/45. + (52.*LAL_PI)/21.;
156 coeffs->delta32vh9 = -9112./405. + (208.*LAL_PI*LAL_PI)/63.;
157
158 coeffs->rho32v = (4.*chiS*eta)/(-3.*m1Plus3eta);
159 coeffs->rho32v2 = (-4.*a2*eta2)/(9.*m1Plus3eta2) + (328. - 1115.*eta
160 + 320.*eta2)/(270.*m1Plus3eta);
161 coeffs->rho32v3 = (2.*(45.*a*m1Plus3eta3
162 - a*eta*(328. - 2099.*eta + 5.*(733. + 20.*a2)*eta2
163 - 960.*eta3)))/(405.*m1Plus3eta3);
164 coeffs->rho32v4 = a2/3. + (-1444528.
165 + 8050045.*eta - 4725605.*eta2 - 20338960.*eta3
166 + 3085640.*eta2*eta2)/(1603800.*m1Plus3eta2);
167 coeffs->rho32v5 = (-2788.*a)/1215.;
168 coeffs->rho32v6 = 5849948554./940355325. + (488.*a2)/405.;
169 coeffs->rho32v6l = - 104./63.;
170 coeffs->rho32v8 = -10607269449358./3072140846775.;
171 coeffs->rho32v8l = 17056./8505.;
172
173 if ( dM2 )
174 {
175 coeffs->delta31vh3 = 13./30.;
176 coeffs->delta31vh6 = (61.*a)/20. + (13.*LAL_PI)/21.;
177 coeffs->delta31vh7 = (-24.*a2)/5.;
178 coeffs->delta31vh9 = -227827./81000. + (26.*LAL_PI*LAL_PI)/63.;
179 coeffs->delta31v5 = - 17.*eta/10.;
180
181 coeffs->rho31v2 = -13./18. - (2.*eta)/9.;
182 coeffs->rho31v3 = (chiA*(-4. + 11.*eta) + chiS*dM*(-4. + 13.*eta))/(6.*dM);
183 coeffs->rho31v4 = 101./7128.
184 - (5.*a2)/6. - (1685.*eta)/1782. - (829.*eta2)/1782.;
185 coeffs->rho31v5 = (4.*a)/9.;
186 coeffs->rho31v6 = 11706720301./6129723600. - (49.*a2)/108.;
187 coeffs->rho31v6l = - 26./63.;
188 coeffs->rho31v7 = (-2579.*a)/5346. + a*a2/9.;
189 coeffs->rho31v8 = 2606097992581./4854741091200.;
190 coeffs->rho31v8l = 169./567.;
191 }
192
193 /* l = 4 */
194
195 coeffs->delta44vh3 = (112. + 219.*eta)/(-120.*m1Plus3eta);
196 coeffs->delta44vh6 = (-464.*a)/75. + (25136.*LAL_PI)/3465.;
197
198 coeffs->rho44v2 = (1614. - 5870.*eta + 2625.*eta2)/(1320.*m1Plus3eta);
199 coeffs->rho44v3 = (chiA*(10. - 39.*eta)*dM + chiS*(10. - 41.*eta
200 + 42.*eta2))/(15.*m1Plus3eta);
201 coeffs->rho44v4 = a2/2. + (-511573572.
202 + 2338945704.*eta - 313857376.*eta2 - 6733146000.*eta3
203 + 1252563795.*eta2*eta2)/(317116800.*m1Plus3eta2);
204 coeffs->rho44v5 = (-69.*a)/55.;
205 coeffs->rho44v6 = 16600939332793./1098809712000. + (217.*a2)/3960.;
206 coeffs->rho44v6l = - 12568./3465.;
207
208 if ( dM2 )
209 {
210 coeffs->delta43vh3 = (486. + 4961.*eta)/(810.*(1. - 2.*eta));
211 coeffs->delta43vh4 = (11.*a)/4.;
212 coeffs->delta43vh6 = 1571.*LAL_PI/385.;
213
214 coeffs->rho43v = (5.*(chiA - chiS*dM)*eta)/(8.*dM*(-1. + 2.*eta));
215 coeffs->rho43v2 = (222. - 547.*eta + 160.*eta2)/(176.*(-1. + 2.*eta));
216 coeffs->rho43v4 = -6894273./7047040. + (3.*a2)/8.;
217 coeffs->rho43v5 = (-12113.*a)/6160.;
218 coeffs->rho43v6 = 1664224207351./195343948800.;
219 coeffs->rho43v6l = - 1571./770.;
220 }
221
222 coeffs->delta42vh3 = (7.*(1. + 6.*eta))/(-15.*m1Plus3eta);
223 coeffs->delta42vh6 = (212.*a)/75. + (6284.*LAL_PI)/3465.;
224
225 coeffs->rho42v2 = (1146. - 3530.*eta + 285.*eta2)/(1320.*m1Plus3eta);
226 coeffs->rho42v3 = (chiA*(10. - 21.*eta)*dM + chiS*(10. - 59.*eta
227 + 78.*eta2))/(15.*m1Plus3eta);
228 coeffs->rho42v4 = a2/2. + (-114859044. + 295834536.*eta + 1204388696.*eta2 - 3047981160.*eta3
229 - 379526805.*eta2*eta2)/(317116800.*m1Plus3eta2);
230 coeffs->rho42v5 = (-7.*a)/110.;
231 coeffs->rho42v6 = 848238724511./219761942400. + (2323.*a2)/3960.;
232 coeffs->rho42v6l = - 3142./3465.;
233
234 if ( dM2 )
235 {
236 coeffs->delta41vh3 = (2. + 507.*eta)/(10.*(1. - 2.*eta));
237 coeffs->delta41vh4 = (11.*a)/12.;
238 coeffs->delta41vh6 = 1571.*LAL_PI/3465.;
239
240 coeffs->rho41v = (5.*(chiA - chiS*dM)*eta)/(8.*dM*(-1. + 2.*eta));
241 coeffs->rho41v2 = (602. - 1385.*eta + 288.*eta2)/(528.*(-1. + 2.*eta));
242 coeffs->rho41v4 = -7775491./21141120. + (3.*a2)/8.;
243 coeffs->rho41v5 = (-20033.*a)/55440. - (5*a*a2)/6.;
244 coeffs->rho41v6 = 1227423222031./1758095539200.;
245 coeffs->rho41v6l = - 1571./6930.;
246 }
247
248 /* l = 5 */
249 if ( dM2 )
250 {
251 coeffs->delta55vh3 = (96875. + 857528.*eta)/(131250.*(1 - 2*eta));
252
253 coeffs->rho55v2 = (487. - 1298.*eta + 512.*eta2)/(390.*(-1. + 2.*eta));
254 coeffs->rho55v3 = (-2.*a)/3.;
255 coeffs->rho55v4 = -3353747./2129400. + a2/2.;
256 coeffs->rho55v5 = - 241. * a / 195.;
257 }
258
259 coeffs->delta54vh3 = 8./15.;
260 coeffs->delta54vh4 = 12.*a/5.;
261
262 coeffs->rho54v2 = (-17448. + 96019.*eta - 127610.*eta2
263 + 33320.*eta3)/(13650.*(1. - 5.*eta + 5.*eta2));
264 coeffs->rho54v3 = (-2.*a)/15.;
265 coeffs->rho54v4 = -16213384./15526875. + (2.*a2)/5.;
266
267 if ( dM2 )
268 {
269 coeffs->delta53vh3 = 31./70.;
270
271 coeffs->rho53v2 = (375. - 850.*eta + 176.*eta2)/(390.*(-1. + 2.*eta));
272 coeffs->rho53v3 = (-2.*a)/3.;
273 coeffs->rho53v4 = -410833./709800. + a2/2.;
274 coeffs->rho53v5 = - 103.*a/325.;
275 }
276
277 coeffs->delta52vh3 = 4./15.;
278 coeffs->delta52vh4 = 6.*a/5.;
279
280 coeffs->rho52v2 = (-15828. + 84679.*eta - 104930.*eta2
281 + 21980.*eta3)/(13650.*(1. - 5.*eta + 5.*eta2));
282 coeffs->rho52v3 = (-2.*a)/15.;
283 coeffs->rho52v4 = -7187914./15526875. + (2.*a2)/5.;
284
285 if ( dM2 )
286 {
287 coeffs->delta51vh3 = 31./210.;
288
289 coeffs->rho51v2 = (319. - 626.*eta + 8.*eta2)/(390.*(-1. + 2.*eta));
290 coeffs->rho51v3 = (-2.*a)/3.;
291 coeffs->rho51v4 = -31877./304200. + a2/2.;
292 coeffs->rho51v5 = 139.*a/975.;
293 }
294
295 /* l = 6 */
296
297 coeffs->delta66vh3 = 43./70.;
298
299 coeffs->rho66v2 = (-106. + 602.*eta - 861.*eta2
300 + 273.*eta3)/(84.*(1. - 5.*eta + 5.*eta2));
301 coeffs->rho66v3 = (-2.*a)/3.;
302 coeffs->rho66v4 = -1025435./659736. + a2/2.;
303
304 if ( dM2 )
305 {
306 coeffs->delta65vh3 = 10./21.;
307
308 coeffs->rho65v2 = (-185. + 838.*eta - 910.*eta2
309 + 220.*eta3)/(144.*(dM2 + 3.*eta2));
310 coeffs->rho65v3 = - 2.*a/9.;
311 }
312
313 coeffs->delta64vh3 = 43./105.;
314
315 coeffs->rho64v2 = (-86. + 462.*eta - 581.*eta2
316 + 133.*eta3)/(84.*(1. - 5.*eta + 5.*eta2));
317 coeffs->rho64v3 = (-2.*a)/3.;
318 coeffs->rho64v4 = -476887./659736. + a2/2.;
319
320 if ( dM2 )
321 {
322 coeffs->delta63vh3 = 2./7.;
323
324 coeffs->rho63v2 = (-169. + 742.*eta - 750.*eta2
325 + 156.*eta3)/(144.*(dM2 + 3.*eta2));
326 coeffs->rho63v3 = - 2.*a/9.;
327 }
328
329 coeffs->delta62vh3 = 43./210.;
330
331 coeffs->rho62v2 = (-74. + 378.*eta - 413.*eta2
332 + 49.*eta3)/(84.*(1. - 5.*eta + 5.*eta2));
333 coeffs->rho62v3 = (-2.*a)/3.;
334 coeffs->rho62v4 = -817991./3298680. + a2/2.;
335
336 if ( dM2 )
337 {
338 coeffs->delta61vh3 = 2./21.;
339
340 coeffs->rho61v2 = (-161. + 694.*eta - 670.*eta2
341 + 124.*eta3)/(144.*(dM2 + 3.*eta2));
342 coeffs->rho61v3 = - 2. * a / 9.;
343 }
344
345 /* l = 7 */
346 if ( dM2 )
347 {
348 coeffs->delta77vh3 = 19./36.;
349
350 coeffs->rho77v2 = (-906. + 4246.*eta - 4963.*eta2
351 + 1380.*eta3)/(714.*(dM2 + 3.*eta2));
352 coeffs->rho77v3 = - 2.*a/3.;
353 }
354
355 coeffs->rho76v2 = (2144. - 16185.*eta + 37828.*eta2 - 29351.*eta3
356 + 6104.*eta2*eta2) / (1666.*(-1 + 7*eta - 14*eta2
357 + 7*eta3));
358
359 if ( dM2 )
360 {
361 coeffs->delta75vh3 = 95./252.;
362
363 coeffs->rho75v2 = (-762. + 3382.*eta - 3523.*eta2
364 + 804.*eta3)/(714.*(dM2 + 3.*eta2));
365 coeffs->rho75v3 = - 2.*a/3.;
366 }
367
368 coeffs->rho74v2 = (17756. - 131805.*eta + 298872.*eta2 - 217959.*eta3
369 + 41076.*eta2*eta2) / (14994.*(-1. + 7.*eta - 14.*eta2
370 + 7.*eta3));
371
372 if ( dM2 )
373 {
374 coeffs->delta73vh3 = 19./84.;
375
376 coeffs->rho73v2 = (-666. + 2806.*eta - 2563.*eta2
377 + 420.*eta3)/(714.*(dM2 + 3.*eta2));
378 coeffs->rho73v3 = - 2.*a/3.;
379 }
380
381 coeffs->rho72v2 = (16832. - 123489.*eta + 273924.*eta2 - 190239.*eta3
382 + 32760.*eta2*eta2) /(14994.*(-1. + 7.*eta - 14.*eta2
383 + 7.*eta3));
384
385 if ( dM2 )
386 {
387 coeffs->delta71vh3 = 19./252.;
388
389 coeffs->rho71v2 = (-618. + 2518.*eta - 2083.*eta2
390 + 228.*eta3)/(714.*(dM2 + 3.*eta2));
391 coeffs->rho71v3 = - 2.*a/3.;
392 }
393
394 /* l = 8 */
395
396 coeffs->rho88v2 = (3482. - 26778.*eta + 64659.*eta2 - 53445.*eta3
397 + 12243.*eta2*eta2) / (2736.*(-1. + 7.*eta - 14.*eta2
398 + 7.*eta3));
399
400 if ( dM2 )
401 {
402 coeffs->rho87v2 = (23478. - 154099.*eta + 309498.*eta2 - 207550.*eta3
403 + 38920*eta2*eta2) / (18240.*(-1 + 6*eta - 10*eta2
404 + 4*eta3));
405 }
406
407 coeffs->rho86v2 = (1002. - 7498.*eta + 17269.*eta2 - 13055.*eta3
408 + 2653.*eta2*eta2) / (912.*(-1. + 7.*eta - 14.*eta2
409 + 7.*eta3));
410
411 if ( dM2 )
412 {
413 coeffs->rho85v2 = (4350. - 28055.*eta + 54642.*eta2 - 34598.*eta3
414 + 6056.*eta2*eta2) / (3648.*(-1. + 6.*eta - 10.*eta2
415 + 4.*eta3));
416 }
417
418 coeffs->rho84v2 = (2666. - 19434.*eta + 42627.*eta2 - 28965.*eta3
419 + 4899.*eta2*eta2) / (2736.*(-1. + 7.*eta - 14.*eta2
420 + 7.*eta3));
421
422 if ( dM2 )
423 {
424 coeffs->rho83v2 = (20598. - 131059.*eta + 249018.*eta2 - 149950.*eta3
425 + 24520.*eta2*eta2) / (18240.*(-1. + 6.*eta - 10.*eta2
426 + 4.*eta3));
427 }
428
429 coeffs->rho82v2 = (2462. - 17598.*eta + 37119.*eta2 - 22845.*eta3
430 + 3063.*eta2*eta2) / (2736.*(-1. + 7.*eta - 14.*eta2
431 + 7.*eta3));
432
433 if ( dM2 )
434 {
435 coeffs->rho81v2 = (20022. - 126451.*eta + 236922.*eta2 - 138430.*eta3
436 + 21640.*eta2*eta2) / (18240.*(-1. + 6.*eta - 10.*eta2
437 + 4.*eta3));
438 }
439
440 /* All relevant coefficients should be set, so we return */
441
442 return XLAL_SUCCESS;
443}
444
446 const REAL8 eta )
447{
448
449 if ( !coeffs )
450 {
452 }
453
454 /* Tweak the relevant coefficients for the generation of the waveform */
455 coeffs->rho21v6 += -5. * eta;
456 coeffs->rho33v6 += -20. * eta;
457 coeffs->rho44v6 += -15. * eta;
458 coeffs->rho55v6 += 4. * eta;
459
460 coeffs->delta21v7 += 30. * eta;
461 coeffs->delta33v7 += -10. * eta;
462 coeffs->delta44v5 += -70. * eta;
463 coeffs->delta55v5 += 40. * eta;
464
465 return XLAL_SUCCESS;
466}
const double a2
#define LAL_PI
double REAL8
int XLALModifyFacWaveformCoefficients(FacWaveformCoeffs *const coeffs, const REAL8 eta)
int XLALCalcFacWaveformCoefficients(FacWaveformCoeffs *const coeffs, const REAL8 eta)
The functions contained within this file pre-compute the various coefficients which are required for ...
static const INT4 a
#define XLAL_ERROR(...)
int XLALPrintError(const char *fmt,...) _LAL_GCC_PRINTF_FORMAT_(1
XLAL_SUCCESS
XLAL_EINVAL