StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StRareTrack.h
1 #ifndef STRARETRACK_HH
2 #define STRARETRACK_HH
3 #include "TObject.h"
4 #include <math.h>
5 
6 class StPrimaryTrack;
7 
8 class StRareTrack : public TObject{
9 
10  public:
11  StRareTrack();
13  ~StRareTrack(){};
14  int tracknumber() const;
15  int iflag() const;
16  float px() const;
17  float py() const;
18  float pz() const;
19  float p() const;
20  short chargesign() const;
21  float rapidity(float mass) const;
22  float pt() const;
23  float dca() const;
24  float dedx() const;
25  short ndedx() const;
26  float chisqxy() const;
27  float chisqz() const;
28  short npntpossible() const;
29  short npntfit() const;
30  float dedxExpected(float mass, float charge = 1) const;
31  float dedxPi() const;
32  float dedxProton() const;
33  float dedxDeuteron() const;
34  float dedxTriton() const;
35  float dedxHe3() const;
36  float dedxHe4() const;
37  int trigtype() const; //33 = random track
38  void SetTrigType(int type);
39 
40  private:
41  int ftracknumber;
42  int fiflag;
43  float fpx;
44  float fpy;
45  float fpz;
46  short fchargesign;
47  float fdca;
48  float fdedx;
49  short fndedx;
50  float fchisqxy;
51  float fchisqz;
52  short fnpntpossible;
53  short fnpntfit;
54  int ftrigtype;
55 
56  ClassDef(StRareTrack,2)
57 };
58 
59 inline int StRareTrack::tracknumber() const {return ftracknumber;}
60 inline int StRareTrack::iflag() const {return fiflag;}
61 inline float StRareTrack::px() const {return fpx;}
62 inline float StRareTrack::py() const {return fpy;}
63 inline float StRareTrack::pz() const {return fpz;}
64 inline float StRareTrack::p() const {return ::sqrt(fpx*fpx+fpy*fpy+fpz*fpz);}
65 inline float StRareTrack::pt() const {return ::sqrt(fpx*fpx+fpy*fpy);}
66 inline short StRareTrack::chargesign() const {return fchargesign;}
67 inline float StRareTrack::dca() const {return fdca;}
68 inline float StRareTrack::dedx() const {return fdedx;}
69 inline short StRareTrack::ndedx() const {return fndedx;}
70 inline float StRareTrack::chisqxy() const {return fchisqxy;}
71 inline float StRareTrack::chisqz() const {return fchisqz;}
72 inline short StRareTrack::npntpossible() const {return fnpntpossible;}
73 inline short StRareTrack::npntfit() const {return fnpntfit;}
74 inline float StRareTrack::dedxPi() const {return dedxExpected(0.139,1);}
75 inline float StRareTrack::dedxProton() const {return dedxExpected(0.939,1);}
76 inline float StRareTrack::dedxDeuteron() const {return dedxExpected(1.88,1);}
77 inline float StRareTrack::dedxTriton() const {return dedxExpected(2.82,1);}
78 inline float StRareTrack::dedxHe3() const {return dedxExpected(2.82,2);}
79 inline float StRareTrack::dedxHe4() const {return dedxExpected(3.76,2);}
80 inline int StRareTrack::trigtype() const {return ftrigtype;}
81 
82 #endif