Linuxpops
3.01.04
Spectral Anaysis Package for Single Dish Data
Main Page
Related Pages
Classes
Files
File List
File Members
All
Classes
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Pages
structure.h
Go to the documentation of this file.
1
/* class data structures */
2
3
#define REC_LEN 512
4
#define ENT_EXT 384
5
#define ENT_LEN (32*4)
6
#define ENT_REC (REC_LEN/ENT_LEN)
7
#define EXT_LEN (ENT_EXT*ENT_LEN)
8
#define EIII_FILE "1B "
9
#define EEEI_FILE "1A "
10
11
struct
file_index
12
{
13
char
code
[4];
/* file type */
14
int
next_rec
,
/* next free (128 byte) record */
15
num_ent
,
/* entries per extension */
16
num_ext
,
/* active extensions */
17
next_ent
,
/* next free entry */
18
ext_addr
[251];
/* record addrs of extensions */
19
};
20
21
#define KIND_SPEC 0
/* Spectroscopy */
22
#define KIND_CONT 1
/* Continuum drift */
23
#define KIND_SKY 2
/* Skydip data */
24
#define KIND_ONOFF 3
/* Continuum on/off */
25
26
#define UNKNOWN 1
/* coord systems */
27
#define EQUAT 2
28
#define GALAC 3
29
#define HORIZ 4
30
#define PLANET 5
31
#define GEOCEN 6
32
33
struct
index_ent
34
{
35
int
addr
,
/* record address of scan */
36
obs
,
/* obs number */
37
version
;
/* and version */
38
char
source
[12],
/* source, */
39
line
[12],
/* line, */
40
telescope
[12];
/* and telescope names */
41
int
date_obs
,
/* observ and reduction dates */
42
date_red
;
/* (days from 27 August 2024) */
43
float
offsets
[2];
/* position offsets */
44
int
offset_type
,
/* 1 Un 2 Eq 3 Ga 4 Ho 5 Pl 6 Ea */
45
obs_type
,
/* 0: spectrum; 1: continuum */
46
quality
,
47
scan
,
/* scan number */
48
future
[12];
49
};
50
51
#define SPECTRUM "2 "
52
#define SCAN_LEN 54
53
struct
scan_ent
54
{
55
char
code
[4];
/* scan ID */
56
int
size_rec
,
/* scan size in records */
57
size
,
/* scan size in (4 byte) words */
58
unused_1
,
59
data_addr
,
/* data offset in words */
60
data_size
,
/* data size in words */
61
unused_2
,
62
num_sec
,
/* number of header sects */
63
entry
,
/* entry number in index */
64
sect_info
[45];
/* section codes[num_sec], */
65
/* section lengths[num_sec], */
66
/* section addrs[num_sec] */
67
};
68
69
struct
pointer_descr
/* length of sects. if 0, sect not present. */
70
{
71
int
general
,
72
position
,
73
spectro
,
74
fswitch
,
75
drift
,
76
beam
,
77
calibration
,
78
skydip
,
79
gauss
,
80
hfs
,
81
shell
,
82
continuum
,
83
history
,
84
plot
,
85
base
,
86
xcoord
;
87
};
88
89
#define GENERAL_SECT -2
90
#define GENERAL_LEN 9
91
struct
general_descr
/* always present */
92
{
93
double
ut_time
,
/* (seconds) */
94
lst_time
;
95
float
azimuth
,
/* (radians) */
96
elevation
,
97
tau
,
/* opacity */
98
tsys
,
/* system temperature (K) */
99
integration
;
/* integration time (minutes) */
100
};
101
102
#define P_NONE 0
/* Projections */
103
#define P_GNOMONIC 1
/* Radial Tangent plane */
104
#define P_ORTHO 2
/* Dixon Tangent plane */
105
#define P_AZIMUTHAL 3
/* Schmidt Tangent plane */
106
#define P_STEREO 4
/* Stereographic */
107
#define P_LAMBERT 5
/* Lambert equal area */
108
#define P_AITOFF 6
/* Aitoff equal area */
109
#define P_RADIO 7
/* Classic Single dish radio mapping */
110
111
#define POSITION_SECT -3
112
#define POSITION_LEN 11
113
struct
position_descr
114
{
115
char
source
[12];
/* source name */
116
float
epoch
;
/* coordinate epoch */
117
double
lambda
,
/* coordinates */
118
beta
;
119
float
lambda_off
,
/* coordinate offsets */
120
beta_off
;
121
int
projection
;
/* projection system */
122
};
123
124
#define VUNK 0
/* velocity references: unknown (planetary...) */
125
#define VLSR 1
126
#define VHEL 2
/* Heliocentric */
127
#define VOBS 3
/* Observatory (telescope) */
128
#define VEAR 4
/* Earth-Moon barycenter */
129
#define VAUT -1
/* from data */
130
131
#define SPECTRO_SECT -4
132
#define SPECTRO_LEN 18
133
struct
spectro_descr
/* spectroscopy */
134
{
/* spectra only */
135
char
line
[12];
/* line name */
136
double
rest
;
/* rest frequency */
137
int
nchan
;
/* number of channels */
138
float
reference
,
/* reference channel */
139
fres
,
/* frequency resolution */
140
foff
,
/* frequency offset */
141
vres
,
/* velocity resolution */
142
voff
,
/* velocity at reference chan */
143
bad
;
/* blanking value */
144
double
image
;
/* image frequency */
145
int
velocity
;
/* 0 Unkn 1 LSR 2 Hel. 3 Ear. */
146
double
sky
;
/* sky frequency */
147
float
vteles
;
/* velocity of telescope rel */
148
};
149
150
#define BASE_SECT -5
151
#define MWIND 20
152
#define BASE_LEN 4+2*MWIND
153
struct
base_descr
/* baseline */
154
{
/* spectra or drifts */
155
int
degree
;
/* degree of last baseline */
156
float
sigma
,
/* sigma */
157
area
;
/* area under windows */
158
int
nwindow
;
/* number of line windows */
159
float
wind1
[
MWIND
],
/* lower limits of windows */
160
wind2
[
MWIND
];
/* upper limits of windows */
161
};
162
163
#define HISTORY_SECT -6
164
#define MSEQ 100
165
#define HISTORY_LEN 1+2*MSEQ
166
struct
history_descr
/* orig scan nums */
167
{
168
int
sequence
,
/* number of sequences */
169
start
[
MSEQ
],
/* start scan number of seq. */
170
end
[
MSEQ
];
/* end scan number of seq. */
171
};
172
173
#define PLOT_SECT -7
174
#define PLOT_LEN 4
175
struct
plot_descr
/* default plot limits */
176
{
177
float
ymin
,
/* min y value plotted */
178
ymax
,
/* max y value plotted */
179
xmin
,
/* min x value plotted */
180
xmax
;
/* max x value plotted */
181
};
182
183
#define MOD_FREQ 0
/* Frequency switch */
184
#define MOD_POS 1
/* Position switch */
185
#define MOD_FOLD 2
/* Folded frequency switch */
186
187
#define FSWITCH_SECT -8
188
#define MXPHAS 8
189
#define FSWITCH_LEN 2+6*MXPHAS
190
struct
fswitch_descr
/* freq & pos switch */
191
{
/* spectra only */
192
int
nphase
;
/* number of phases */
193
double
decalage
[
MXPHAS
];
/* frequency offsets */
194
float
duree
[
MXPHAS
],
/* time per phase */
195
poids
[
MXPHAS
];
/* weight of each phase */
196
int
mode
;
/* switch mode (freq , pos) */
197
float
lamoff
[
MXPHAS
],
/* lambda offsets */
198
betoff
[
MXPHAS
];
/* beta offsets of each phase */
199
};
200
201
#define CALIBRATION_SECT -14
202
#define CALIBRATION_LEN 21
203
struct
calibration_descr
204
{
205
float
beam_eff
,
/* beam efficiency */
206
forw_eff
,
/* forward efficiency */
207
gain_im
,
/* image/signal gain ratio */
208
h2omm
,
/* mm of water vapor */
209
pamb
,
/* ambient pressure (hpa) */
210
tamb
,
/* ambient temperature (K) */
211
tatmsig
,
/* atmosphere temp. signal band */
212
tchop
,
/* chopper temperature */
213
tcold
,
/* cold load temperature */
214
tausig
,
/* opacity signal band */
215
tauima
,
/* opacity image band */
216
tatmima
,
/* atmosphere temp. image band */
217
trec
;
/* receiver temperature */
218
int
mode
;
/* calibration mode */
219
float
factor
,
/* applied calibration factor */
220
altitude
,
/* site elevation (m) */
221
counts
[3],
/* power of atm., chopp., cold */
222
lamoff
,
/* long offset for sky measure */
223
betoff
;
/* lat offset for sky measure */
224
};
225
226
227
#define SKYDIP_SECT -16
228
#define MSKY 10
229
#define SKYDIP_LEN (10+4*MSKY)
230
struct
skydip_descr
/* skydips */
231
{
/* no associated data */
232
char
line
[12];
/* line name */
233
double
rest
,
/* rest frequency */
234
image
;
/* image frequency */
235
int
nsky
,
/* number of points on sky */
236
nchop
,
/* - - - - chopper */
237
ncold
;
/* - - - - cold load */
238
float
elevation
[
MSKY
],
/* elevations */
239
emission
[
MSKY
],
/* power on sky */
240
chopper
[
MSKY
],
/* power on chopper */
241
cold
[
MSKY
];
/* power on cold load */
242
};
243
244
#define GAUSS_SECT -9
245
#define MXGAUS 5
246
#define GAUSS_LEN (3+6*MXGAUS)
247
struct
gauss_descr
/* fit results */
248
{
/* spectra or drifts */
249
int
nline
;
/* number of components */
250
float
sigma_base
,
/* sigma on base */
251
sigma_raie
,
/* sigma on line */
252
fit
[3*
MXGAUS
],
/* fit results */
253
err
[3*
MXGAUS
];
/* errors */
254
};
255
256
#define SHELL_SECT -12
257
#define SHELL_LEN 43
258
struct
shell_descr
/* "stellar shell" profile fit result */
259
{
/* spectra only */
260
int
nline
;
/* number of components */
261
float
sigma_base
,
/* sigma on base */
262
sigma_raie
,
/* sigma on line */
263
fit
[20],
/* fit results */
264
err
[20];
/* errors */
265
};
266
267
#define HFS_SECT -13
268
#define HFS_LEN 27
269
struct
hfs_descr
/* "hyperfine struct" (nh3, hcn) fit */
270
{
/* spectra only */
271
int
nline
;
/* number of components */
272
float
sigma_base
,
/* sigma on base */
273
sigma_raie
,
/* sigma on line */
274
fit
[12],
/* fit results */
275
err
[12];
/* errors */
276
};
277
278
#define DRIFT_SECT -10
279
#define DRIFT_LEN 16
280
struct
drift_descr
/* continuum drifts */
281
{
/* drifts only */
282
double
rest
;
/* rest frequency */
283
float
width
;
/* bandwidth */
284
int
npoint
;
/* number of data points */
285
float
reference
,
/* reference point */
286
timoff
,
/* time at reference */
287
angoff
,
/* angular offset at ref. */
288
pa
,
/* position angle of drift */
289
timres
,
/* time resolution */
290
angres
,
/* angular resolution */
291
bad
;
/* blanking value */
292
int
system
;
/* type of offsets */
293
double
image
;
/* image frequency */
294
float
colla
,
/* collimation error az */
295
colle
;
/* collimation error el */
296
};
297
298
#define BEAM_SECT -11
299
#define BEAM_LEN 5
300
struct
beam_descr
/* beam switch */
301
{
/* spectra or drifts */
302
float
azimuth
,
/* observation azimuth */
303
elevation
,
/* observation elevation */
304
throw
,
/* beam spacing */
305
pa
;
/* position angle of beams */
306
int
system
;
/* system for angle */
307
};
308
309
#define CONT_SECT -15
310
#define CONT_LEN 19
311
struct
cont_descr
/* doub gauss & base fit results */
312
{
/* drifts only */
313
int
nline
;
/* number of components */
314
float
sigma_base
,
/* sigma on base */
315
sigma_raie
,
/* sigma on line */
316
fit
[8],
/* results */
317
err
[8];
/* errors */
318
};
pointer_descr::base
int base
Definition:
structure.h:71
cont_descr::err
float err[8]
Definition:
structure.h:314
index_ent::line
char line[12]
Definition:
structure.h:38
scan_ent
Definition:
structure.h:53
calibration_descr::lamoff
float lamoff
Definition:
structure.h:219
drift_descr::image
double image
Definition:
structure.h:293
general_descr::integration
float integration
Definition:
structure.h:95
pointer_descr::spectro
int spectro
Definition:
structure.h:71
spectro_descr::image
double image
Definition:
structure.h:144
spectro_descr::bad
float bad
Definition:
structure.h:138
hfs_descr
Definition:
structure.h:269
history_descr::start
int start[MSEQ]
Definition:
structure.h:168
calibration_descr::tamb
float tamb
Definition:
structure.h:205
gauss_descr::sigma_raie
float sigma_raie
Definition:
structure.h:250
drift_descr::colla
float colla
Definition:
structure.h:294
pointer_descr::history
int history
Definition:
structure.h:71
fswitch_descr::mode
int mode
Definition:
structure.h:196
pointer_descr::skydip
int skydip
Definition:
structure.h:71
index_ent::future
int future[12]
Definition:
structure.h:44
skydip_descr::emission
float emission[MSKY]
Definition:
structure.h:238
plot_descr::xmin
float xmin
Definition:
structure.h:177
position_descr::beta_off
float beta_off
Definition:
structure.h:119
file_index::next_ent
int next_ent
Definition:
structure.h:14
drift_descr::timoff
float timoff
Definition:
structure.h:285
file_index::next_rec
int next_rec
Definition:
structure.h:14
general_descr::tsys
float tsys
Definition:
structure.h:95
calibration_descr::beam_eff
float beam_eff
Definition:
structure.h:205
drift_descr::npoint
int npoint
Definition:
structure.h:284
gauss_descr::nline
int nline
Definition:
structure.h:249
calibration_descr::tatmsig
float tatmsig
Definition:
structure.h:205
spectro_descr::reference
float reference
Definition:
structure.h:138
skydip_descr::elevation
float elevation[MSKY]
Definition:
structure.h:238
index_ent::quality
int quality
Definition:
structure.h:44
scan_ent::unused_2
int unused_2
Definition:
structure.h:56
calibration_descr::h2omm
float h2omm
Definition:
structure.h:205
general_descr::elevation
float elevation
Definition:
structure.h:95
skydip_descr::nchop
int nchop
Definition:
structure.h:235
pointer_descr::position
int position
Definition:
structure.h:71
base_descr::nwindow
int nwindow
Definition:
structure.h:158
spectro_descr
Definition:
structure.h:133
MXGAUS
#define MXGAUS
Definition:
structure.h:245
pointer_descr::gauss
int gauss
Definition:
structure.h:71
file_index::code
char code[4]
Definition:
structure.h:13
drift_descr::width
float width
Definition:
structure.h:283
drift_descr::timres
float timres
Definition:
structure.h:285
position_descr::lambda_off
float lambda_off
Definition:
structure.h:119
plot_descr
Definition:
structure.h:175
skydip_descr::image
double image
Definition:
structure.h:233
file_index::num_ext
int num_ext
Definition:
structure.h:14
index_ent::scan
int scan
Definition:
structure.h:44
index_ent::version
int version
Definition:
structure.h:35
base_descr::wind1
float wind1[MWIND]
Definition:
structure.h:159
index_ent::date_obs
int date_obs
Definition:
structure.h:41
drift_descr::angoff
float angoff
Definition:
structure.h:285
beam_descr
Definition:
structure.h:300
pointer_descr::fswitch
int fswitch
Definition:
structure.h:71
scan_ent::code
char code[4]
Definition:
structure.h:55
shell_descr::err
float err[20]
Definition:
structure.h:261
calibration_descr::factor
float factor
Definition:
structure.h:219
calibration_descr::pamb
float pamb
Definition:
structure.h:205
pointer_descr
Definition:
structure.h:69
general_descr::azimuth
float azimuth
Definition:
structure.h:95
position_descr::projection
int projection
Definition:
structure.h:121
calibration_descr::trec
float trec
Definition:
structure.h:205
drift_descr::colle
float colle
Definition:
structure.h:294
cont_descr::fit
float fit[8]
Definition:
structure.h:314
scan_ent::unused_1
int unused_1
Definition:
structure.h:56
file_index::num_ent
int num_ent
Definition:
structure.h:14
pointer_descr::calibration
int calibration
Definition:
structure.h:71
gauss_descr
Definition:
structure.h:247
scan_ent::data_size
int data_size
Definition:
structure.h:56
skydip_descr::chopper
float chopper[MSKY]
Definition:
structure.h:238
drift_descr::reference
float reference
Definition:
structure.h:285
plot_descr::ymin
float ymin
Definition:
structure.h:177
file_index::ext_addr
int ext_addr[251]
Definition:
structure.h:14
fswitch_descr::poids
float poids[MXPHAS]
Definition:
structure.h:194
MWIND
#define MWIND
Definition:
structure.h:151
base_descr::degree
int degree
Definition:
structure.h:155
calibration_descr::tausig
float tausig
Definition:
structure.h:205
fswitch_descr::betoff
float betoff[MXPHAS]
Definition:
structure.h:197
history_descr::end
int end[MSEQ]
Definition:
structure.h:168
calibration_descr::mode
int mode
Definition:
structure.h:218
spectro_descr::rest
double rest
Definition:
structure.h:136
spectro_descr::fres
float fres
Definition:
structure.h:138
spectro_descr::line
char line[12]
Definition:
structure.h:135
scan_ent::data_addr
int data_addr
Definition:
structure.h:56
scan_ent::sect_info
int sect_info[45]
Definition:
structure.h:56
base_descr::area
float area
Definition:
structure.h:156
spectro_descr::voff
float voff
Definition:
structure.h:138
index_ent::offsets
float offsets[2]
Definition:
structure.h:43
general_descr::lst_time
double lst_time
Definition:
structure.h:93
position_descr
Definition:
structure.h:113
pointer_descr::general
int general
Definition:
structure.h:71
gauss_descr::sigma_base
float sigma_base
Definition:
structure.h:250
position_descr::beta
double beta
Definition:
structure.h:117
beam_descr::pa
float pa
Definition:
structure.h:302
shell_descr::sigma_raie
float sigma_raie
Definition:
structure.h:261
skydip_descr::rest
double rest
Definition:
structure.h:233
skydip_descr::cold
float cold[MSKY]
Definition:
structure.h:238
MSKY
#define MSKY
Definition:
structure.h:228
index_ent
Definition:
structure.h:33
skydip_descr::line
char line[12]
Definition:
structure.h:232
file_index
Definition:
structure.h:11
cont_descr::sigma_base
float sigma_base
Definition:
structure.h:314
calibration_descr::tchop
float tchop
Definition:
structure.h:205
spectro_descr::velocity
int velocity
Definition:
structure.h:145
calibration_descr::counts
float counts[3]
Definition:
structure.h:219
beam_descr::system
int system
Definition:
structure.h:306
shell_descr::sigma_base
float sigma_base
Definition:
structure.h:261
scan_ent::entry
int entry
Definition:
structure.h:56
pointer_descr::beam
int beam
Definition:
structure.h:71
index_ent::obs
int obs
Definition:
structure.h:35
index_ent::offset_type
int offset_type
Definition:
structure.h:44
scan_ent::size_rec
int size_rec
Definition:
structure.h:56
fswitch_descr::lamoff
float lamoff[MXPHAS]
Definition:
structure.h:197
shell_descr::nline
int nline
Definition:
structure.h:260
drift_descr::rest
double rest
Definition:
structure.h:282
drift_descr::system
int system
Definition:
structure.h:292
hfs_descr::nline
int nline
Definition:
structure.h:271
spectro_descr::foff
float foff
Definition:
structure.h:138
drift_descr::bad
float bad
Definition:
structure.h:285
drift_descr::angres
float angres
Definition:
structure.h:285
plot_descr::xmax
float xmax
Definition:
structure.h:177
calibration_descr::betoff
float betoff
Definition:
structure.h:219
index_ent::obs_type
int obs_type
Definition:
structure.h:44
base_descr
Definition:
structure.h:153
MXPHAS
#define MXPHAS
Definition:
structure.h:188
calibration_descr::altitude
float altitude
Definition:
structure.h:219
position_descr::source
char source[12]
Definition:
structure.h:115
spectro_descr::vres
float vres
Definition:
structure.h:138
gauss_descr::fit
float fit[3 *MXGAUS]
Definition:
structure.h:250
shell_descr::fit
float fit[20]
Definition:
structure.h:261
general_descr::ut_time
double ut_time
Definition:
structure.h:93
history_descr::sequence
int sequence
Definition:
structure.h:168
plot_descr::ymax
float ymax
Definition:
structure.h:177
calibration_descr::tcold
float tcold
Definition:
structure.h:205
drift_descr::pa
float pa
Definition:
structure.h:285
fswitch_descr::nphase
int nphase
Definition:
structure.h:192
drift_descr
Definition:
structure.h:280
calibration_descr
Definition:
structure.h:203
pointer_descr::drift
int drift
Definition:
structure.h:71
base_descr::sigma
float sigma
Definition:
structure.h:156
position_descr::epoch
float epoch
Definition:
structure.h:116
scan_ent::num_sec
int num_sec
Definition:
structure.h:56
pointer_descr::hfs
int hfs
Definition:
structure.h:71
hfs_descr::sigma_base
float sigma_base
Definition:
structure.h:272
fswitch_descr::decalage
double decalage[MXPHAS]
Definition:
structure.h:193
index_ent::addr
int addr
Definition:
structure.h:35
general_descr
Definition:
structure.h:91
calibration_descr::forw_eff
float forw_eff
Definition:
structure.h:205
fswitch_descr::duree
float duree[MXPHAS]
Definition:
structure.h:194
calibration_descr::tauima
float tauima
Definition:
structure.h:205
skydip_descr
Definition:
structure.h:230
fswitch_descr
Definition:
structure.h:190
cont_descr::sigma_raie
float sigma_raie
Definition:
structure.h:314
cont_descr
Definition:
structure.h:311
beam_descr::azimuth
float azimuth
Definition:
structure.h:302
index_ent::date_red
int date_red
Definition:
structure.h:41
calibration_descr::tatmima
float tatmima
Definition:
structure.h:205
spectro_descr::nchan
int nchan
Definition:
structure.h:137
base_descr::wind2
float wind2[MWIND]
Definition:
structure.h:159
calibration_descr::gain_im
float gain_im
Definition:
structure.h:205
shell_descr
Definition:
structure.h:258
hfs_descr::fit
float fit[12]
Definition:
structure.h:272
general_descr::tau
float tau
Definition:
structure.h:95
pointer_descr::shell
int shell
Definition:
structure.h:71
hfs_descr::err
float err[12]
Definition:
structure.h:272
index_ent::telescope
char telescope[12]
Definition:
structure.h:38
history_descr
Definition:
structure.h:166
spectro_descr::sky
double sky
Definition:
structure.h:146
beam_descr::elevation
float elevation
Definition:
structure.h:302
index_ent::source
char source[12]
Definition:
structure.h:38
hfs_descr::sigma_raie
float sigma_raie
Definition:
structure.h:272
position_descr::lambda
double lambda
Definition:
structure.h:117
pointer_descr::xcoord
int xcoord
Definition:
structure.h:71
skydip_descr::ncold
int ncold
Definition:
structure.h:235
skydip_descr::nsky
int nsky
Definition:
structure.h:235
scan_ent::size
int size
Definition:
structure.h:56
gauss_descr::err
float err[3 *MXGAUS]
Definition:
structure.h:250
cont_descr::nline
int nline
Definition:
structure.h:313
spectro_descr::vteles
float vteles
Definition:
structure.h:147
pointer_descr::continuum
int continuum
Definition:
structure.h:71
pointer_descr::plot
int plot
Definition:
structure.h:71
MSEQ
#define MSEQ
Definition:
structure.h:164
include
structure.h
Generated on Mon Feb 21 2022 20:37:01 for Linuxpops by
1.8.5