33#include <lal/LALInspiral.h>
34#include <lal/LALEOBNRv2Waveform.h>
36#include <gsl/gsl_sf_gamma.h>
71 for (
m = 1;
m <=
l;
m++ )
96 INT4 epsilon = (
l +
m) % 2;
108 if ( (
l == 4 &&
m == 4) || (
l == 2 &&
m == 1 ) )
110 *multipole =
params->prefixes->values[
l][
m] * (pow(
x, (
REAL8)(
l+epsilon)/2.0 - 1.0)/
r);
114 *multipole =
params->prefixes->values[
l][
m] * (pow(
x, (
REAL8)(
l+epsilon)/2.0));
116 *multipole = *multipole *
y;
136 INT4 absM = abs(
m );
138 if ( l < 0 || absM > (
INT4)
l )
152 *
y =
crect( legendre * cos(
m * phi), legendre * sin(
m * phi) );
155 if (
m < 0 && absM % 2 == 1 )
178 if ( m < 0 || m >
l )
296 legendre = - 135135.;
308 legendre = - 118.125;
330 legendre = - 67567.5;
342 legendre = - 19.6875;
356 legendre *= sqrt( (
REAL8)(2*
l+1)*gsl_sf_fact(
l-
m ) / (4.*
LAL_PI*gsl_sf_fact(
l+
m)));
390 epsilon = (
l +
m ) % 2;
395 eta = m1*m2/(totalMass*totalMass);
397 if ( abs(
m % 2 ) == 0 )
406 c = pow( x2,
l + epsilon - 1 ) + sign * pow(x1,
l + epsilon - 1 );
415 mult1 = 8.0 *
LAL_PI / gsl_sf_doublefact(2u*
l + 1u);
422 else if ( epsilon == 1 )
429 mult1 = 16.*
LAL_PI / gsl_sf_doublefact( 2u*
l + 1u );
431 mult2 = (
REAL8)( (2*
l + 1) * (
l+2) * (
l*
l -
m*
m) );
432 mult2 /= (
REAL8)( (2*
l - 1) * (
l+1) *
l * (
l-1) );
444 *prefix =
n * ( eta *
c );
static int CalculateThisMultipolePrefix(COMPLEX16 *prefix, const REAL8 m1, const REAL8 m2, const INT4 l, const INT4 m)
static REAL8 XLALAssociatedLegendreXIsZero(const int l, const int m)
static int XLALScalarSphHarmThetaPiBy2(COMPLEX16 *y, INT4 l, INT4 m, REAL8 phi)
#define XLAL_ERROR_REAL8(...)
int XLALPrintError(const char *fmt,...) _LAL_GCC_PRINTF_FORMAT_(1
#define XLAL_IS_REAL8_FAIL_NAN(val)
COMPLEX16 values[LALEOB_MAX_MULTIPOLE+1][LALEOB_MAX_MULTIPOLE+1]