41 #include <lal/LALSimIMR.h>
42 #include <lal/LALConstants.h>
44 #include <lal/FrequencySeries.h>
45 #include <lal/Units.h>
48 #include <gsl/gsl_linalg.h>
59 double sixth = pow(number, 1.0 / 6.0);
60 double m_sixth = 1.0 / sixth;
63 p->m_one_sixth = m_sixth;
65 p->m_one = 1.0 / number;
68 p->one_third = sixth * sixth;
69 p->m_one_third = 1.0 / (
p->one_third);
71 p->two_thirds =
p->one_third *
p->one_third;
72 p->m_two_thirds = 1.0 /
p->two_thirds;
74 p->four_thirds =
p->two_thirds *
p->two_thirds;
75 p->m_four_thirds = 1.0 /
p->four_thirds;
77 p->five_thirds =
p->four_thirds *
p->one_third;
78 p->m_five_thirds = 1.0 /
p->five_thirds;
80 p->seven_thirds =
p->four_thirds * number;
81 p->m_seven_thirds = 1.0 /
p->seven_thirds;
83 p->eight_thirds =
p->seven_thirds *
p->one_third;
84 p->m_eight_thirds = 1.0 /
p->eight_thirds;
86 p->two = number * number;
87 p->three =
p->two * number;
88 p->four =
p->three * number;
89 p->five =
p->four * number;
91 p->m_two = 1.0 /
p->two;
92 p->m_three = 1.0 /
p->three;
93 p->m_four = 1.0 /
p->four;
94 p->m_five = 1.0 /
p->five;
96 p->seven_sixths =
p->one_sixth *
p->itself;
97 p->m_seven_sixths =
p->m_one_sixth *
p->m_one;
100 p->sqrt =
p->one_sixth*
p->one_sixth*
p->one_sixth;
111 double sixth = pow(number, 1.0 / 6.0);
112 double m_sixth = 1.0 / sixth;
114 p->one_sixth = sixth;
115 p->m_one_sixth = m_sixth;
117 p->m_one = 1.0 / number;
120 p->one_third = sixth * sixth;
121 p->two_thirds =
p->one_third *
p->one_third;
123 p->m_two =
p->m_one *
p->m_one;
124 p->m_three =
p->m_two *
p->m_one;
126 p->seven_sixths =
p->one_sixth *
p->itself;
127 p->m_seven_sixths =
p->m_one_sixth *
p->m_one;
129 p->log = log(number);
139 const REAL8 chi1L_In,
140 const REAL8 chi2L_In,
146 const REAL8 distance,
147 const REAL8 inclination,
149 UNUSED
const UINT4 debug
196 switch( InspPhaseFlag )
221 XLAL_ERROR(
XLAL_EINVAL,
"Error in IMRPhenomX_SetWaveformVariables: IMRPhenomXInspiralPhaseVersion not recognized. Recommended flag is 104.\n");
227 switch( IntPhaseFlag )
241 XLAL_ERROR(
XLAL_EINVAL,
"Error in IMRPhenomX_SetWaveformVariables: IMRPhenomXIntermediatePhaseVersion not recognized. Recommended flag is 105.\n");
247 switch( RDPhaseFlag )
256 XLAL_ERROR(
XLAL_EINVAL,
"Error in IMRPhenomX_SetWaveformVariables: IMRPhenomXRingdownPhaseVersion not recognized. Recommended flag is 105.\n");
271 XLAL_ERROR(
XLAL_EINVAL,
"Error in IMRPhenomX_SetWaveformVariables: IMRPhenomXInspiralAmpVersion not recognized. Recommended flag is 103.\n");
296 XLAL_ERROR(
XLAL_EINVAL,
"Error in IMRPhenomX_SetWaveformVariables: IMRPhenomXIntermediateAmpVersion not recognized. Recommended flag is 104.\n");
310 XLAL_ERROR(
XLAL_EINVAL,
"Error in IMRPhenomX_SetWaveformVariables: IMRPhenomXRingdownAmpVersion not recognized. Recommended flag is 103.\n");
319 REAL8 lambda1_In = 0, lambda2_In = 0, quadparam1_In = 1, quadparam2_In = 1;
326 if( lambda1_In < 0 || lambda2_In < 0 )
327 XLAL_ERROR(
XLAL_EFUNC,
"lambda1 = %f, lambda2 = %f. Both should be greater than zero for NRTidalv2", lambda1_In, lambda2_In);
338 REAL8 m1, m2, chi1L, chi2L, lambda1, lambda2, quadparam1, quadparam2;
347 lambda1 = lambda1_In;
348 lambda2 = lambda2_In;
349 quadparam1 = quadparam1_In;
350 quadparam2 = quadparam2_In;
354 XLAL_PRINT_WARNING(
"Warning: m1 < m2, swapping the masses, spins, tidal deformabilities, and spin-induced quadrupole parameters.\n");
359 lambda1 = lambda2_In;
360 lambda2 = lambda1_In;
361 quadparam1 = quadparam2_In;
362 quadparam2 = quadparam1_In;
382 if( chi1L > 1.0 || chi1L < -1.0 || chi2L > 1.0 || chi2L < -1.0)
391 REAL8 q = ((m1 > m2) ? (m1 / m2) : (m2 / m1));
398 if(eta > 0.25 || eta < 0.0)
402 if(eta == 0.25)
q = 1.;
427 wf->
eta2 = eta * eta;
432 printf(
"m1 (Msun) = %.6f\n",m1);
433 printf(
"m2 (Msun) = %.6f\n",m2);
434 printf(
"m1_SI = %.6f\n",wf->
m1_SI);
435 printf(
"m2_SI = %.6f\n",wf->
m2_SI);
436 printf(
"m1 = %.6f\n",wf->
m1);
437 printf(
"m2 = %.6f\n",wf->
m2);
453 wf->
chi1L3 = chi1L*chi1L*chi1L;
456 wf->
chi2L3 = chi2L*chi2L*chi2L;
470 printf(
"eta : %.16e\n",wf->
eta);
471 printf(
"q : %.16e\n",wf->
q);
472 printf(
"chi1L : %.16e\n",wf->
chi1L);
473 printf(
"chi2L : %.16e\n",wf->
chi2L);
474 printf(
"chi_eff : %.16e\n",wf->
chiEff);
475 printf(
"chi_hat : %.16e\n",wf->
chiPNHat);
476 printf(
"STotR : %.16e\n",wf->
STotR);
523 printf(
"fRef : %.6f\n",wf->
fRef);
524 printf(
"phi0 : %.6f\n",wf->
phi0);
525 printf(
"fCut : %.6f\n",wf->
fCut);
526 printf(
"fMin : %.6f\n",wf->
fMin);
527 printf(
"fMax : %.6f\n",wf->
fMax);
542 printf(
"fMin = %.6f\n",wf->
fMin);
543 printf(
"fMax = %.6f\n",wf->
fMax);
568 printf(
"Mf = %.6f\n",wf->
Mfinal);
569 printf(
"af = %.6f\n",wf->
afinal);
570 printf(
"frd = %.6f\n",wf->
fRING);
571 printf(
"fda = %.6f\n",wf->
fDAMP);
578 if(fabs(wf->
afinal) > 1.0)
591 printf(
"fMECO = %.6f\n",wf->
fMECO);
592 printf(
"fISCO = %.6f\n",wf->
fISCO);
611 printf(
"\n\neta = %.6f\n",wf->
eta);
612 printf(
"\nampNorm = %e\n",wf->
ampNorm);
613 printf(
"amp0 : %e",wf->
amp0);
621 printf(
"\n\n **** Sanity checks complete. Waveform struct has been initialized. **** \n\n");
666 REAL8 V1, V2, V3, V4;
667 REAL8 F1, F2, F3, F4;
687 printf(
"chi1L = %.6f\n",chi1L);
688 printf(
"chi1L2 = %.6f\n",chi1L2);
689 printf(
"chi1L3 = %.6f\n",chi1L3);
690 printf(
"chi2L2 = %.6f\n",chi2L2);
691 printf(
"delta = %.6f\n",
delta);
692 printf(
"eta2 = %.6f\n",eta2);
693 printf(
"eta3 = %.6f\n",eta3);
725 printf(
"V1 = %.6f\n",pAmp->
v1RD);
726 printf(
"gamma1 = %.6f\n",pAmp->
gamma1);
727 printf(
"gamma2 = %.6f\n",pAmp->
gamma2);
728 printf(
"gamma3 = %.6f\n",pAmp->
gamma3);
751 + 24*(428652*chi2L2*(-1 +
delta) + (-1975055 + 10584*(81*chi1L2 - 94*chi1L*chi2L + 81*chi2L2))*eta
754 + 4*(-93414 + 1512*chi2L2*(-3 +
delta) + 2083*
delta)*eta - 35632*eta2)
755 + chi1L*(287213*(1 +
delta) - 4*eta*(93414 + 2083*
delta + 8908*eta))
757 pAmp->
pnSixThirds = ( (-1242641879927 + 12.0*(28.0*(-3248849057.0
758 + 11088*(163199*chi1L2 - 266498*chi1L*chi2L + 163199*chi2L2))*eta2
759 + 27026893936*eta3 - 116424*(147117*(-(chi2L2*(-1.0 +
delta)) + chi1L2*(1.0 +
delta))
761 + eta*(545384828789.0 - 77616*(638642*chi1L*chi2L + chi1L2*(-158633 + 282718*
delta)
762 - chi2L2*(158633.0 + 282718.0*
delta) - 107520.0*(chi1L + chi2L)*
LAL_PI
789 XLAL_ERROR(
XLAL_EINVAL,
"Error in IMRPhenomXGetAmplitudeCoefficients: IMRPhenomXInspiralAmpVersion is not valid.\n");
803 printf(
"\nAmplitude pseudo PN coeffcients\n");
805 printf(
"V1 = %.6f\n",V1);
806 printf(
"V2 = %.6f\n",V2);
807 printf(
"V3 = %.6f\n",V3);
808 printf(
"F1 = %e\n",F1);
809 printf(
"F2 = %e\n",F2);
810 printf(
"F3 = %e\n",F3);
825 printf(
"\nTaylorF2 PN Amplitude Coefficients\n");
836 printf(
"Pseudo-PN Amplitude Coefficients (Agrees with MMA).\n");
868 d1 = ((7.0/6.0) * powers_of_F1.
one_sixth / inspF1) - ( powers_of_F1.
seven_sixths * d1 / (inspF1*inspF1) );
873 printf(
"d1 = %.6f\n",d1);
874 printf(
"d4 = %.6f\n",d4);
883 F2 = F1 + (1.0/3.0) * (F4-F1);
884 F3 = F1 + (2.0/3.0) * (F4-F1);
900 F2 = F1 + (1.0/2.0) * (F4-F1);
917 F2 = F1 + (1.0/3.0) * (F4-F1);
918 F3 = F1 + (2.0/3.0) * (F4-F1);
943 printf(
"\nIntermediate Region: \n");
944 printf(
"F1 = %.6f\n",F1);
945 printf(
"F2 = %.6f\n",F2);
946 printf(
"F3 = %.6f\n",F3);
947 printf(
"F4 = %.6f\n",F4);
950 printf(
"d1 = %.6f\n",d1);
951 printf(
"d4 = %.6f\n",d4);
952 printf(
"V1 = %.6f\n",V1);
953 printf(
"V2 = %.6f\n",V2);
954 printf(
"V3 = %.6f\n",V3);
955 printf(
"V4 = %.6f\n",V4);
961 pAmp->
delta0 =
IMRPhenomX_Intermediate_Amp_22_delta0(d1,d4,V1,V2,V3,V4,F1,F2,F3,F4,pWF->
IMRPhenomXIntermediateAmpVersion);
962 pAmp->
delta1 =
IMRPhenomX_Intermediate_Amp_22_delta1(d1,d4,V1,V2,V3,V4,F1,F2,F3,F4,pWF->
IMRPhenomXIntermediateAmpVersion);
963 pAmp->
delta2 =
IMRPhenomX_Intermediate_Amp_22_delta2(d1,d4,V1,V2,V3,V4,F1,F2,F3,F4,pWF->
IMRPhenomXIntermediateAmpVersion);
964 pAmp->
delta3 =
IMRPhenomX_Intermediate_Amp_22_delta3(d1,d4,V1,V2,V3,V4,F1,F2,F3,F4,pWF->
IMRPhenomXIntermediateAmpVersion);
965 pAmp->
delta4 =
IMRPhenomX_Intermediate_Amp_22_delta4(d1,d4,V1,V2,V3,V4,F1,F2,F3,F4,pWF->
IMRPhenomXIntermediateAmpVersion);
966 pAmp->
delta5 =
IMRPhenomX_Intermediate_Amp_22_delta5(d1,d4,V1,V2,V3,V4,F1,F2,F3,F4,pWF->
IMRPhenomXIntermediateAmpVersion);
970 printf(
"delta0 = %.6f\n",pAmp->
delta0);
971 printf(
"delta1 = %.6f\n",pAmp->
delta1);
972 printf(
"delta2 = %.6f\n",pAmp->
delta2);
973 printf(
"delta3 = %.6f\n",pAmp->
delta3);
974 printf(
"delta4 = %.6f\n",pAmp->
delta4);
975 printf(
"delta5 = %.6f\n",pAmp->
delta5);
1003 REAL8 gpoints4[4] = {0.0, 1.0/4.0, 3.0/4.0, 1.0};
1004 REAL8 gpoints5[5] = {0.0, 1.0/2 - 1.0/(2*sqrt(2.0)), 1.0/2.0, 1.0/2 + 1.0/(2.0*sqrt(2.0)), 1.0};
1009 double fIMmatch = 0.6 * (0.5 * pWF->
fRING + pWF->
fISCO);
1012 double fINmatch = pWF->
fMECO;
1015 double deltaf = (fIMmatch - fINmatch) * 0.03;
1041 REAL8 chi1L2L = chi1L * chi2L;
1050 REAL8 eta2 = eta*eta;
1051 REAL8 eta3 = eta*eta2;
1134 printf(
"Solving system of equations for RD phase...\n");
1138 for(
i = 0;
i < 5;
i++)
1147 printf(
"Rigndown collocation points : \n");
1193 printf(
"Ringdown Collocation Points: \n");
1232 REAL8 ff, invff, ff0, ff1, ff2, ff3, ff4;
1238 ff2 = invff * invff;
1241 gsl_matrix_set(A,0,0,1.0);
1242 gsl_matrix_set(A,0,1,ff1);
1243 gsl_matrix_set(A,0,2,ff2);
1244 gsl_matrix_set(A,0,3,ff3);
1245 gsl_matrix_set(A,0,4,ff4);
1249 printf(
"For row 0: a0 + a1 %.6f + a2 %.6f + a4 %.6f + aRD %.6f\n",ff1,ff2,ff3,ff4);
1256 ff2 = invff * invff;
1259 gsl_matrix_set(A,1,0,1.0);
1260 gsl_matrix_set(A,1,1,ff1);
1261 gsl_matrix_set(A,1,2,ff2);
1262 gsl_matrix_set(A,1,3,ff3);
1263 gsl_matrix_set(A,1,4,ff4);
1269 ff2 = invff * invff;
1272 gsl_matrix_set(A,2,0,1.0);
1273 gsl_matrix_set(A,2,1,ff1);
1274 gsl_matrix_set(A,2,2,ff2);
1275 gsl_matrix_set(A,2,3,ff3);
1276 gsl_matrix_set(A,2,4,ff4);
1282 ff2 = invff * invff;
1285 gsl_matrix_set(A,3,0,1.0);
1286 gsl_matrix_set(A,3,1,ff1);
1287 gsl_matrix_set(A,3,2,ff2);
1288 gsl_matrix_set(A,3,3,ff3);
1289 gsl_matrix_set(A,3,4,ff4);
1295 ff2 = invff * invff;
1298 gsl_matrix_set(A,4,0,1.0);
1299 gsl_matrix_set(A,4,1,ff1);
1300 gsl_matrix_set(A,4,2,ff2);
1301 gsl_matrix_set(A,4,3,ff3);
1302 gsl_matrix_set(A,4,4,ff4);
1305 gsl_linalg_LU_decomp(A,
p,&
s);
1306 gsl_linalg_LU_solve(A,
p,b,
x);
1308 pPhase->
c0 = gsl_vector_get(
x,0);
1309 pPhase->
c1 = gsl_vector_get(
x,1);
1310 pPhase->
c2 = gsl_vector_get(
x,2);
1311 pPhase->
c4 = gsl_vector_get(
x,3);
1312 pPhase->
cRD = gsl_vector_get(
x,4);
1322 printf(
"Ringdown Coefficients: \n");
1323 printf(
"c0 : %.6f\n",pPhase->
c0);
1324 printf(
"c1 : %.6f\n",pPhase->
c1);
1325 printf(
"c2 : %.6f\n",pPhase->
c2);
1326 printf(
"c4 : %e\n",pPhase->
c4);
1327 printf(
"cRD : %.6f\n",gsl_vector_get(
x,4));
1328 printf(
"d0 : %.6f\n",pWF->
dphase0);
1329 printf(
"cL : %e\n",pPhase->
cL);
1332 printf(
"Freeing arrays...\n");
1339 gsl_permutation_free(
p);
1396 printf(
"NPseudoPN : %d\n",pPhase->
NPseudoPN);
1416 fi = gpoints4[
i] * deltax + xmin;
1434 printf(
"Inspiral Collocation Points and Values:\n");
1458 gsl_matrix_set(A,0,0,1.0);
1459 gsl_matrix_set(A,0,1,ff1);
1460 gsl_matrix_set(A,0,2,ff2);
1461 gsl_matrix_set(A,0,3,ff3);
1469 gsl_matrix_set(A,1,0,1.0);
1470 gsl_matrix_set(A,1,1,ff1);
1471 gsl_matrix_set(A,1,2,ff2);
1472 gsl_matrix_set(A,1,3,ff3);
1480 gsl_matrix_set(A,2,0,1.0);
1481 gsl_matrix_set(A,2,1,ff1);
1482 gsl_matrix_set(A,2,2,ff2);
1483 gsl_matrix_set(A,2,3,ff3);
1491 gsl_matrix_set(A,3,0,1.0);
1492 gsl_matrix_set(A,3,1,ff1);
1493 gsl_matrix_set(A,3,2,ff2);
1494 gsl_matrix_set(A,3,3,ff3);
1497 gsl_linalg_LU_decomp(A,
p,&
s);
1498 gsl_linalg_LU_solve(A,
p,b,
x);
1501 pPhase->
a0 = gsl_vector_get(
x,0);
1502 pPhase->
a1 = gsl_vector_get(
x,1);
1503 pPhase->
a2 = gsl_vector_get(
x,2);
1504 pPhase->
a3 = gsl_vector_get(
x,3);
1518 printf(
"Inspiral Pseudo-PN Coefficients:\n");
1519 printf(
"a0 : %.6f\n",pPhase->
a0);
1520 printf(
"a1 : %.6f\n",pPhase->
a1);
1521 printf(
"a2 : %.6f\n",pPhase->
a2);
1522 printf(
"a3 : %.6f\n",pPhase->
a3);
1523 printf(
"a4 : %.6f\n",pPhase->
a4);
1531 gsl_permutation_free(
p);
1537 for(
i = 0;
i < 5;
i++)
1539 fi = gpoints5[
i] * deltax + xmin;
1557 printf(
"Inspiral Collocation Points and Values:\n");
1584 gsl_matrix_set(A,0,0,1.0);
1585 gsl_matrix_set(A,0,1,ff1);
1586 gsl_matrix_set(A,0,2,ff2);
1587 gsl_matrix_set(A,0,3,ff3);
1588 gsl_matrix_set(A,0,4,ff4);
1596 gsl_matrix_set(A,1,0,1.0);
1597 gsl_matrix_set(A,1,1,ff1);
1598 gsl_matrix_set(A,1,2,ff2);
1599 gsl_matrix_set(A,1,3,ff3);
1600 gsl_matrix_set(A,1,4,ff4);
1608 gsl_matrix_set(A,2,0,1.0);
1609 gsl_matrix_set(A,2,1,ff1);
1610 gsl_matrix_set(A,2,2,ff2);
1611 gsl_matrix_set(A,2,3,ff3);
1612 gsl_matrix_set(A,2,4,ff4);
1620 gsl_matrix_set(A,3,0,1.0);
1621 gsl_matrix_set(A,3,1,ff1);
1622 gsl_matrix_set(A,3,2,ff2);
1623 gsl_matrix_set(A,3,3,ff3);
1624 gsl_matrix_set(A,3,4,ff4);
1632 gsl_matrix_set(A,4,0,1.0);
1633 gsl_matrix_set(A,4,1,ff1);
1634 gsl_matrix_set(A,4,2,ff2);
1635 gsl_matrix_set(A,4,3,ff3);
1636 gsl_matrix_set(A,4,4,ff4);
1639 gsl_linalg_LU_decomp(A,
p,&
s);
1640 gsl_linalg_LU_solve(A,
p,b,
x);
1643 pPhase->
a0 = gsl_vector_get(
x,0);
1644 pPhase->
a1 = gsl_vector_get(
x,1);
1645 pPhase->
a2 = gsl_vector_get(
x,2);
1646 pPhase->
a3 = gsl_vector_get(
x,3);
1647 pPhase->
a4 = gsl_vector_get(
x,4);
1653 printf(
"Inspiral Pseudo-PN Coefficients:\n");
1654 printf(
"a0 : %.6f\n",pPhase->
a0);
1655 printf(
"a1 : %.6f\n",pPhase->
a1);
1656 printf(
"a2 : %.6f\n",pPhase->
a2);
1657 printf(
"a3 : %.6f\n",pPhase->
a3);
1658 printf(
"a4 : %.6f\n",pPhase->
a4);
1666 gsl_permutation_free(
p);
1670 XLALPrintError(
"Error in ComputeIMRPhenomXWaveformVariables: NPseudoPN requested is not valid.\n");
1675 pPhase->
sigma1 = (-5.0/3.0) * pPhase->
a0;
1676 pPhase->
sigma2 = (-5.0/4.0) * pPhase->
a1;
1677 pPhase->
sigma3 = (-5.0/5.0) * pPhase->
a2;
1678 pPhase->
sigma4 = (-5.0/6.0) * pPhase->
a3;
1679 pPhase->
sigma5 = (-5.0/7.0) * pPhase->
a4;
1682 pPhase->
dphi0 = 0.0;
1683 pPhase->
dphi1 = 0.0;
1684 pPhase->
dphi2 = 0.0;
1685 pPhase->
dphi3 = 0.0;
1686 pPhase->
dphi4 = 0.0;
1687 pPhase->
dphi5 = 0.0;
1688 pPhase->
dphi6 = 0.0;
1689 pPhase->
dphi7 = 0.0;
1690 pPhase->
dphi8 = 0.0;
1691 pPhase->
dphi9 = 0.0;
1711 pPhase->
phi10 = 0.0;
1712 pPhase->
phi11 = 0.0;
1713 pPhase->
phi12 = 0.0;
1715 pPhase->
phi5L = 0.0;
1716 pPhase->
phi6L = 0.0;
1717 pPhase->
phi8L = 0.0;
1718 pPhase->
phi9L = 0.0;
1743 UNUSED
REAL8 phi0S = 0.0, phi1S = 0.0, phi2S = 0.0;
1744 REAL8 phi0NS = 0.0, phi1NS = 0.0, phi2NS = 0.0;
1745 REAL8 phi3NS = 0.0, phi3S = 0.0, phi4NS = 0.0, phi4S = 0.0, phi5NS = 0.0, phi5S = 0.0;
1746 REAL8 phi5LNS = 0.0, phi5LS = 0.0, phi6NS = 0.0, phi6S = 0.0, phi6LNS = 0.0, phi6LS = 0.0;
1747 REAL8 phi7NS = 0.0, phi7S = 0.0, phi8NS = 0.0, phi8S = 0.0, phi8LNS = 0.0;
1748 REAL8 phi8LS = 0.0, phi9NS = 0.0, phi9S = 0.0, phi9LNS = 0.0, phi9LS = 0.0;
1782 phi5LS = ( (-732985*(chi1L + chi2L + chi1L*
delta - chi2L*
delta) - 560*(-1213*(chi1L + chi2L)
1787 phi6NS = ( 11583231236531/4.69421568e9 - (5*eta*(3147553127 + 588*eta*(-45633 + 102260*eta)))/3.048192e6 - (6848*
LAL_GAMMA)/21.
1792 phi6S += ( (5*(20*chi1L2L*eta*(11763 + 12488*eta) + 7*chi2L2*(-15103*(-1 +
delta) + 2*(-21683 + 6580*
delta)*eta - 9808*eta2) -
1803 phi7S = ( (5*(-5030016755*(chi1L + chi2L + chi1L*
delta - chi2L*
delta) + 4*(2113331119*(chi1L + chi2L) + 675484362*(chi1L - chi2L)*
delta)*eta - 1008*(208433*(chi1L + chi2L) + 25011*(chi1L - chi2L)*
delta)*eta2 + 90514368*(chi1L + chi2L)*eta3))/6.096384e6 ) *
powers_of_lalpi.
seven_thirds;
1807 phi7S += ( (14585*(-(chi2L3*(-1 +
delta)) + chi1L3*(1 +
delta)) - 5*(chi2L3*(8819 - 2985*
delta) + 8439*chi1L*chi2L2*(-1 +
delta) - 8439*chi1L2*chi2L*(1 +
delta) + chi1L3*(8819 + 2985*
delta))*eta + 40*(chi1L + chi2L)*(17*chi1L2 - 14*chi1L2L + 17*chi2L2)*eta2)/48. ) *
powers_of_lalpi.
seven_thirds;
1819 phi8LS = ((-5*(1263141*(chi1L + chi2L + chi1L*
delta - chi2L*
delta) - 2*(794075*(chi1L + chi2L) + 178533*(chi1L - chi2L)*
delta)*eta
1837 phi9NS += ( (5*(-256 + 451*eta)*
powers_of_lalpi.
three)/6. + (
LAL_PI*(105344279473163 + 700*eta*(-298583452147 + 96*eta*(99645337 + 14453257*eta)) -
1845 pPhase->
phi0 = phi0NS;
1848 pPhase->
phi1 = phi1NS;
1851 pPhase->
phi2 = phi2NS;
1854 pPhase->
phi3 = phi3NS + phi3S;
1857 pPhase->
phi4 = phi4NS + phi4S;
1860 pPhase->
phi5 = phi5NS + phi5S;
1863 pPhase->
phi5L = phi5LNS + phi5LS;
1866 pPhase->
phi6 = phi6NS + phi6S;
1869 pPhase->
phi6L = phi6LNS + phi6LS;
1872 pPhase->
phi7 = phi7NS + phi7S;
1875 pPhase->
phi8 = phi8NS + phi8S;
1878 pPhase->
phi8L = phi8LNS + phi8LS;
1881 pPhase->
phi9 = phi9NS + phi9S;
1884 pPhase->
phi9L = phi9LNS + phi9LS;
1889 printf(
"TaylorF2 PN Coefficients: \n");
1890 printf(
"phi0 : %.6f\n",pPhase->
phi0);
1891 printf(
"phi1 : %.6f\n",pPhase->
phi1);
1892 printf(
"phi2 : %.6f\n",pPhase->
phi2);
1893 printf(
"phi3 : %.6f\n",pPhase->
phi3);
1894 printf(
"phi4 : %.6f\n",pPhase->
phi4);
1895 printf(
"phi5 : %.6f\n",pPhase->
phi5);
1896 printf(
"phi6 : %.6f\n",pPhase->
phi6);
1897 printf(
"phi7 : %.6f\n",pPhase->
phi7);
1898 printf(
"phi8 : %.6f\n",pPhase->
phi8);
1900 printf(
"phi5L : %.6f\n",pPhase->
phi5L);
1901 printf(
"phi6L : %.6f\n",pPhase->
phi6L);
1902 printf(
"phi8L : %.6f\n",pPhase->
phi8L);
1904 printf(
"phi8P : %.6f\n",pPhase->
sigma1);
1905 printf(
"phi9P : %.6f\n",pPhase->
sigma2);
1906 printf(
"phi10P : %.6f\n",pPhase->
sigma3);
1907 printf(
"phi11P : %.6f\n",pPhase->
sigma4);
1908 printf(
"phi12P : %.6f\n",pPhase->
sigma5);
1915 pPhase->
dphi1 = 4.0 / 5.0 * pPhase->
phi1;
1916 pPhase->
dphi2 = 3.0 / 5.0 * pPhase->
phi2;
1917 pPhase->
dphi3 = 2.0 / 5.0 * pPhase->
phi3;
1918 pPhase->
dphi4 = 1.0 / 5.0 * pPhase->
phi4;
1920 pPhase->
dphi6 = -1.0 / 5.0 * pPhase->
phi6 - 3.0 / 5.0 * pPhase->
phi6L;
1922 pPhase->
dphi7 = -2.0 / 5.0 * pPhase->
phi7;
1923 pPhase->
dphi8 = -3.0 / 5.0 * pPhase->
phi8 - 3.0 / 5.0 * pPhase->
phi8L;
1925 pPhase->
dphi9 = -4.0 / 5.0 * pPhase->
phi9 - 3.0 / 5.0 * pPhase->
phi9L;
1930 printf(
"\nTaylorF2 PN Derivative Coefficients\n");
1931 printf(
"dphi0 : %.6f\n",pPhase->
dphi0);
1932 printf(
"dphi1 : %.6f\n",pPhase->
dphi1);
1933 printf(
"dphi2 : %.6f\n",pPhase->
dphi2);
1934 printf(
"dphi3 : %.6f\n",pPhase->
dphi3);
1935 printf(
"dphi4 : %.6f\n",pPhase->
dphi4);
1936 printf(
"dphi5 : %.6f\n",pPhase->
dphi5);
1937 printf(
"dphi6 : %.6f\n",pPhase->
dphi6);
1938 printf(
"dphi7 : %.6f\n",pPhase->
dphi7);
1939 printf(
"dphi8 : %.6f\n",pPhase->
dphi8);
1940 printf(
"dphi9 : %.6f\n",pPhase->
dphi9);
1942 printf(
"dphi6L : %.6f\n",pPhase->
dphi6L);
1943 printf(
"dphi8L : %.6f\n",pPhase->
dphi8L);
1944 printf(
"dphi9L : %.6f\n",pPhase->
dphi9L);
1953 printf(
"\nTransition frequency for ins to int : %.6f\n",pPhase->
fPhaseMatchIN);
1960 phaseIN = pPhase->
dphi0;
1963 phaseIN += pPhase->
dphi3 * powers_of_fmatchIN.
itself;
1966 phaseIN += pPhase->
dphi6 * powers_of_fmatchIN.
two;
1967 phaseIN += pPhase->
dphi6L * powers_of_fmatchIN.
two * powers_of_fmatchIN.
log;
1971 phaseIN += pPhase->
dphi9 * powers_of_fmatchIN.
three;
1972 phaseIN += pPhase->
dphi9L * powers_of_fmatchIN.
three * powers_of_fmatchIN.
log;
1976 + pPhase->
a1 * powers_of_fmatchIN.
three
2032 for(
i = 0;
i < 4;
i++)
2034 fi = gpoints4[
i] * deltax + xmin;
2063 ff1 = pWF->
fRING / ff;
2067 gsl_matrix_set(A,0,0,1.0);
2068 gsl_matrix_set(A,0,1,ff1);
2069 gsl_matrix_set(A,0,2,ff2);
2070 gsl_matrix_set(A,0,3,ff3);
2075 ff1 = 1.0 / (ff / pWF->
fRING);
2079 gsl_matrix_set(A,1,0,1);
2080 gsl_matrix_set(A,1,1,ff1);
2081 gsl_matrix_set(A,1,2,ff2);
2082 gsl_matrix_set(A,1,3,ff3);
2087 ff1 = 1.0 / (ff / pWF->
fRING);
2091 gsl_matrix_set(A,2,0,1);
2092 gsl_matrix_set(A,2,1,ff1);
2093 gsl_matrix_set(A,2,2,ff2);
2094 gsl_matrix_set(A,2,3,ff3);
2099 ff1 = 1.0 / (ff / pWF->
fRING);
2103 gsl_matrix_set(A,3,0,1);
2104 gsl_matrix_set(A,3,1,ff1);
2105 gsl_matrix_set(A,3,2,ff2);
2106 gsl_matrix_set(A,3,3,ff3);
2110 gsl_linalg_LU_decomp(A,
p,&
s);
2111 gsl_linalg_LU_solve(A,
p,b,
x);
2114 pPhase->
b0 = gsl_vector_get(
x,0);
2115 pPhase->
b1 = gsl_vector_get(
x,1) * pWF->
fRING;
2124 gsl_permutation_free(
p);
2130 for(
i = 0;
i < 5;
i++)
2132 fi = gpoints5[
i] * deltax + xmin;
2164 ff1 = pWF->
fRING / ff;
2169 gsl_matrix_set(A,0,0,1.0);
2170 gsl_matrix_set(A,0,1,ff1);
2171 gsl_matrix_set(A,0,2,ff2);
2172 gsl_matrix_set(A,0,3,ff3);
2173 gsl_matrix_set(A,0,4,ff4);
2178 printf(
"For row 0: a0 + a1 %.6f + a2 %.6f + a3 %.6f + a4 %.6f = %.6f , ff0 = %.6f, ff = %.6f\n",ff1,ff2,ff3,ff4,pPhase->
CollocationValuesPhaseInt[0] - ff0,ff0,ff);
2183 ff1 = pWF->
fRING / ff;
2188 gsl_matrix_set(A,1,0,1.0);
2189 gsl_matrix_set(A,1,1,ff1);
2190 gsl_matrix_set(A,1,2,ff2);
2191 gsl_matrix_set(A,1,3,ff3);
2192 gsl_matrix_set(A,1,4,ff4);
2197 printf(
"For row 1: a0 + a1 %.6f + a2 %.6f + a3 %.6f + a4 %.6f = %.6f\n",ff1,ff2,ff3,ff4,pPhase->
CollocationValuesPhaseInt[1] - ff0);
2202 ff1 = pWF->
fRING / ff;
2207 gsl_matrix_set(A,2,0,1.0);
2208 gsl_matrix_set(A,2,1,ff1);
2209 gsl_matrix_set(A,2,2,ff2);
2210 gsl_matrix_set(A,2,3,ff3);
2211 gsl_matrix_set(A,2,4,ff4);
2216 printf(
"For row 2: a0 + a1 %.6f + a2 %.6f + a3 %.6f + a4 %.6f = %.6f\n",ff1,ff2,ff3,ff4,pPhase->
CollocationValuesPhaseInt[2] - ff0);
2221 ff1 = pWF->
fRING / ff;
2226 gsl_matrix_set(A,3,0,1.0);
2227 gsl_matrix_set(A,3,1,ff1);
2228 gsl_matrix_set(A,3,2,ff2);
2229 gsl_matrix_set(A,3,3,ff3);
2230 gsl_matrix_set(A,3,4,ff4);
2235 printf(
"For row 3: a0 + a1 %.6f + a2 %.6f + a3 %.6f + a4 %.6f = %.6f\n",ff1,ff2,ff3,ff4,pPhase->
CollocationValuesPhaseInt[3] - ff0);
2240 ff1 = pWF->
fRING / ff;
2245 gsl_matrix_set(A,4,0,1.0);
2246 gsl_matrix_set(A,4,1,ff1);
2247 gsl_matrix_set(A,4,2,ff2);
2248 gsl_matrix_set(A,4,3,ff3);
2249 gsl_matrix_set(A,4,4,ff4);
2254 printf(
"For row 4: a0 + a1 %.6f + a2 %.6f + a3 %.6f + a4 %.6f = %.6f\n",ff1,ff2,ff3,ff4,pPhase->
CollocationValuesPhaseInt[4] - ff0);
2258 gsl_linalg_LU_decomp(A,
p,&
s);
2259 gsl_linalg_LU_solve(A,
p,b,
x);
2262 pPhase->
b0 = gsl_vector_get(
x,0);
2263 pPhase->
b1 = gsl_vector_get(
x,1) * pWF->
fRING;
2271 printf(
"Intermediate Collocation Points and Values:\n");
2278 printf(
"V's agree with Mathematica...\n");
2285 printf(
"g0 : %.7f\n",gsl_vector_get(
x,0));
2286 printf(
"g1 : %.7f\n",gsl_vector_get(
x,1));
2287 printf(
"g2 : %.7f\n",gsl_vector_get(
x,2));
2288 printf(
"g3 : %.7f\n",gsl_vector_get(
x,3));
2289 printf(
"g4 : %.7f\n",gsl_vector_get(
x,4));
2291 printf(
"b0 : %.7f\n",pPhase->
b0);
2292 printf(
"b1 : %.7f\n",pPhase->
b1);
2293 printf(
"b2 : %.7f\n",pPhase->
b2);
2294 printf(
"b3 : %.7f\n",pPhase->
b3);
2295 printf(
"b4 : %.7f\n",pPhase->
b4);
2303 gsl_permutation_free(
p);
2307 XLALPrintError(
"Error in ComputeIMRPhenomXWaveformVariables: IMRPhenomXIntermediatePhaseVersion is not valid.\n");
2343 pPhase->
cLGR = pPhase->
cL;
2344 pPhase->
c1 *= (1.0 + nonGR_dc1);
2345 pPhase->
c2 *= (1.0 + nonGR_dc2);
2346 pPhase->
c4 *= (1.0 + nonGR_dc4);
2347 pPhase->
cL *= (1.0 + nonGR_dcl);
2350 pPhase->
c4ov3 = pPhase->
c4 / 3.0;
2360 pPhase->
b1 *= (1.0 + nonGR_db1);
2361 pPhase->
b2 *= (1.0 + nonGR_db2);
2362 pPhase->
b4 *= (1.0 + nonGR_db4);
2366 pPhase->
b1 *= (1.0 + nonGR_db1);
2367 pPhase->
b2 *= (1.0 + nonGR_db2);
2368 pPhase->
b3 *= (1.0 + nonGR_db3);
2369 pPhase->
b4 *= (1.0 + nonGR_db4);
2373 XLALPrintError(
"Error in ComputeIMRPhenomXWaveformVariables: IMRPhenomXIntermediatePhaseVersion is not valid.\n");
2388 int tgr_parameterization = 0;
2391 if(tgr_parameterization == 1)
2400 pPhase->
phi0 = (phi0NS + phi0S)*(1.0 + dchi0);
2406 pPhase->
phi2 = (phi2NS + phi2S)*(1.0 + dchi2);
2409 pPhase->
phi3 = (phi3NS + phi3S)*(1.0 + dchi3);
2412 pPhase->
phi4 = (phi4NS + phi4S)*(1.0 + dchi4);
2415 pPhase->
phi5 = (phi5NS + phi5S)*(1.0 + dchi5);
2418 pPhase->
phi5L = (phi5LNS + phi5LS)*(1.0 + dchi5L);
2421 pPhase->
phi6 = (phi6NS + phi6S)*(1.0 + dchi6);
2424 pPhase->
phi6L = (phi6LNS + phi6LS)*(1.0 + dchi6L);
2427 pPhase->
phi7 = (phi7NS + phi7S)*(1.0 + dchi7);
2430 pPhase->
phi8 = (phi8NS + phi8S)*(1.0 + dchi8);
2433 pPhase->
phi8L = (phi8LNS + phi8LS)*(1.0 + dchi8L);
2436 pPhase->
phi9 = (phi9NS + phi9S)*(1.0 + dchi9);
2439 pPhase->
phi9L = (phi9LNS + phi9LS)*(1.0 + dchi9L);
2441 else if(tgr_parameterization == 0)
2450 pPhase->
phi0 = phi0NS*(1.0 + dchi0) + phi0S;
2456 pPhase->
phi2 = phi2NS*(1.0 + dchi2) + phi2S;
2459 pPhase->
phi3 = phi3NS*(1.0 + dchi3)+ phi3S;
2462 pPhase->
phi4 = phi4NS*(1.0 + dchi4) + phi4S;
2465 pPhase->
phi5 = phi5NS*(1.0 + dchi5) + phi5S;
2468 pPhase->
phi5L = phi5LNS*(1.0 + dchi5L) + phi5LS;
2471 pPhase->
phi6 = phi6NS*(1.0 + dchi6) + phi6S;
2474 pPhase->
phi6L = phi6LNS*(1.0 + dchi6L) + phi6LS;
2477 pPhase->
phi7 = phi7NS*(1.0 + dchi7) + phi7S;
2480 pPhase->
phi8 = phi8NS*(1.0 + dchi8) + phi8S;
2483 pPhase->
phi8L = phi8LNS*(1.0 + dchi8L) + phi8LS;
2486 pPhase->
phi9 = phi9NS*(1.0 + dchi9) + phi9S;
2489 pPhase->
phi9L = phi9LNS*(1.0 + dchi9L) + phi9LS;
2493 XLALPrintError(
"Error in IMRPhenomXGetPhaseCoefficients: TGR Parameterizataion is not valid.\n");
2499 pPhase->
dphi0 = +(5.0 / 5.0) * pPhase->
phi0;
2500 pPhase->
dphi1 = +(4.0 / 5.0) * pPhase->
phi1;
2501 pPhase->
dphi2 = +(3.0 / 5.0) * pPhase->
phi2;
2502 pPhase->
dphi3 = +(2.0 / 5.0) * pPhase->
phi3;
2503 pPhase->
dphi4 = +(1.0 / 5.0) * pPhase->
phi4;
2504 pPhase->
dphi5 = -(3.0 / 5.0) * pPhase->
phi5L;
2505 pPhase->
dphi6 = -(1.0 / 5.0) * pPhase->
phi6 - (3.0 / 5.0) * pPhase->
phi6L;
2507 pPhase->
dphi7 = -(2.0 / 5.0) * pPhase->
phi7;
2508 pPhase->
dphi8 = -(3.0 / 5.0) * pPhase->
phi8 - (3.0 / 5.0) * pPhase->
phi8L;
2510 pPhase->
dphi9 = -(4.0 / 5.0) * pPhase->
phi9 - (3.0 / 5.0) * pPhase->
phi9L;
2526 int debug = pWF->
debug;
2553 pPhase->
C2Int = DPhiIns - DPhiInt;
2561 printf(
"dphiIM = %.6f and dphiIN = %.6f\n",DPhiInt,DPhiIns);
2562 printf(
"phiIN(fIns) : %.7f\n",phiIN);
2563 printf(
"phiIM(fIns) : %.7f\n",phiIM);
2564 printf(
"fIns : %.7f\n",fIns);
2565 printf(
"C2 : %.7f\n",pPhase->
C2Int);
2569 pPhase->
C1Int = phiIN - phiIM - (pPhase->
C2Int * fIns);
2595 pPhase->
C2MRD = DPhiIntC - DPhiRD;
2596 pPhase->
C1MRD = phiIMC - phiRD - pPhase->
C2MRD*fInt;
2601 printf(
"phiIMC(fInt) : %.7f\n",phiIMC);
2602 printf(
"phiRD(fInt) : %.7f\n",phiRD);
2603 printf(
"fInt : %.7f\n",fInt);
2604 printf(
"C2 : %.7f\n",pPhase->
C2Int);
2610 printf(
"dphiIM = %.6f and dphiRD = %.6f\n",DPhiIntC,DPhiRD);
2611 printf(
"\nContinuity Coefficients\n");
2612 printf(
"C1Int : %.6f\n",pPhase->
C1Int);
2613 printf(
"C2Int : %.6f\n",pPhase->
C2Int);
2614 printf(
"C1MRD : %.6f\n",pPhase->
C1MRD);
2615 printf(
"C2MRD : %.6f\n",pPhase->
C2MRD);
2623 REAL8 linb, tshift, dphi22Ref,frefFit;
2634 tshift = linb-dphi22Ref -2.*
LAL_PI*(500+psi4tostrain);
2745 INT4 larray[5] = {2, 2, 3, 3, 4};
2746 INT4 marray[5] = {2, 1, 3, 2, 4};
2750 for(
INT4 emm=0; emm<=ell; emm++)
2754 for(
UINT4 idx=0; idx<5; idx++)
2756 if(ell==larray[idx] && abs(emm)==marray[idx])
2763 XLALPrintError (
"Mode (%d,%d) is not available by the model.\n", ell, emm);
2845 *phase = pre_phase * inveta;
2846 *phase += linb*Mf + lina + phifRef;
2851 *dphase = pre_dphase * inveta;
2865 switch(tidal_version){
2877 XLAL_ERROR(
XLAL_EINVAL,
"Error: Tidal version not recognized. Only NRTidal, NRTidalv2, and NoNRT are allowed, and NRTidal is not implemented completely in IMRPhenomX*.\n");
2893 REAL8 SS_3p5PN = 0., SSS_3p5PN = 0.;
2922 REAL8 phaseTidal=0.;
2924 REAL8 pfaN=3./(128.*X_A*X_B);
2936 REAL8 NRTidalv2_coeffs[9];
2942 const REAL8 cNewt = NRTidalv2_coeffs[0];
2943 const REAL8 n1 = NRTidalv2_coeffs[1];
2944 const REAL8 n3over2 = NRTidalv2_coeffs[2];
2945 const REAL8 n2 = NRTidalv2_coeffs[3];
2946 const REAL8 n5over2 = NRTidalv2_coeffs[4];
2947 const REAL8 n3 = NRTidalv2_coeffs[5];
2948 const REAL8 d1 = NRTidalv2_coeffs[6];
2949 const REAL8 d3over2 = NRTidalv2_coeffs[7];
2950 const REAL8 d2 = NRTidalv2_coeffs[8];
2956 phaseTidal+=NRphase;
2964 XLAL_ERROR(
XLAL_EINVAL,
"Error in IMRPhenomX_TidalPhase: Unsupported NRTidal_version. This function currently only supports NRTidalv2.\n");
2983 REAL8 NRTuned_dphase=0.;
2985 REAL8 pfaN=3./(128.*X_A*X_B);
2989 REAL8 dphase=threePN_dphase;
2996 REAL8 NRTidalv2_coeffs[9];
3002 const REAL8 cNewt = NRTidalv2_coeffs[0];
3003 const REAL8 n1 = NRTidalv2_coeffs[1];
3004 const REAL8 n3over2 = NRTidalv2_coeffs[2];
3005 const REAL8 n2 = NRTidalv2_coeffs[3];
3006 const REAL8 n5over2 = NRTidalv2_coeffs[4];
3007 const REAL8 n3 = NRTidalv2_coeffs[5];
3008 const REAL8 d1 = NRTidalv2_coeffs[6];
3009 const REAL8 d3over2 = NRTidalv2_coeffs[7];
3010 const REAL8 d2 = NRTidalv2_coeffs[8];
3019 XLAL_ERROR(
XLAL_EINVAL,
"Error in IMRPhenomX_TidalPhaseDerivative: Unsupported NRTidal_version. This function currently only supports NRTidalv2.\n");
3022 dphase+=NRTuned_dphase;
void XLALSimInspiralGetHOSpinTerms(REAL8 *SS_3p5PN, REAL8 *SSS_3p5PN, REAL8 X_A, REAL8 X_B, REAL8 chi1, REAL8 chi2, REAL8 quadparam1, REAL8 quadparam2)
Function to add 3.5PN spin-squared and 3.5PN spin-cubed terms.
int XLALSimNRTunedTidesSetFDTidalPhase_v2_Coeffs(REAL8 *NRTidalv2_coeffs)
Set the NRTidalv2 phase coefficients in an array for use here and in the IMRPhenomX*_NRTidalv2 implem...
double XLALSimNRTunedTidesMergerFrequency(const REAL8 mtot_MSUN, const REAL8 kappa2T, const REAL8 q)
compute the merger frequency of a BNS system.
double XLALSimNRTunedTidesComputeKappa2T(REAL8 m1_SI, REAL8 m2_SI, REAL8 lambda1, REAL8 lambda2)
convenient function to compute tidal coupling constant.
static double evaluate_QNMfit_fdamp22(double finalDimlessSpin)
static double evaluate_QNMfit_fring22(double finalDimlessSpin)
static double double delta
IMRPhenomX_UsefulPowers powers_of_lalpi
static double IMRPhenomX_Inspiral_Phase_22_Ansatz(double Mf, IMRPhenomX_UsefulPowers *powers_of_Mf, IMRPhenomXPhaseCoefficients *pPhase)
static double IMRPhenomX_Inspiral_Amp_22_v2(double eta, double S, double dchi, double delta, int InsAmpFlag)
static double IMRPhenomX_Inspiral_Amp_22_v4(double eta, double S, double dchi, double delta, int InsAmpFlag)
static double IMRPhenomX_Inspiral_Phase_22_AnsatzInt(double Mf, IMRPhenomX_UsefulPowers *powers_of_Mf, IMRPhenomXPhaseCoefficients *pPhase)
Ansatz for the inspiral phase.
static double IMRPhenomX_Inspiral_Phase_22_v3(double eta, double S, double dchi, double delta, int InspPhaseFlag)
static double IMRPhenomX_Inspiral_Amp_22_v3(double eta, double S, double dchi, double delta, int InsAmpFlag)
static double IMRPhenomX_Inspiral_Amp_22_Ansatz(double Mf, IMRPhenomX_UsefulPowers *powers_of_Mf, IMRPhenomXWaveformStruct *pWF, IMRPhenomXAmpCoefficients *pAmp)
static double IMRPhenomX_Inspiral_Phase_22_d43(double eta, double S, double dchi, double delta, int InspPhaseFlag)
static double IMRPhenomX_Inspiral_Phase_22_d53(double eta, double S, double dchi, double delta, int InspPhaseFlag)
static double IMRPhenomX_Inspiral_Amp_22_rho3(double v1, double v2, double v3, double F1, double F2, double F3, int InsAmpFlag)
static double IMRPhenomX_Inspiral_Phase_22_d13(double eta, double S, double dchi, double delta, int InspPhaseFlag)
static double IMRPhenomX_Inspiral_Phase_22_d23(double eta, double S, double dchi, double delta, int InspPhaseFlag)
static double IMRPhenomX_Inspiral_Amp_22_DAnsatz(double Mf, IMRPhenomXWaveformStruct *pWF, IMRPhenomXAmpCoefficients *pAmp)
static double IMRPhenomX_Inspiral_Amp_22_rho1(double v1, double v2, double v3, double F1, double F2, double F3, int InsAmpFlag)
static double IMRPhenomX_Inspiral_Amp_22_rho2(double v1, double v2, double v3, double F1, double F2, double F3, int InsAmpFlag)
int IMRPhenomXSetWaveformVariables(IMRPhenomXWaveformStruct *wf, const REAL8 m1_SI, const REAL8 m2_SI, const REAL8 chi1L_In, const REAL8 chi2L_In, const REAL8 deltaF, const REAL8 fRef, const REAL8 phi0, const REAL8 f_min, const REAL8 f_max, const REAL8 distance, const REAL8 inclination, LALDict *LALParams, UNUSED const UINT4 debug)
NRTidal_version_type IMRPhenomX_SetTidalVersion(LALDict *lalParams)
double IMRPhenomX_TimeShift_22(IMRPhenomXPhaseCoefficients *pPhase, IMRPhenomXWaveformStruct *pWF)
REAL8 IMRPhenomX_TidalPhaseDerivative(IMRPhenomX_UsefulPowers *powers_of_Mf, IMRPhenomXWaveformStruct *pWF, IMRPhenomXPhaseCoefficients *pPhase, NRTidal_version_type NRTidal_version)
void IMRPhenomX_Phase_22_ConnectionCoefficients(IMRPhenomXWaveformStruct *pWF, IMRPhenomXPhaseCoefficients *pPhase)
int IMRPhenomXGetAmplitudeCoefficients(IMRPhenomXWaveformStruct *pWF, IMRPhenomXAmpCoefficients *pAmp)
int IMRPhenomX_Initialize_Powers(IMRPhenomX_UsefulPowers *p, REAL8 number)
double IMRPhenomX_Phase_22(double ff, IMRPhenomX_UsefulPowers *powers_of_f, IMRPhenomXPhaseCoefficients *pPhase, IMRPhenomXWaveformStruct *pWF)
void IMRPhenomXGetTidalPhaseCoefficients(IMRPhenomXWaveformStruct *pWF, IMRPhenomXPhaseCoefficients *pPhase, NRTidal_version_type NRTidal_version)
REAL8 IMRPhenomX_TidalPhase(IMRPhenomX_UsefulPowers *powers_of_Mf, IMRPhenomXWaveformStruct *pWF, IMRPhenomXPhaseCoefficients *pPhase, NRTidal_version_type NRTidal_version)
int IMRPhenomX_Initialize_Powers_Light(IMRPhenomX_UsefulPowers *p, REAL8 number)
int IMRPhenomXGetPhaseCoefficients(IMRPhenomXWaveformStruct *pWF, IMRPhenomXPhaseCoefficients *pPhase)
double IMRPhenomX_dPhase_22(double ff, IMRPhenomX_UsefulPowers *powers_of_f, IMRPhenomXPhaseCoefficients *pPhase, IMRPhenomXWaveformStruct *pWF)
INT4 check_input_mode_array(LALDict *lalParams)
INT4 IMRPhenomX_FullPhase_22(double *phase, double *dphase, double Mf, IMRPhenomXPhaseCoefficients *pPhase, IMRPhenomXWaveformStruct *pWF)
double IMRPhenomX_Amplitude_22(double ff, IMRPhenomX_UsefulPowers *powers_of_f, IMRPhenomXAmpCoefficients *pAmp, IMRPhenomXWaveformStruct *pWF)
Internal function for IMRPhenomX phenomenological waveform model, arXiv:2001.11412 See LALSimIMRPheno...
static double IMRPhenomX_Ringdown_Amp_22_gamma2(double eta, double S, double dchi, double delta, int RDAmpFlag)
static double IMRPhenomX_Ringdown_Phase_22_v4(double eta, double S, double dchi, double delta, int RDPhaseFlag)
static double IMRPhenomX_Ringdown_Phase_22_d24(double eta, double S, double dchi, double delta, int RDPhaseFlag)
static double IMRPhenomX_Ringdown_Amp_22_v1(double eta, double S, double dchi, double delta, int RDAmpFlag)
static double IMRPhenomX_Ringdown_Phase_22_AnsatzInt(double ff, IMRPhenomX_UsefulPowers *powers_of_f, IMRPhenomXWaveformStruct *pWF, IMRPhenomXPhaseCoefficients *pPhase)
static double IMRPhenomX_Ringdown_Phase_22_d12(double eta, double S, double dchi, double delta, int RDPhaseFlag)
static double IMRPhenomX_Ringdown_Phase_22_d34(double eta, double S, double dchi, double delta, int RDPhaseFlag)
static double IMRPhenomX_Ringdown_Amp_22_PeakFrequency(double gamma2, double gamma3, double frd, double fda, int RDAmpFlag)
static double IMRPhenomX_Ringdown_Phase_22_Ansatz(double ff, IMRPhenomX_UsefulPowers *powers_of_f, IMRPhenomXWaveformStruct *pWF, IMRPhenomXPhaseCoefficients *pPhase)
static double IMRPhenomX_Ringdown_Amp_22_DAnsatz(double ff, IMRPhenomXWaveformStruct *pWF, IMRPhenomXAmpCoefficients *pAmp)
static double IMRPhenomX_Ringdown_Phase_22_d54(double eta, double S, double dchi, double delta, int RDPhaseFlag)
static double IMRPhenomX_Ringdown_Amp_22_Ansatz(double ff, IMRPhenomXWaveformStruct *pWF, IMRPhenomXAmpCoefficients *pAmp)
static double IMRPhenomX_Ringdown_Amp_22_gamma3(double eta, double S, double dchi, double delta, int RDAmpFlag)
REAL8 XLALSimIMRPhenomXfMECO(REAL8 eta, REAL8 chi1L, REAL8 chi2L)
Phenomenological fit to hybrid minimum energy circular orbit (MECO) function.
void IMRPhenomX_InternalNudge(REAL8 x, REAL8 X, REAL8 epsilon)
If x and X are approximately equal to relative accuracy epsilon then set x = X.
REAL8 XLALSimIMRPhenomXFinalMass2017(REAL8 eta, REAL8 chi1L, REAL8 chi2L)
Final Mass = 1 - Energy Radiated, X Jimenez-Forteza et al, PRD, 95, 064024, (2017),...
REAL8 XLALSimIMRPhenomXfISCO(REAL8 chif)
Fitting function for hybrid minimum energy circular orbit (MECO) function.
REAL8 XLALSimIMRPhenomXFinalSpin2017(REAL8 eta, REAL8 chi1L, REAL8 chi2L)
Final Dimensionless Spin, X Jimenez-Forteza et al, PRD, 95, 064024, (2017), arXiv:1611....
bool IMRPhenomX_StepFuncBool(const double t, const double t1)
REAL8 XLALSimIMRPhenomXUtilsHztoMf(REAL8 fHz, REAL8 Mtot_Msun)
Convert from frequency in Hz to geometric frequency.
REAL8 XLALSimIMRPhenomXSTotR(REAL8 eta, REAL8 chi1L, REAL8 chi2L)
Total spin normalised to [-1,1].
REAL8 XLALSimIMRPhenomXdchi(REAL8 chi1L, REAL8 chi2L)
Spin difference.
REAL8 XLALSimIMRPhenomXPsi4ToStrain(double eta, double S, double dchi)
This is a fit of the time-difference between t_peak of strain and t_peak of psi4 needed to align in t...
REAL8 XLALSimIMRPhenomXchiPNHat(REAL8 eta, REAL8 chi1L, REAL8 chi2L)
Normalised PN reduced spin parameter.
REAL8 XLALSimIMRPhenomXLinb(REAL8 eta, REAL8 S, REAL8 dchi, REAL8 delta)
REAL8 XLALSimIMRPhenomXchiEff(REAL8 eta, REAL8 chi1L, REAL8 chi2L)
Effective aligned spin parameter.
int XLALSimInspiralSetQuadMonParamsFromLambdas(LALDict *LALparams)
if you do NOT provide a quadparam[1,2] term and you DO provide lamdba[1,2] then we calculate quad-mon...
static REAL8 UNUSED XLALSimInspiralTaylorF2Phasing_4PNQM2SOCoeff(REAL8 mByM)
static REAL8 UNUSED XLALSimInspiralTaylorF2Phasing_6PNQM2SCoeff(REAL8 mByM)
static REAL8 UNUSED XLALSimInspiralTaylorF2Phasing_4PNQM2SCoeff(REAL8 mByM)
void XLALDestroyValue(LALValue *value)
@ NRTidal_V
version NRTidal: based on https://arxiv.org/pdf/1706.02969.pdf
@ NoNRT_V
special case for PhenomPv2 BBH baseline
@ NRTidalv2_V
version NRTidalv2: https://arxiv.org/abs/1905.06011
#define LAL_SIM_L_MAX_MODE_ARRAY
Maximum L spherical harmonic mode that is supported in Mode Array.
#define XLAL_ERROR_REAL8(...)
#define XLAL_CHECK(assertion,...)
#define XLAL_PRINT_WARNING(...)
int XLALPrintError(const char *fmt,...) _LAL_GCC_PRINTF_FORMAT_(1
REAL8 CollocationPointsAmpIns[N_MAX_COLLOCATION_POINTS_AMP_INS]
REAL8 CollocationValuesAmpIns[N_MAX_COLLOCATION_POINTS_AMP_INS]
INT4 NCollocationPointsInt
INT4 NCollocationPointsRD
REAL8 CollocationPointsPhaseRD[N_MAX_COLLOCATION_POINTS_PHASE_RD]
INT4 NCollocationPointsPhaseIns
REAL8 CollocationPointsPhaseInt[N_MAX_COLLOCATION_POINTS_PHASE_INT]
REAL8 CollocationValuesPhaseIns[N_MAX_COLLOCATION_POINTS_PHASE_INS]
REAL8 CollocationValuesPhaseInt[N_MAX_COLLOCATION_POINTS_PHASE_INT]
REAL8 CollocationPointsPhaseIns[N_MAX_COLLOCATION_POINTS_PHASE_INS]
REAL8 CollocationValuesPhaseRD[N_MAX_COLLOCATION_POINTS_PHASE_RD]