Loading [MathJax]/extensions/TeX/AMSsymbols.js
LALPulsar 7.1.1.1-b246709
All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
IHS.h
Go to the documentation of this file.
1/*
2* Copyright (C) 2010, 2011, 2015 Evan Goetz
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#ifndef __IHS_H__
21#define __IHS_H__
22
23#include "TwoSpectTypes.h"
24
25ihsMaximaStruct *createihsMaxima( const UINT4 fbins, const UINT4 rows );
27INT4 runIHS( ihsMaximaStruct *output, const ffdataStruct *input, const ihsfarStruct *ihsfarinput, const UserInput_t *params, UINT4 rows, const REAL4VectorAligned *aveNoise, const REAL4VectorAligned *FbinMean );
28
29ihsVals *createihsVals( void );
30void destroyihsVals( ihsVals *ihsvals );
31INT4 incHarmSum( ihsVals *output, const REAL4VectorAligned *input, const UINT4 ihsfactor );
33INT4 incHarmSumVectorWeighted( REAL4VectorAligned *output, const REAL4VectorAligned *input, const REAL4VectorAligned *aveNoise, const UINT4 ihsfactor );
34
36void destroyihsfarStruct( ihsfarStruct *ihsfarstruct );
37INT4 genIhsFar( ihsfarStruct *output, const UserInput_t *params, UINT4 rows, const REAL4VectorAligned *aveNoise, const gsl_rng *rng );
38
39INT4 sumIHSarrayFAR( ihsfarStruct *outputfar, REAL4VectorAlignedArray *ihsvectorarray, const UINT4 rows, const REAL4VectorAligned *FbinMean, const UserInput_t *params, const gsl_rng *rng );
40INT4 sumIHSarray( ihsMaximaStruct *output, const ihsfarStruct *inputfar, REAL4VectorAlignedArray *ihsvectorarray, const UINT4 rows, const REAL4VectorAligned *FbinMean, const UserInput_t *params );
41
42INT4 findIHScandidates( candidateVector **candlist, const ihsfarStruct *ihsfarstruct, const UserInput_t *params, const ffdataStruct *ffdata, const ihsMaximaStruct *ihsmaxima, const REAL4VectorAligned *fbinavgs, const REAL4VectorSequence *trackedlines );
43
44REAL4 ihsFOM( const INT4Vector *locs, const INT4 fomnorm );
45
46REAL8 ihs2h0( const REAL8 ihsval, const UserInput_t *params );
47
48#endif
void destroyihsfarStruct(ihsfarStruct *ihsfarstruct)
Destroy ihsfarStruct struct.
Definition: IHS.c:316
void destroyihsMaxima(ihsMaximaStruct *data)
Destroy vectors and the IHS maxima struct.
Definition: IHS.c:65
ihsVals * createihsVals(void)
Allocate memory for ihsVals struct.
Definition: IHS.c:168
REAL8 ihs2h0(const REAL8 ihsval, const UserInput_t *params)
Convert the IHS statistic to an estimated h0, based on injections.
Definition: IHS.c:1083
INT4 runIHS(ihsMaximaStruct *output, const ffdataStruct *input, const ihsfarStruct *ihsfarinput, const UserInput_t *params, UINT4 rows, const REAL4VectorAligned *aveNoise, const REAL4VectorAligned *FbinMean)
Run the IHS algorithm.
Definition: IHS.c:89
INT4 incHarmSumVector(REAL4VectorAligned *output, const REAL4VectorAligned *input, const UINT4 ihsfactor)
Compute the IHS vector – does not compute the maximum value.
Definition: IHS.c:228
void destroyihsVals(ihsVals *ihsvals)
Destroy ihsVals struct.
Definition: IHS.c:180
INT4 genIhsFar(ihsfarStruct *output, const UserInput_t *params, UINT4 rows, const REAL4VectorAligned *aveNoise, const gsl_rng *rng)
Compute the IHS FAR for a sum of a number of rows.
Definition: IHS.c:340
INT4 incHarmSum(ihsVals *output, const REAL4VectorAligned *input, const UINT4 ihsfactor)
Compute the IHS sum maximum.
Definition: IHS.c:195
ihsfarStruct * createihsfarStruct(const UINT4 rows, const UserInput_t *params)
Allocate memory for ihsfarStruct struct.
Definition: IHS.c:289
INT4 incHarmSumVectorWeighted(REAL4VectorAligned *output, const REAL4VectorAligned *input, const REAL4VectorAligned *aveNoise, const UINT4 ihsfactor)
Compute the noise weighted IHS vector – does not compute the maximum value.
Definition: IHS.c:259
REAL4 ihsFOM(const INT4Vector *locs, const INT4 fomnorm)
Calculate the IHS FOM for a number of rows.
Definition: IHS.c:782
INT4 sumIHSarray(ihsMaximaStruct *output, const ihsfarStruct *inputfar, REAL4VectorAlignedArray *ihsvectorarray, const UINT4 rows, const REAL4VectorAligned *FbinMean, const UserInput_t *params)
Compute the IHS sums for a number of rows.
Definition: IHS.c:639
INT4 sumIHSarrayFAR(ihsfarStruct *outputfar, REAL4VectorAlignedArray *ihsvectorarray, const UINT4 rows, const REAL4VectorAligned *FbinMean, const UserInput_t *params, const gsl_rng *rng)
Compute the IHS sums for a number of rows used for the FAR calculation.
Definition: IHS.c:469
INT4 findIHScandidates(candidateVector **candlist, const ihsfarStruct *ihsfarstruct, const UserInput_t *params, const ffdataStruct *ffdata, const ihsMaximaStruct *ihsmaxima, const REAL4VectorAligned *fbinavgs, const REAL4VectorSequence *trackedlines)
Find IHS candidates above thresholds.
Definition: IHS.c:809
ihsMaximaStruct * createihsMaxima(const UINT4 fbins, const UINT4 rows)
Create vectors for IHS maxima struct.
Definition: IHS.c:37
double REAL8
uint32_t UINT4
int32_t INT4
float REAL4
float data[BLOCKSIZE]
Definition: hwinject.c:360