1
+ #ifndef JHFNTUPLE_H
2
+ #define JHFNTUPLE_H
3
+ static const int MAX_N_PRIMARIES = 900 ;
4
+ static const int MAX_N_ACTIVE_TUBES = 2000 ;
5
+ static const int MAX_N_HITS_PER_TUBE = 90 ;
1
6
struct ntupleStruct
2
7
{
3
8
int mode ; // interaction mode
4
- int vtxvol ; // volume of vertex
5
- float vtx [3 ]; // interaction vertex
9
+ int nvtxs ; // number of vertices
10
+ int vtxsvol [MAX_N_PRIMARIES ]; // volume of vertices
11
+ float vtxs [MAX_N_PRIMARIES ][3 ]; // interaction vertices
6
12
int vecRecNumber ; // info event number in inputvetcotfile
7
13
int jmu ; // index to muon
8
14
int jp ; // index to proton
9
15
int npar ; // number of final state particles
10
- int ipnu [50 ]; // id of ith final state particle
11
- int flag [50 ]; // flag: -1 = incoming neutrino
16
+ int ipnu [MAX_N_PRIMARIES ]; // id of ith final state particle
17
+ int flag [MAX_N_PRIMARIES ]; // flag: -1 = incoming neutrino
12
18
// -2 = target
13
19
// 1 = outgoing lepton
14
20
// 2 = most energetic outgoing nucleon
15
- float m [50 ]; // mass of ith final state particle
16
- float p [50 ]; // momentum of ith final state particle
17
- float E [50 ]; // energy of ith final state particle
18
- int startvol [50 ]; // starting volume of ith final state particle
19
- int stopvol [50 ]; // stopping volume of ith final state particle
20
- float dir [50 ][3 ]; // direction of ith final state particle
21
- float pdir [50 ][3 ]; // momentum-vector of ith final state particle
22
- float stop [50 ][3 ]; // stopping point of ith final state particle
23
- float start [50 ][3 ]; // starting point of ith final state particle
24
- int parent [50 ]; // ID of parent of ith particle (0 if primary)
25
- float time [50 ]; // creation time of the ith particle
21
+ float m [MAX_N_PRIMARIES ]; // mass of ith final state particle
22
+ float p [MAX_N_PRIMARIES ]; // momentum of ith final state particle
23
+ float E [MAX_N_PRIMARIES ]; // energy of ith final state particle
24
+ int startvol [MAX_N_PRIMARIES ]; // starting volume of ith final state particle
25
+ int stopvol [MAX_N_PRIMARIES ]; // stopping volume of ith final state particle
26
+ float dir [MAX_N_PRIMARIES ][3 ]; // direction of ith final state particle
27
+ float pdir [MAX_N_PRIMARIES ][3 ]; // momentum-vector of ith final state particle
28
+ float stop [MAX_N_PRIMARIES ][3 ]; // stopping point of ith final state particle
29
+ float start [MAX_N_PRIMARIES ][3 ]; // starting point of ith final state particle
30
+ int parent [MAX_N_PRIMARIES ]; // ID of parent of ith particle (0 if primary)
31
+ float time [MAX_N_PRIMARIES ]; // creation time of the ith particle
26
32
27
33
int numTubesHit ; // Total number of tubes with hits
28
- int totalPe [500 ]; // The totalPE recorded at each tube
29
- float truetime [500 ][ 90 ]; // The true time of each hit
34
+ int totalPe [MAX_N_ACTIVE_TUBES ]; // The totalPE recorded at each tube
35
+ float truetime [MAX_N_ACTIVE_TUBES ][ MAX_N_HITS_PER_TUBE ]; // The true time of each hit
30
36
31
37
int numDigitizedTubes ; // Number of PMTs with digitized hits
32
- float q [500 ]; // The readout digitized pe
33
- float t [500 ]; // The readout digitized time
34
- int tubeid [500 ]; // The readout tube ID
38
+ float q [MAX_N_ACTIVE_TUBES ]; // The readout digitized pe
39
+ float t [MAX_N_ACTIVE_TUBES ]; // The readout digitized time
40
+ int tubeid [MAX_N_ACTIVE_TUBES ]; // The readout tube ID
35
41
float sumq ; // sum of q(readout digitized pe) in event
36
42
37
43
int fvnumTubesHit ; // Total number of inner tubes with hits
38
- int fvtotalPe [500 ]; // The totalPE recorded at each innertube
39
- float fvtruetime [500 ][ 90 ]; // The true time of each inner hit
44
+ int fvtotalPe [MAX_N_ACTIVE_TUBES ]; // The totalPE recorded at each innertube
45
+ float fvtruetime [MAX_N_ACTIVE_TUBES ][ MAX_N_HITS_PER_TUBE ]; // The true time of each inner hit
40
46
41
47
int fvnumDigitizedTubes ; // Number of PMTs with digitized hits
42
- float fvq [500 ]; // The readout digitized pe
43
- float fvt [500 ]; // The readout digitized time
44
- int fvtubeid [500 ]; // The readout tube ID
48
+ float fvq [MAX_N_ACTIVE_TUBES ]; // The readout digitized pe
49
+ float fvt [MAX_N_ACTIVE_TUBES ]; // The readout digitized time
50
+ int fvtubeid [MAX_N_ACTIVE_TUBES ]; // The readout tube ID
45
51
float fvsumq ; // sum of q(readout digitized pe) in event
46
52
};
47
53
48
54
extern struct ntupleStruct jhfNtuple ;
49
55
50
56
static const char * ntDesc =
51
57
"mode:I,"
52
- "vtxvol:I,"
53
- "vtx(3):R,"
58
+ "nvtxs[0,MAX_N_PRIMARIES]:I,"
59
+ "vtxsvol(npar):I,"
60
+ "vtxs(3,npar):R,"
54
61
"vecRecNumber:I,"
55
62
"jmu:I,"
56
63
"jp:I,"
57
- "npar[0,50 ]:I,"
64
+ "npar[0,MAX_N_PRIMARIES ]:I,"
58
65
"ipnu(npar):I,"
59
66
"flag(npar):I,"
60
67
"m(npar):R,"
@@ -68,19 +75,20 @@ static const char* ntDesc =
68
75
"startpos(3,npar):R,"
69
76
"parent(npar):I,"
70
77
"time(npar):R,"
71
- "numTubesHit[0,500 ]:I,"
78
+ "numTubesHit[0,MAX_N_ACTIVE_TUBES ]:I,"
72
79
"totalPe(numTubesHit):I,"
73
- "truetime(90 ,numTubesHit):R,"
74
- "numDigTubes[0,500 ]:I,"
80
+ "truetime(MAX_N_HITS_PER_TUBE ,numTubesHit):R,"
81
+ "numDigTubes[0,MAX_N_ACTIVE_TUBES ]:I,"
75
82
"q(numDigTubes):R,"
76
83
"t(numDigTubes):R,"
77
84
"tubeid(numDigTubes):I"
78
- "fvnumTubesHit[0,500 ]:I,"
85
+ "fvnumTubesHit[0,MAX_N_ACTIVE_TUBES ]:I,"
79
86
"fvtotalPe(fvnumTubesHit):I,"
80
- "fvtruetime(90 ,fvnumTubesHit):R,"
81
- "fvnumDigTubes[0,500 ]:I,"
87
+ "fvtruetime(MAX_N_HITS_PER_TUBE ,fvnumTubesHit):R,"
88
+ "fvnumDigTubes[0,MAX_N_ACTIVE_TUBES ]:I,"
82
89
"fvq(fvnumDigTubes):R,"
83
90
"fvt(fvnumDigTubes):R,"
84
91
"fvtubeid(fvnumDigTubes):I" ;
92
+ #endif
85
93
86
94
0 commit comments