prepfold.h
1#ifndef _prepfold_h
2#define _prepfold_h
3
4/* Presto "position" struct, from include/presto.h */
5struct position {
6 float pow;
7 double p1;
8 double p2;
9 double p3;
10};
11
12/* Presto folstats struct from include/presto.h */
13struct foldstats {
14 double numdata; /* Number of data bins folded */
15 double data_avg; /* Average level of the data bins */
16 double data_var; /* Variance of the data bins */
17 double numprof; /* Number of bins in the profile */
18 double prof_avg; /* Average level of the profile bins */
19 double prof_var; /* Variance of the profile bins */
20 double redchi; /* Reduced chi-squared of the profile */
21};
22
23/* Slightly edited version of Scott's prepfold structure. Mostly
24 * corresponds to what is stored on disk. Original is
25 * in Presto's include/prepfold.h
26 */
27struct prepfoldinfo {
28 double *rawfolds; /* Raw folds (nsub * npart * proflen points) */
29 double *dms; /* DMs used in the trials */
30 double *periods; /* Periods used in the trials */
31 double *pdots; /* P-dots used in the trials */
32 foldstats *stats; /* Statistics for the raw folds */
33 int numdms; /* Number of 'dms' */
34 int numperiods; /* Number of 'periods' */
35 int numpdots; /* Number of 'pdots' */
36 int nsub; /* Number of frequency subbands folded */
37 int npart; /* Number of folds in time over integration */
38 int proflen; /* Number of bins per profile */
39 int numchan; /* Number of channels for radio data */
40 int pstep; /* Minimum period stepsize in profile phase bins */
41 int pdstep; /* Minimum p-dot stepsize in profile phase bins */
42 int dmstep; /* Minimum DM stepsize in profile phase bins */
43 int ndmfact; /* 2*ndmfact*proflen+1 DMs to search */
44 int npfact; /* 2*npfact*proflen+1 periods and p-dots to search */
45 char *filenm; /* Filename of the folded data */
46 char *candnm; /* String describing the candidate */
47 char *telescope; /* Telescope where observation took place */
48 char *pgdev; /* PGPLOT device to use */
49 char rastr[16]; /* J2000 RA string in format hh:mm:ss.ssss */
50 char decstr[16]; /* J2000 DEC string in format dd:mm:ss.ssss */
51 double dt; /* Sampling interval of the data */
52 double startT; /* Fraction of observation file to start folding */
53 double endT; /* Fraction of observation file to stop folding */
54 double tepoch; /* Topocentric eopch of data in MJD */
55 double bepoch; /* Barycentric eopch of data in MJD */
56 double avgvoverc; /* Average topocentric velocity */
57 double lofreq; /* Center of low frequency radio channel */
58 double chan_wid; /* Width of each radio channel in MHz */
59 double bestdm; /* Best DM */
60 position topo; /* Best topocentric p, pd, and pdd */
61 position bary; /* Best barycentric p, pd, and pdd */
62 position fold; /* f, fd, and fdd used to fold the initial data */
63 //orbitparams orb; /* Barycentric orbital parameters used in folds */
64};
65#endif

Generated using doxygen 1.14.0