Loading [MathJax]/extensions/TeX/AMSsymbols.js
LALPulsar
7.1.1.1-b246709
LALSuite
LAL
LALFrame
LALMetaIO
LALSimulation
LALBurst
LALInspiral
LALInference
LALPulsar
LALApps
•
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Modules
Pages
SFTbin.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2007 Badri Krishnan, Alicia Sintes Olives
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
/*-----------------------------------------------------------------------
21
*
22
* File Name: SFTbin.h
23
*
24
* Authors: Sintes, A.M., Krishnan, B. & inspired from Siemens, X.
25
*
26
*
27
* History: Created by Sintes May 21, 2003
28
* Modified...
29
*
30
*-----------------------------------------------------------------------
31
*/
32
33
/**
34
* \author A.M. Sintes
35
*
36
* ### Header SFTbin.h ###
37
*
38
* Routines for reading SFT binary files
39
*
40
* ### Synopsis ###
41
*
42
* \code
43
* #include <lal/SFTbin.h>
44
* \endcode
45
*/
46
47
/*
48
* 4. Protection against double inclusion (include-loop protection)
49
* Note the naming convention!
50
*/
51
52
#ifndef _SFTBIN_H
53
#define _SFTBIN_H
54
55
/*
56
* 5. Includes. This header may include others; if so, they go immediately
57
* after include-loop protection. Includes should appear in the following
58
* order:
59
* a. Standard library includes
60
* b. LDAS includes
61
* c. LAL includes
62
*/
63
64
#include <stdlib.h>
65
#include <math.h>
66
#include <stdio.h>
67
#include <stdlib.h>
68
#include <string.h>
69
#include <lal/LALStdlib.h>
70
#include <lal/LALConstants.h>
71
#include <lal/AVFactories.h>
72
#include <lal/SeqFactories.h>
73
#include <lal/SFTfileIO.h>
74
#include <lal/Random.h>
75
#include <lal/PulsarDataTypes.h>
76
#include <lal/UserInput.h>
77
#include <lal/LUT.h>
78
#include <lal/RngMedBias.h>
79
80
#include <gsl/gsl_statistics.h>
81
#include <gsl/gsl_rng.h>
82
#include <gsl/gsl_randist.h>
83
#include <gsl/gsl_sort.h>
84
/*
85
* Protection against C++ name mangling
86
*/
87
88
#ifdef __cplusplus
89
extern
"C"
{
90
#endif
91
92
/*
93
* 7. Error codes and messages. This must be auto-extracted for
94
* inclusion in the documentation.
95
*/
96
97
/**\name Error Codes */
/** @{ */
98
99
#define SFTBINH_ENULL 1
100
#define SFTBINH_EFILE 2
101
#define SFTBINH_EHEADER 3
102
#define SFTBINH_EENDIAN 4
103
#define SFTBINH_EVAL 5
104
#define SFTBINH_ESEEK 9
105
#define SFTBINH_EREAD 10
106
#define SFTBINH_EWRITE 11
107
108
#define SFTBINH_MSGENULL "Null pointer"
109
#define SFTBINH_MSGEFILE "Could not open file"
110
#define SFTBINH_MSGEHEADER "Incorrect header in file"
111
#define SFTBINH_MSGEENDIAN "Incorrect endian type"
112
#define SFTBINH_MSGEVAL "Invalid value"
113
#define SFTBINH_MSGESEEK "fseek failed"
114
#define SFTBINH_MSGEREAD "fread failed"
115
#define SFTBINH_MSGEWRITE "fwrite failed"
116
117
118
/** @} */
119
120
121
/* ******************************************************
122
* 8. Macros. But, note that macros are deprecated.
123
* They could be moved to the modules where are needed
124
*/
125
126
/* *******************************************************
127
* 9. Constant Declarations. (discouraged)
128
*/
129
130
131
132
/* **************************************************************
133
* 10. Structure, enum, union, etc., typdefs.
134
*/
135
136
137
typedef
struct
tagCOMPLEX8SFTData1 {
/* simple case */
138
LIGOTimeGPS
epoch
;
/* epoch of first series sample */
139
REAL8
timeBase
;
140
INT4
fminBinIndex
;
141
INT4
length
;
/* number of elements in data */
142
COMPLEX8
*
data
;
/* pointer to the data */
143
}
COMPLEX8SFTData1
;
144
145
typedef
struct
tagCOMPLEX8SFTvector1 {
146
UINT4
length
;
/* number of elements */
147
COMPLEX8SFTData1
*
sft
;
/* pointer to the data */
148
}
COMPLEX8SFTvector1
;
149
150
typedef
struct
tagCOMPLEX16SFTData1 {
/* simple case */
151
LIGOTimeGPS
epoch
;
/* epoch of first series sample */
152
REAL8
timeBase
;
153
INT4
fminBinIndex
;
154
INT4
length
;
/* number of elements in data */
155
COMPLEX16
*
data
;
/* pointer to the data */
156
}
COMPLEX16SFTData1
;
157
158
typedef
struct
tagREAL8Periodogram1 {
/* simple case */
159
LIGOTimeGPS
epoch
;
/* epoch of first series sample */
160
REAL8
timeBase
;
161
INT4
fminBinIndex
;
162
INT4
length
;
/* number of elements in data */
163
REAL8
*
data
;
/* pointer to the data */
164
}
REAL8Periodogram1
;
165
166
167
168
/*
169
* 11. Extern Global variables. (discouraged)
170
*/
171
172
173
/*
174
* 12. Functions Declarations (i.e., prototypes).
175
*/
176
177
178
void
COMPLEX8SFT2Periodogram1
(
LALStatus
*
status
,
179
REAL8Periodogram1
*peri,
180
COMPLEX8SFTData1
*sft
181
);
182
183
void
SFT2Periodogram
(
LALStatus
*
status
,
184
REAL8Periodogram1
*peri,
185
SFTtype
*sft
186
);
187
188
189
#ifdef __cplusplus
190
}
/* Close C++ protection */
191
#endif
192
193
#endif
/* Close double-include protection _SFTBIN_H */
SFT2Periodogram
void SFT2Periodogram(LALStatus *status, REAL8Periodogram1 *peri, SFTtype *sft)
Definition:
SFTbin.c:133
COMPLEX8SFT2Periodogram1
void COMPLEX8SFT2Periodogram1(LALStatus *status, REAL8Periodogram1 *peri, COMPLEX8SFTData1 *sft)
OBSOLETE – Use LAL functions from SFTfileIO.c instead.
Definition:
SFTbin.c:69
COMPLEX16
double complex COMPLEX16
REAL8
double REAL8
UINT4
uint32_t UINT4
COMPLEX8
float complex COMPLEX8
INT4
int32_t INT4
lalpulsar.git_version.status
string status
Definition:
git_version.py:32
COMPLEX16SFTData1
Definition:
SFTbin.h:150
COMPLEX16SFTData1::epoch
LIGOTimeGPS epoch
Definition:
SFTbin.h:151
COMPLEX16SFTData1::length
INT4 length
Definition:
SFTbin.h:154
COMPLEX16SFTData1::data
COMPLEX16 * data
Definition:
SFTbin.h:155
COMPLEX16SFTData1::timeBase
REAL8 timeBase
Definition:
SFTbin.h:152
COMPLEX16SFTData1::fminBinIndex
INT4 fminBinIndex
Definition:
SFTbin.h:153
COMPLEX8FrequencySeries
COMPLEX8SFTData1
Definition:
SFTbin.h:137
COMPLEX8SFTData1::epoch
LIGOTimeGPS epoch
Definition:
SFTbin.h:138
COMPLEX8SFTData1::timeBase
REAL8 timeBase
Definition:
SFTbin.h:139
COMPLEX8SFTData1::data
COMPLEX8 * data
Definition:
SFTbin.h:142
COMPLEX8SFTData1::fminBinIndex
INT4 fminBinIndex
Definition:
SFTbin.h:140
COMPLEX8SFTData1::length
INT4 length
Definition:
SFTbin.h:141
COMPLEX8SFTvector1
Definition:
SFTbin.h:145
COMPLEX8SFTvector1::sft
COMPLEX8SFTData1 * sft
Definition:
SFTbin.h:147
COMPLEX8SFTvector1::length
UINT4 length
Definition:
SFTbin.h:146
LALStatus
LIGOTimeGPS
REAL8Periodogram1
Definition:
SFTbin.h:158
REAL8Periodogram1::timeBase
REAL8 timeBase
Definition:
SFTbin.h:160
REAL8Periodogram1::epoch
LIGOTimeGPS epoch
Definition:
SFTbin.h:159
REAL8Periodogram1::fminBinIndex
INT4 fminBinIndex
Definition:
SFTbin.h:161
REAL8Periodogram1::data
REAL8 * data
Definition:
SFTbin.h:163
REAL8Periodogram1::length
INT4 length
Definition:
SFTbin.h:162
bin
Hough
SFTbin.h
Generated on Fri Jul 11 2025 05:18:03 for LALPulsar by
1.9.4