CGEM BOSS 6.6.5.f
BESIII Offline Software System
Loading...
Searching...
No Matches
DstCgemKalTrack.cxx
Go to the documentation of this file.
1/*
2* @class : CgemTrack
3*
4* this class models "Kalman Track" from Cgem
5*
6* ********************************************************/
7
8#include "DstEvent/DstCgemKalTrack.h"
9
11
13{
14 HepVector za(5,0);
15 HepSymMatrix zea(5,0);
16 HepPoint3D poca(0,0,0);
17 m_trackId = -1;
18 for(int pid=0; pid<5; pid++) {
19 m_zhelixs.push_back(za);
20 m_zerrors.push_back(zea);
21 m_fhelixs.push_back(za);
22 m_ferrors.push_back(zea);
23 m_pocas.push_back(poca);
24 m_mass[pid] = 1;
25 m_charge[pid] = 1;
26 m_stat[0][pid] = 0;
27 m_stat[1][pid] = 0;
28
29 m_ndf[0][pid] = 0;
30 m_ndf[1][pid] = 0;
31 m_firstLayer[0][pid] = 0;
32 m_firstLayer[1][pid] = 0;
33 m_lastLayer[0][pid] = 0;
34 m_lastLayer[1][pid] = 0;
35 m_pxy[pid] = 0;
36 m_px[pid] = 0;
37 m_py[pid] = 0;
38 m_pz[pid] = 0;
39 m_p[pid] = 0;
40 m_theta[pid] = 0;
41 m_phi[pid] = 0;
42 m_x[pid] = 0;
43 m_y[pid] = 0;
44 m_z[pid] = 0;
45 m_r[pid] = 0;
46 m_stat[0][pid] = 0;
47 m_stat[1][pid] = 0;
48 m_chisq[0][pid] = 0;
49 m_chisq[1][pid] = 0;
50 m_ndf[0][pid] = 0;
51 m_ndf[1][pid] = 0;
52
53 }
54}
55
56
58 :m_trackId(other.m_trackId),
59 m_pocas(other.m_pocas),
60 m_zhelixs(other.m_zhelixs),
61 m_zerrors(other.m_zerrors),
62 m_fhelixs(other.m_fhelixs),
63 m_ferrors(other.m_ferrors)
64{
65 for(int i=0;i<5;i++){
66 m_charge[i] = other.m_charge[i];
67 m_stat[0][i] = other.m_stat[0][i];
68 m_stat[1][i] = other.m_stat[1][i];
69 m_firstLayer[0][i] = other.m_firstLayer[0][i];
70 m_firstLayer[1][i] = other.m_firstLayer[1][i];
71 m_lastLayer[0][i] = other.m_lastLayer[0][i];
72 m_lastLayer[1][i] = other.m_lastLayer[1][i];
73 m_mass[i] = other.m_mass[i];
74
75 m_pxy[i] = other.m_pxy[i];
76 m_px[i] = other.m_px[i];
77 m_py[i] = other.m_py[i];
78 m_pz[i] = other.m_pz[i];
79 m_p[i] = other.m_p[i];
80 m_theta[i] = other.m_theta[i];
81 m_phi[i] = other.m_phi[i];
82 m_x[i] = other.m_x[i];
83 m_y[i] = other.m_y[i];
84 m_z[i] = other.m_z[i];
85 m_r[i] = other.m_r[i];
86 m_chisq[0][i] = other.m_chisq[0][i];
87 m_chisq[1][i] = other.m_chisq[1][i];
88 m_ndf[0][i] = other.m_ndf[0][i];
89 m_ndf[1][i] = other.m_ndf[1][i];
90 m_nhits[i] = other.m_nhits[i];
91 }
92}
93
95 if(&other != this){
96 m_trackId = other.m_trackId;
97 m_pocas = other.m_pocas;
98 m_zhelixs = other.m_zhelixs;
99 m_zerrors = other.m_zerrors;
100 m_fhelixs = other.m_fhelixs;
101 m_ferrors = other.m_ferrors;
102 for(int i=0;i<5;i++){
103 m_charge[i] = other.m_charge[i];
104 m_stat[0][i] = other.m_stat[0][i];
105 m_stat[1][i] = other.m_stat[1][i];
106 m_firstLayer[0][i] = other.m_firstLayer[0][i];
107 m_firstLayer[1][i] = other.m_firstLayer[1][i];
108 m_lastLayer[0][i] = other.m_lastLayer[0][i];
109 m_lastLayer[1][i] = other.m_lastLayer[1][i];
110 m_mass[i] = other.m_mass[i];
111 m_chisq[0][i] = other.m_chisq[0][i];
112 m_chisq[1][i] = other.m_chisq[1][i];
113 m_pxy[i] = other.m_pxy[i];
114 m_px[i] = other.m_px[i];
115 m_py[i] = other.m_py[i];
116 m_pz[i] = other.m_pz[i];
117 m_p[i] = other.m_p[i];
118 m_theta[i] = other.m_theta[i];
119 m_phi[i] = other.m_phi[i];
120 m_x[i] = other.m_x[i];
121 m_y[i] = other.m_y[i];
122 m_z[i] = other.m_z[i];
123 m_r[i] = other.m_r[i];
124 //m_chi2[i] = other.m_chi2[i];
125 m_ndf[0][i] = other.m_ndf[0][i];
126 m_ndf[1][i] = other.m_ndf[1][i];
127 m_nhits[i] = other.m_nhits[i];
128 }
129 }
130 return *this;
131}
132
133
135
136 }
137
138
139const HepLorentzVector DstCgemKalTrack::p4() const{
140 const HepLorentzVector p_LV( px(), py(), pz(), sqrt(pow(mass(),2)+pow(p(),2)) );
141 return p_LV;
142}
143
144
145const HepLorentzVector DstCgemKalTrack::p4(double v_mass) const{
146 const HepLorentzVector p_LV( px(), py(), pz(), sqrt(pow(v_mass,2)+pow(p(),2)) );
147 return p_LV;
148}
149
150const Hep3Vector DstCgemKalTrack::p3() const {
151 const Hep3Vector p3( px(), py(), pz() );
152 return p3;
153}
154
157}
HepGeom::Point3D< double > HepPoint3D
const HepPoint3D x3() const
const HepLorentzVector p4() const
DstCgemKalTrack & operator=(const DstCgemKalTrack &)
const Hep3Vector p3() const