File: types.h

package info (click to toggle)
aoflagger 2.13.0-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 4,232 kB
  • sloc: cpp: 61,805; python: 60; sh: 23; makefile: 8
file content (88 lines) | stat: -rw-r--r-- 2,053 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
#ifndef MSIO_TYPES
#define MSIO_TYPES

class AntennaInfo;
class BandInfo;
class FieldInfo;
class TimeFrequencyData;
class TimeFrequencyImager;
class FitsFile;

#define NUM_T_IS_FLOAT

#ifdef NUM_T_IS_FLOAT
typedef float num_t;

#define sqrtn(X) sqrtf(X)
#define expn(X) expf(X)
#define logn(X) logf(X)
#define sinn(X) sinf(X)
#define asinn(X) asinf(X)
#define cosn(X) cosf(X)
#define acosn(X) acosf(X)
#define tann(X) tanf(X)
#define atann(X) atanf(X)
#define atan2n(X, Y) atan2(X, Y)
#define fabsn(X) fabsf(X)
#define floorn(X) floorf(X)
#define ceiln(X) ceilf(X)
#define roundn(X) roundf(X)
#define pown(X, Y) powf(X, Y)
#define fmodn(X, Y) fmodf(X, Y)
#define M_PIn M_PI

#else // NOT NUM_T_IS_FLOAT

typedef double num_t;

#define sqrtn(X) sqrt(X)
#define expn(X) exp(X)
#define logn(X) log(X)
#define sinn(X) sin(X)
#define asinn(X) asin(X)
#define cosn(X) cos(X)
#define acosn(X) acos(X)
#define tann(X) tan(X)
#define atann(X) atan(X)
#define atan2n(X, Y) atan2(X, Y)
#define fabsn(X) fabs(X)
#define floorn(X) floor(X)
#define ceiln(X) ceil(X)
#define roundn(X) round(X)
#define pown(X, Y) pow(X, Y)
#define fmodn(X, Y) fmod(X, Y)
#define M_PIn M_PI

#endif

// numl_t is the numeric type for high precision, intermediate calculations
typedef long double numl_t;

#define sqrtnl(X) sqrtl(X)
#define expnl(X) expl(X)
#define lognl(X) logl(X)
#define sinnl(X) sinl(X)
#define asinnl(X) asinl(X)
#define cosnl(X) cosl(X)
#define tannl(X) tanl(X)
#define atannl(X) atanl(X)
#define atan2nl(X, Y) atan2l(X, Y)
#define fabsnl(X) fabsl(X)
#define floornl(X) floorl(X)
#define ceilnl(X) ceill(X)
#define roundnl(X) roundl(X)
#define pownl(X, Y) powl(X, Y)
#define fmodnl(X, Y) fmodl(X, Y)
// M_PIl is not defined on some OS-X systems
#ifndef M_PIl
#define M_PIl  3.1415926535897932384626433832795029L  /* pi */
#endif
#define M_PInl M_PIl

enum DataKind { ObservedData, CorrectedData, ResidualData, ModelData, WeightData };

class ParmTable;

enum BaselineIOMode { DirectReadMode, IndirectReadMode, MemoryReadMode, AutoReadMode };

#endif // MSIO_TYPES