LALSimInspiralPNMode.c

Go to the documentation of this file.
00001 /*
00002  * Copyright (C) 2008 J. Creighton
00003  *
00004  *  This program is free software; you can redistribute it and/or modify
00005  *  it under the terms of the GNU General Public License as published by
00006  *  the Free Software Foundation; either version 2 of the License, or
00007  *  (at your option) any later version.
00008  *
00009  *  This program is distributed in the hope that it will be useful,
00010  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012  *  GNU General Public License for more details.
00013  *
00014  *  You should have received a copy of the GNU General Public License
00015  *  along with with program; see the file COPYING. If not, write to the 
00016  *  Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, 
00017  *  MA  02111-1307  USA
00018  */
00019 
00020 #include <math.h>
00021 #include <lal/LALStdlib.h>
00022 #include <lal/LALSimInspiral.h>
00023 #define LAL_USE_COMPLEX_SHORT_MACROS
00024 #include <lal/LALComplex.h>
00025 #include <lal/LALConstants.h>
00026 
00027 NRCSID(LALSIMINSPIRALPNMODEC, "$Id: LALSimInspiralPNMode.c,v 1.3 2008/03/20 00:31:58 jolien Exp $");
00028 
00029 /**
00030  * Computes h(2,2) mode of spherical harmonic decomposition of
00031  * the post-Newtonian inspiral waveform.
00032  *
00033  * Implements Equation (79) of:
00034  * Lawrence E. Kidder, "Using Full Information When Computing Modes of
00035  * Post-Newtonian Waveforms From Inspiralling Compact Binaries in Circular
00036  * Orbit", Physical Review D 77, 044016 (2008), arXiv:0710.0614v1 [gr-qc].
00037  */
00038 COMPLEX16 XLALSimInspiralPNMode22(
00039                 REAL8 x,      /**< post-Newtonian parameter */
00040                 REAL8 phi,    /**< orbital phase */
00041                 REAL8 logx,   /**< log(x/x0) tail gauge parameter */
00042                 REAL8 m1,     /**< mass of companion 1 */
00043                 REAL8 m2,     /**< mass of companion 2 */
00044                 REAL8 r,      /**< distance of source */
00045                 int O         /**< twice post-Newtonian order */
00046                 )
00047 {
00048         static const char *func = "XLALSimInspiralPNMode22";
00049         REAL8 fac = -8.0*sqrt(LAL_PI/5.0)*LAL_G_SI*pow(LAL_C_SI, -2.0);
00050         REAL8 m = m1 + m2;
00051         REAL8 mu = m1*m2/m;
00052         REAL8 nu = mu/m;
00053         COMPLEX16 ans;
00054         REAL8 re = 0.0;
00055         REAL8 im = 0.0;
00056         switch (O) {
00057                 default: /* unsupported pN order */
00058                         XLALPrintError("XLAL Error - %s: PN order %d%s not supported\n", func, O/2, O%2?".5":"" );
00059                         XLAL_ERROR_VAL(func, XLAL_EINVAL, czero);
00060                 case -1: /* use highest available pN order */
00061                 case 6:
00062                         re += ((27027409.0/646800.0) - (856.0/105.0)*LAL_GAMMA + (2.0/3.0)*pow(LAL_PI, 2.0) - (1712.0/105.0)*log(2.0) - (428.0/105.0)*log(x) - 18.0*pow(logx, 2.0) - ((278185.0/33264.0) - (41.0/96.0)*pow(LAL_PI, 2.0))*nu - (20261.0/2772.0)*pow(nu, 2.0) + (114635.0/99792.0)*pow(nu, 3.0))*pow(x, 3.0);
00063                         im += ((428.0/105.0) + 12.0*logx)*LAL_PI*pow(x, 3.0);
00064                 case 5:
00065                         re -= ((107.0/21.0) - (34.0/21.0)*nu)*LAL_PI*pow(x, 2.5);
00066                         im -= (24.0*nu + ((107.0/7.0) - (34.0/7.0)*nu)*logx)*pow(x, 2.5);
00067                 case 4:
00068                         re -= ((2173.0/1512.0) + (1069.0/216.0)*nu - (2047.0/1512.0)*pow(nu, 2.0))*pow(x, 2.0);
00069                 case 3:
00070                         re += 2.0*LAL_PI*pow(x, 1.5);
00071                         im += 6.0*logx*pow(x, 1.5);
00072                 case 2:
00073                         re -= ((107.0/42.0) - (55.0/42.0)*nu)*x;
00074                 case 1:
00075                 case 0:
00076                         re += 1.0;
00077         }
00078         ans = cmul(cpolar(1.0, -2.0*phi), crect(re, im));
00079         ans = cmulr(ans, (fac*nu*m/r)*x);
00080         return ans;
00081 }
00082 
00083 /**
00084  * Computes h(2,1) mode of spherical harmonic decomposition of
00085  * the post-Newtonian inspiral waveform.
00086  *
00087  * Implements Equation (80) of:
00088  * Lawrence E. Kidder, "Using Full Information When Computing Modes of
00089  * Post-Newtonian Waveforms From Inspiralling Compact Binaries in Circular
00090  * Orbit", Physical Review D 77, 044016 (2008), arXiv:0710.0614v1 [gr-qc].
00091  */
00092 COMPLEX16 XLALSimInspiralPNMode21(
00093                 REAL8 x,      /**< post-Newtonian parameter */
00094                 REAL8 phi,    /**< orbital phase */
00095                 REAL8 logx,   /**< log(x/x0) tail gauge parameter */
00096                 REAL8 m1,     /**< mass of companion 1 */
00097                 REAL8 m2,     /**< mass of companion 2 */
00098                 REAL8 r,      /**< distance of source */
00099                 int O         /**< twice post-Newtonian order */
00100                 )
00101 {
00102         static const char *func = "XLALSimInspiralPNMode21";
00103         REAL8 fac = -8.0*sqrt(LAL_PI/5.0)*LAL_G_SI*pow(LAL_C_SI, -2.0);
00104         REAL8 m = m1 + m2;
00105         REAL8 dm = m1 - m2;
00106         REAL8 mu = m1*m2/m;
00107         REAL8 nu = mu/m;
00108         COMPLEX16 ans;
00109         REAL8 re = 0.0;
00110         REAL8 im = 0.0;
00111         switch (O) {
00112                 default: /* unsupported pN order */
00113                         XLALPrintError("XLAL Error - %s: PN order %d%s not supported\n", func, O/2, O%2?".5":"" );
00114                         XLAL_ERROR_VAL(func, XLAL_EINVAL, czero);
00115                 case -1: /* use highest available pN order */
00116                 case 5:
00117                         re -= ((43.0/126.0) + (509.0/126.0)*nu - (79.0/168.0)*pow(nu, 2.0))*pow(x, 2.0);
00118                 case 4:
00119                         re += LAL_PI*pow(x, 1.5);
00120                         im += (-(1.0/2.0) - 2.0*log(2.0) + 3.0*logx)*pow(x, 1.5);
00121                 case 3:
00122                         re -= ((17.0/28.0) - (5.0/7.0)*nu)*x;
00123                 case 2:
00124                 case 1:
00125                         re += 1.0;
00126                 case 0:
00127                         re += 0.0;
00128         }
00129         ans = cmul(cpolar(1.0, -phi), crect(re, im));
00130         ans = cmuli(ans, (fac*nu*dm/r)*pow(x, 1.5));
00131         return ans;
00132 }
00133 
00134 /**
00135  * Computes h(3,3) mode of spherical harmonic decomposition of
00136  * the post-Newtonian inspiral waveform.
00137  *
00138  * Implements Equation (82) of:
00139  * Lawrence E. Kidder, "Using Full Information When Computing Modes of
00140  * Post-Newtonian Waveforms From Inspiralling Compact Binaries in Circular
00141  * Orbit", Physical Review D 77, 044016 (2008), arXiv:0710.0614v1 [gr-qc].
00142  */
00143 COMPLEX16 XLALSimInspiralPNMode33(
00144                 REAL8 x,      /**< post-Newtonian parameter */
00145                 REAL8 phi,    /**< orbital phase */
00146                 REAL8 logx,   /**< log(x/x0) tail gauge parameter */
00147                 REAL8 m1,     /**< mass of companion 1 */
00148                 REAL8 m2,     /**< mass of companion 2 */
00149                 REAL8 r,      /**< distance of source */
00150                 int O         /**< twice post-Newtonian order */
00151                 )
00152 {
00153         static const char *func = "XLALSimInspiralPNMode33";
00154         REAL8 fac = 3.0*sqrt(6.0*LAL_PI/7.0)*LAL_G_SI*pow(LAL_C_SI, -2.0);
00155         REAL8 m = m1 + m2;
00156         REAL8 dm = m1 - m2;
00157         REAL8 mu = m1*m2/m;
00158         REAL8 nu = mu/m;
00159         COMPLEX16 ans;
00160         REAL8 re = 0.0;
00161         REAL8 im = 0.0;
00162         switch (O) {
00163                 default: /* unsupported pN order */
00164                         XLALPrintError("XLAL Error - %s: PN order %d%s not supported\n", func, O/2, O%2?".5":"" );
00165                         XLAL_ERROR_VAL(func, XLAL_EINVAL, czero);
00166                 case -1: /* use highest available pN order */
00167                 case 5:
00168                         re += ((123.0/110.0) - (1838.0/165.0)*nu - (887.0/330.0)*pow(nu, 2.0))*pow(x, 2.0);
00169                 case 4:
00170                         re += 3.0*LAL_PI*pow(x, 1.5);
00171                         im += (-(21.0/5.0) + 6.0*log(3.0/2.0) + 9.0*logx)*pow(x, 1.5);
00172                 case 3:
00173                         re -= (4.0 - 2.0*nu)*x;
00174                 case 2:
00175                 case 1:
00176                         re += 1.0;
00177                 case 0:
00178                         re += 0.0;
00179         }
00180         ans = cmul(cpolar(1.0, -3.0*phi), crect(re, im));
00181         ans = cmuli(ans, (fac*nu*dm/r)*pow(x, 1.5));
00182         return ans;
00183 }
00184 
00185 
00186 /**
00187  * Computes h(3,2) mode of spherical harmonic decomposition of
00188  * the post-Newtonian inspiral waveform.
00189  *
00190  * Implements Equation (83) of:
00191  * Lawrence E. Kidder, "Using Full Information When Computing Modes of
00192  * Post-Newtonian Waveforms From Inspiralling Compact Binaries in Circular
00193  * Orbit", Physical Review D 77, 044016 (2008), arXiv:0710.0614v1 [gr-qc].
00194  */
00195 COMPLEX16 XLALSimInspiralPNMode32(
00196                 REAL8 x,      /**< post-Newtonian parameter */
00197                 REAL8 phi,    /**< orbital phase */
00198                 REAL8 logx,   /**< log(x/x0) tail gauge parameter */
00199                 REAL8 m1,     /**< mass of companion 1 */
00200                 REAL8 m2,     /**< mass of companion 2 */
00201                 REAL8 r,      /**< distance of source */
00202                 int O         /**< twice post-Newtonian order */
00203                 )
00204 {
00205         static const char *func = "XLALSimInspiralPNMode32";
00206         REAL8 fac = -(8.0/3.0)*sqrt(LAL_PI/7.0)*LAL_G_SI*pow(LAL_C_SI, -2.0);
00207         REAL8 m = m1 + m2;
00208         REAL8 mu = m1*m2/m;
00209         REAL8 nu = mu/m;
00210         COMPLEX16 ans;
00211         REAL8 re = 0.0;
00212         REAL8 im = 0.0;
00213         switch (O) {
00214                 default: /* unsupported pN order */
00215                         XLALPrintError("XLAL Error - %s: PN order %d%s not supported\n", func, O/2, O%2?".5":"" );
00216                         XLAL_ERROR_VAL(func, XLAL_EINVAL, czero);
00217                 case -1: /* use highest available pN order */
00218                 case 5:
00219                         re += 2.0*LAL_PI*(1.0 - 3.0*nu)*pow(x, 1.5);
00220                         im += (-3.0 + (66.0/5.0)*nu + 6.0*(1.0 - 3.0*nu)*logx)*pow(x, 1.5);
00221                 case 4:
00222                         re -= ((193.0/90.0) - (145.0/18.0)*nu + (73.0/18.0)*pow(nu, 2.0))*x;
00223                 case 3:
00224                 case 2:
00225                         re += 1.0 - 3.0*nu;
00226                 case 1:
00227                 case 0:
00228                         re += 0.0;
00229         }
00230         ans = cmul(cpolar(1.0, -2.0*phi), crect(re, im));
00231         ans = cmulr(ans, (fac*nu*m/r)*pow(x, 2.0));
00232         return ans;
00233 }
00234 
00235 /**
00236  * Computes h(3,1) mode of spherical harmonic decomposition of
00237  * the post-Newtonian inspiral waveform.
00238  *
00239  * Implements Equation (84) of:
00240  * Lawrence E. Kidder, "Using Full Information When Computing Modes of
00241  * Post-Newtonian Waveforms From Inspiralling Compact Binaries in Circular
00242  * Orbit", Physical Review D 77, 044016 (2008), arXiv:0710.0614v1 [gr-qc].
00243  */
00244 COMPLEX16 XLALSimInspiralPNMode31(
00245                 REAL8 x,      /**< post-Newtonian parameter */
00246                 REAL8 phi,    /**< orbital phase */
00247                 REAL8 logx,   /**< log(x/x0) tail gauge parameter */
00248                 REAL8 m1,     /**< mass of companion 1 */
00249                 REAL8 m2,     /**< mass of companion 2 */
00250                 REAL8 r,      /**< distance of source */
00251                 int O         /**< twice post-Newtonian order */
00252                 )
00253 {
00254         static const char *func = "XLALSimInspiralPNMode31";
00255         REAL8 fac = -(1.0/3.0)*sqrt(2.0*LAL_PI/35.0)*LAL_G_SI*pow(LAL_C_SI, -2.0);
00256         REAL8 m = m1 + m2;
00257         REAL8 dm = m1 - m2;
00258         REAL8 mu = m1*m2/m;
00259         REAL8 nu = mu/m;
00260         COMPLEX16 ans;
00261         REAL8 re = 0.0;
00262         REAL8 im = 0.0;
00263         switch (O) {
00264                 default: /* unsupported pN order */
00265                         XLALPrintError("XLAL Error - %s: PN order %d%s not supported\n", func, O/2, O%2?".5":"" );
00266                         XLAL_ERROR_VAL(func, XLAL_EINVAL, czero);
00267                 case -1: /* use highest available pN order */
00268                 case 5:
00269                         re += ((607.0/198.0) - (136.0/99.0)*nu - (247.0/198.0)*pow(nu, 2.0))*pow(x, 2.0);
00270                 case 4:
00271                         re += LAL_PI*pow(x, 1.5);
00272                         im += (-(7.0/5.0) - 2.0*log(2.0) + 3.0*logx)*pow(x, 1.5);
00273                 case 3:
00274                         re -= ((8.0/3.0) + (2.0/3.0)*nu)*x;
00275                 case 2:
00276                 case 1:
00277                         re += 1.0;
00278                 case 0:
00279                         re += 0.0;
00280         }
00281         ans = cmul(cpolar(1.0, -phi), crect(re, im));
00282         ans = cmuli(ans, (fac*nu*dm/r)*pow(x, 1.5));
00283         return ans;
00284 }

Generated on Thu Aug 21 03:12:47 2008 for LAL by  doxygen 1.5.2