Loading [MathJax]/extensions/TeX/AMSsymbols.js
LALInference 4.1.9.1-5e288d3
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Header LALInferenceLikelihood.h

Detailed Description

Header file for likelihood functions used by LALInference codes.

LALInferenceLikelihood contains all the necessary routines to compute the likelihood from a template (computed with LALInferenceTemplate) and the data (initialised with LALInferenceReadData).

Likelihood functions follow the basic naming convention: LALInference<type_of>LogLikelihood()

Takes as input:

Outputs as a REAL8 the natural logarithm value of the likelihood, as defined by:

\[ Likelihood(\vec{x}|\vec{\lambda},M)=\exp(-\tfrac{1}{2}<\vec{x}-\vec{h_M}(\vec{\lambda})|\vec{x}-\vec{h_M}(\vec{\lambda})>) \]

where: \(<x|y>=4Re\left ( \int \frac{\tilde{x}\,\tilde{y}^*}{S_f}\, df \right )\)

Note that the likelihood is reported unnormalised.

Prototypes

REAL8 LALInferenceUndecomposedFreqDomainLogLikelihood (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 (log-) likelihood function. More...
 
REAL8 LALInferenceZeroLogLikelihood (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 For testing purposes (for instance sampling the prior), likelihood that returns 0.0 = log(1) every time. More...
 
REAL8 LALInferenceComputeFrequencyDomainOverlap (LALInferenceIFOData *data, COMPLEX16Vector *freqData1, COMPLEX16Vector *freqData2)
 Computes the <x|y> overlap in the Fourier domain. More...
 
COMPLEX16 LALInferenceComputeFrequencyDomainComplexOverlap (LALInferenceIFOData *dataPtr, COMPLEX16Vector *freqData1, COMPLEX16Vector *freqData2)
 Computes the complex <x|y> overlap. More...
 
REAL8 LALInferenceNullLogLikelihood (LALInferenceIFOData *data)
 Identical to LALInferenceFreqDomainNullLogLikelihood, but returns the likelihood of a null template. More...
 
REAL8 LALInferenceFreqDomainStudentTLogLikelihood (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 Student-t (log-) likelihood function as described in Roever/Meyer/Christensen (2011): "Modelling coloured residual noise in gravitational-wave signal processing. More...
 
REAL8 LALInferenceCorrelatedAnalyticLogLikelihood (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 An analytic likeilhood that is a correlated Gaussian in 15 dimensions. More...
 
REAL8 LALInferenceBimodalCorrelatedAnalyticLogLikelihood (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 An analytic likeilhood that is two correlated Gaussians in 15 dimensions. More...
 
REAL8 LALInferenceRosenbrockLogLikelihood (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 15-D Rosenbrock log(L) function (see Eq (3) of http://en.wikipedia.org/wiki/Rosenbrock_function . More...
 
REAL8 LALInferenceMarginalisedPhaseLogLikelihood (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 
REAL8 LALInferenceMarginalisedTimePhaseLogLikelihood (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 
double LALInferenceMarginalDistanceLogLikelihood (double dist_min, double dist_max, double OptimalSNR, double d_inner_h, int cosmology, int margphi)
 Compute delta-log-likelihood for given distance min, max and OptimalSNR and d_inner_h when evaluated at 1Mpc cosmology: 0 = Euclidean distance prior , 1 = uniform in comoving volume margphi: 0 = use gaussian likelihood, 1 = phase-marginalised bessel likelihood. More...
 
REAL8 LALInferenceMarginalisedTimeLogLikelihood (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 Returns the log-likelihood marginalised over the time dimension from the prior min to the prior max. More...
 
void LALInferenceInitLikelihood (LALInferenceRunState *runState)
 Initialisation function which reads runState->commaneLine and sets up the likelihood function accordingly. More...
 
LALInferenceVariables LALInferenceGetInstrinsicParams (LALInferenceVariables *currentParams)
 Get the intrinsic parameters from currentParams. More...
 
REAL8 LALInferenceFastSineGaussianLogLikelihood (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 fast SineGaussian likelihood for LIB More...
 
void LALInferenceNetworkSNR (LALInferenceVariables *currentParams, LALInferenceIFOData *data, LALInferenceModel *model)
 Calculate the SNR across the network. More...
 

Function Documentation

◆ LALInferenceUndecomposedFreqDomainLogLikelihood()

REAL8 LALInferenceUndecomposedFreqDomainLogLikelihood ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

(log-) likelihood function.

Returns the non-normalised logarithmic likelihood.

Required (‘currentParams’) parameters are:

  • "rightascension" (REAL8, radian, 0 <= RA <= 2pi)
  • "declination" (REAL8, radian, -pi/2 <= dec <=pi/2)
  • "polarisation" (REAL8, radian, 0 <= psi <= ?)
  • "distance" (REAL8, Mpc, >0)
  • "time" (REAL8, GPS sec.)

Definition at line 313 of file LALInferenceLikelihood.c.

◆ LALInferenceZeroLogLikelihood()

REAL8 LALInferenceZeroLogLikelihood ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

For testing purposes (for instance sampling the prior), likelihood that returns 0.0 = log(1) every time.

Activated with the –zeroLogLike command flag.

◆ LALInferenceComputeFrequencyDomainOverlap()

REAL8 LALInferenceComputeFrequencyDomainOverlap ( LALInferenceIFOData data,
COMPLEX16Vector freqData1,
COMPLEX16Vector freqData2 
)

Computes the <x|y> overlap in the Fourier domain.

Definition at line 1490 of file LALInferenceLikelihood.c.

◆ LALInferenceComputeFrequencyDomainComplexOverlap()

COMPLEX16 LALInferenceComputeFrequencyDomainComplexOverlap ( LALInferenceIFOData dataPtr,
COMPLEX16Vector freqData1,
COMPLEX16Vector freqData2 
)

Computes the complex <x|y> overlap.

Definition at line 1517 of file LALInferenceLikelihood.c.

◆ LALInferenceNullLogLikelihood()

REAL8 LALInferenceNullLogLikelihood ( LALInferenceIFOData data)

Identical to LALInferenceFreqDomainNullLogLikelihood, but returns the likelihood of a null template.

Used for normalising.

Definition at line 1543 of file LALInferenceLikelihood.c.

◆ LALInferenceFreqDomainStudentTLogLikelihood()

REAL8 LALInferenceFreqDomainStudentTLogLikelihood ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

Student-t (log-) likelihood function as described in Roever/Meyer/Christensen (2011): "Modelling coloured residual noise in gravitational-wave signal processing.

" Classical and Quantum Gravity, 28(1):015010. http://dx.doi.org/10.1088/0264-9381/28/1/015010 http://arxiv.org/abs/0804.3853 Returns the non-normalised logarithmic likelihood. Required (&lsquo;currentParams&rsquo;) parameters are: - "rightascension" (REAL8, radian, 0 <= RA <= 2pi) - "declination" (REAL8, radian, -pi/2 <= dec <=pi/2) - "polarisation" (REAL8, radian, 0 <= psi <= ?) - "distance" (REAL8, Mpc, > 0) - "time" (REAL8, GPS sec.) This function is essentially the same as the "UndecomposedFreqDomainLogLikelihood()" function. The additional parameter to be supplied is the (REAL8) degrees-of-freedom parameter (nu) for each Ifo. The additional "df" argument gives the corresponding d.f. parameter for each element of the "*data" list. The names of "df" must match the "->name" slot of the elements of "data".

(TODO: allow for d.f. parameter to vary with frequency, i.e., to be a set of vectors corresponding to frequencies)

Definition at line 1480 of file LALInferenceLikelihood.c.

◆ LALInferenceCorrelatedAnalyticLogLikelihood()

REAL8 LALInferenceCorrelatedAnalyticLogLikelihood ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

An analytic likeilhood that is a correlated Gaussian in 15 dimensions.

Definition at line 203 of file LALInferenceAnalyticLikelihood.c.

◆ LALInferenceBimodalCorrelatedAnalyticLogLikelihood()

REAL8 LALInferenceBimodalCorrelatedAnalyticLogLikelihood ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

An analytic likeilhood that is two correlated Gaussians in 15 dimensions.

Definition at line 268 of file LALInferenceAnalyticLikelihood.c.

◆ LALInferenceRosenbrockLogLikelihood()

REAL8 LALInferenceRosenbrockLogLikelihood ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

15-D Rosenbrock log(L) function (see Eq (3) of http://en.wikipedia.org/wiki/Rosenbrock_function .

Definition at line 349 of file LALInferenceAnalyticLikelihood.c.

◆ LALInferenceMarginalisedPhaseLogLikelihood()

REAL8 LALInferenceMarginalisedPhaseLogLikelihood ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

Definition at line 1561 of file LALInferenceLikelihood.c.

◆ LALInferenceMarginalisedTimePhaseLogLikelihood()

REAL8 LALInferenceMarginalisedTimePhaseLogLikelihood ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

Definition at line 1643 of file LALInferenceLikelihood.c.

◆ LALInferenceMarginalDistanceLogLikelihood()

double LALInferenceMarginalDistanceLogLikelihood ( double  dist_min,
double  dist_max,
double  OptimalSNR,
double  d_inner_h,
int  cosmology,
int  margphi 
)

Compute delta-log-likelihood for given distance min, max and OptimalSNR and d_inner_h when evaluated at 1Mpc cosmology: 0 = Euclidean distance prior , 1 = uniform in comoving volume margphi: 0 = use gaussian likelihood, 1 = phase-marginalised bessel likelihood.

Definition at line 1408 of file LALInferenceLikelihood.c.

◆ LALInferenceMarginalisedTimeLogLikelihood()

REAL8 LALInferenceMarginalisedTimeLogLikelihood ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

Returns the log-likelihood marginalised over the time dimension from the prior min to the prior max.

See https://dcc.ligo.org/LIGO-T1400460 for the details.

Definition at line 1633 of file LALInferenceLikelihood.c.

◆ LALInferenceInitLikelihood()

void LALInferenceInitLikelihood ( LALInferenceRunState runState)

Initialisation function which reads runState->commaneLine and sets up the likelihood function accordingly.

Can choose between Gaussian, Student-t, marginalised phase likelihoods

Definition at line 102 of file LALInferenceLikelihood.c.

◆ LALInferenceGetInstrinsicParams()

LALInferenceVariables LALInferenceGetInstrinsicParams ( LALInferenceVariables currentParams)

Get the intrinsic parameters from currentParams.

Definition at line 236 of file LALInferenceLikelihood.c.

◆ LALInferenceFastSineGaussianLogLikelihood()

REAL8 LALInferenceFastSineGaussianLogLikelihood ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

fast SineGaussian likelihood for LIB

Definition at line 1653 of file LALInferenceLikelihood.c.

◆ LALInferenceNetworkSNR()

void LALInferenceNetworkSNR ( LALInferenceVariables currentParams,
LALInferenceIFOData data,
LALInferenceModel model 
)

Calculate the SNR across the network.

Definition at line 1866 of file LALInferenceLikelihood.c.