Class Reference for E1039 Core & Analysis Software
MatrixData.cc
Go to the documentation of this file.
1 #include <cmath>
2 #include "MatrixData.h"
3 using namespace std;
4 
6  : id(0), charge(0), pX(-9999), pY(-9999), pZ(-9999), chisq(-9999)
7 {
8  for(int i=0; i<4; i++)
9  {
10  exp_xpos[i] = -9999;
11  exp_ypos[i] = -9999;
12 
13  for(int j=0; j<3; j++)
14  {
15  detectorIDs[j][i] = 0;
16  elementIDs[j][i] = 0;
17  el_pos[j][i] = -9999;
18  zpos[j][i] = -9999;
19  }
20  }
21 }
22 
24 {
25  int tb = 0;
26 
27  if( detectorIDs[0][0] == 32 && detectorIDs[0][1] == 38 && detectorIDs[0][2] == 40 && detectorIDs[0][3] == 46)
28  {
29  tb = 1;
30  }
31  else if( detectorIDs[0][0] == 31 && detectorIDs[0][1] == 37 && detectorIDs[0][2] == 39 && detectorIDs[0][3] == 45)
32  {
33  tb = -1;
34  }
35 
36  id = tb*( (elementIDs[0][0]-1)*pow(16,3) + (elementIDs[0][1]-1)*pow(16,2) + (elementIDs[0][2]-1)*16 + elementIDs[0][3] );
37 }
38 
40  : mass(-9999), x1(-9999), x2(-9999), xf(-9999)
41 {
42  ;
43 }
float exp_xpos[4]
at X hodo stations only
Definition: MatrixData.h:22
float el_pos[3][4]
Definition: MatrixData.h:19
int tb
Definition: MatrixData.h:11
float exp_ypos[4]
Definition: MatrixData.h:23
Road()
Definition: MatrixData.cc:5
void get_id()
Definition: MatrixData.cc:23
float zpos[3][4]
Definition: MatrixData.h:20
int detectorIDs[3][4]
followings are [x,y,dp][st]
Definition: MatrixData.h:17
int elementIDs[3][4]
Definition: MatrixData.h:18