CGEM BOSS 6.6.5.i
BESIII Offline Software System
Loading...
Searching...
No Matches
MdcDedxTrk Class Reference

#include <MdcDedxTrk.h>

Public Member Functions

 MdcDedxTrk (RecMdcTrack &trk)
 
 MdcDedxTrk (RecMdcKalTrack &trk_kal, int pid)
 
 MdcDedxTrk ()
 
 ~MdcDedxTrk ()
 
void set_ExTrk (RecMdcTrack &trk)
 
void set_ExTrk_Kal (RecMdcKalTrack &trk_kal, int pid)
 
double cal_dedx (float)
 
double cal_dedx_bitrunc (float, int, int &)
 
double cal_dedx_median (float)
 
double cal_dedx_geometric (float)
 
double cal_dedx_geometric_trunc (float)
 
double cal_dedx_harmonic (float)
 
double cal_dedx_harmonic_trunc (float)
 
double cal_dedx_transform (int)
 
double cal_dedx_log (float, int)
 
double SpaceChargeCorrec (double, double, int, double)
 
void set_dEdx (int l, float dEdx_meas, int trkalg, int runflag, int vflag[3], double t0, vector< double > &DedxCurve_Parameter, vector< double > &DedxSigma_Parameter, MdcDedxCorrection *)
 
void set_phlist (const vector< double > &phlist)
 
void set_phlist_hit (const vector< double > &phlist)
 
void setVecDedxHits (const DedxHitRefVec &vecdedxhit)
 
vector< double > get_phlist (void)
 
vector< double > get_phlist_hit (void)
 
DedxHitRefVec getVecDedxHits () const
 
RecMdcTracktrk_ptr () const
 
RecMdcKalTracktrk_ptr_kal () const
 
int stat () const
 
int trk_id () const
 
int nsample () const
 
int quality () const
 
double dedx () const
 
int charge () const
 
double P () const
 
double theta () const
 
double phi () const
 
double Pt () const
 
double expect (int pid) const
 
double exp_sigma (int pid) const
 
double prob (int pid) const
 
double chi_dedx (int pid) const
 
double * pexpect ()
 
double * pexp_sigma ()
 
double * pprob ()
 
double * pchi_dedx ()
 

Detailed Description

Definition at line 21 of file MdcDedxTrk.h.

Constructor & Destructor Documentation

◆ MdcDedxTrk() [1/3]

MdcDedxTrk::MdcDedxTrk ( RecMdcTrack & trk)

Definition at line 43 of file MdcDedxTrk.cxx.

44{
45 m_trk = 0;
46 m_trk_kal = 0;
47 m_stat = -1;
48 m_trk_id = 0;
49 m_quality = -99;
50 m_charge = 0;
51 m_P = 0;
52 m_theta = 0;
53 m_phi = 0;
54 m_pl_rp = 0;
55 m_nsample = 0;
56 m_dEdx = 0;
57 m_truncate = 0.7;
58
59 set_ExTrk( trk );
60#ifdef DEBUG
61 std::cout<<"MdcDedxTrk(2) constructed!"<<std::endl;
62#endif
63}
void set_ExTrk(RecMdcTrack &trk)

◆ MdcDedxTrk() [2/3]

MdcDedxTrk::MdcDedxTrk ( RecMdcKalTrack & trk_kal,
int pid )

Definition at line 65 of file MdcDedxTrk.cxx.

66{
67 m_trk = 0;
68 m_trk_kal = 0;
69 m_stat = -1;
70 m_trk_id = 0;
71 m_quality = -99;
72 m_charge = 0;
73 m_P = 0;
74 m_theta = 0;
75 m_phi = 0;
76 m_pl_rp = 0;
77 m_nsample = 0;
78 m_dEdx = 0;
79 m_truncate = 0.7;
80
81 set_ExTrk_Kal( trk_kal, pid );
82#ifdef DEBUG
83 std::cout<<"MdcDedxTrk(2) kal constructed!"<<std::endl;
84#endif
85}
void set_ExTrk_Kal(RecMdcKalTrack &trk_kal, int pid)

◆ MdcDedxTrk() [3/3]

MdcDedxTrk::MdcDedxTrk ( )

Definition at line 14 of file MdcDedxTrk.cxx.

15{
16 m_trk = 0;
17 m_trk_kal = 0;
18 m_stat = -1;
19 m_trk_id = 0;
20 m_quality = -99;
21 m_charge = 0;
22 m_P = 0;
23 m_theta = 0;
24 m_phi = 0;
25 m_pl_rp = 0;
26 m_nsample = 0;
27
28 m_dEdx = 0;
29 m_truncate = 1;
30 for( unsigned a = 0; a < 5 ; a++ )
31 {
32 dedx_exp[a]=0.0;
33 ex_sigma[a]=0.0;
34 pid_prob[a]=0.0;
35 chi_ex[a]=999.0;
36 }
37
38#ifdef DEBUG
39 std::cout<<"MdcDedxTrk(1) constructed!"<<std::endl;
40#endif
41}

◆ ~MdcDedxTrk()

MdcDedxTrk::~MdcDedxTrk ( )

Definition at line 87 of file MdcDedxTrk.cxx.

88{
89#ifdef DEBUG
90 std::cout<<"MdcDedxTrk destructed!!!"<<std::endl;
91#endif
92}

Member Function Documentation

◆ cal_dedx()

double MdcDedxTrk::cal_dedx ( float truncate)

Definition at line 153 of file MdcDedxTrk.cxx.

154{
155 m_truncate = truncate;
156 sort(m_phlist.begin(),m_phlist.end());
157 int nsampl = (int)( m_phlist.size()*truncate );
158 double qSum = 0;
159 unsigned int i = 0;
160 for(vector<double>::iterator ql= m_phlist.begin();ql!=m_phlist.end();ql++)
161 {
162 i++;
163 if(i<= nsampl) qSum += (*ql);
164 }
165
166 float trunc=qSum/nsampl;
167 return trunc;
168 std::cout<<"MdcDedxTrk::cal_dedx()!!!"<<std::endl;
169}

◆ cal_dedx_bitrunc()

double MdcDedxTrk::cal_dedx_bitrunc ( float truncate,
int alg,
int & usedhit )

Definition at line 171 of file MdcDedxTrk.cxx.

172{
173 m_truncate = truncate;
174 sort(m_phlist.begin(),m_phlist.end());
175 int nsampl = (int)( m_phlist.size()*truncate );
176 int smpl = (int)(m_phlist.size()*(truncate+0.05));
177 int min_cut = (int)( m_phlist.size()*0.05 + 0.5 );
178 double qSum = 0;
179 unsigned i = 0;
180 for(vector<double>::iterator ql= m_phlist.begin();ql!=m_phlist.end();ql++)
181 {
182 i++;
183 if(i<= smpl && i>=min_cut ) qSum += (*ql);
184 }
185 double trunc=-99;
186 usedhit = smpl-min_cut+1;
187 if(usedhit>0) trunc=qSum/usedhit;
188
189 return trunc;
190 std::cout<<"MdcDedxTrk::cal_dedx()!!!"<<std::endl;
191}

◆ cal_dedx_geometric()

double MdcDedxTrk::cal_dedx_geometric ( float truncate)

Definition at line 207 of file MdcDedxTrk.cxx.

208{
209 sort(m_phlist.begin(),m_phlist.end());
210
211 int nsampl = m_phlist.size();
212 double qSum = 1.0;
213 for(vector<double>::iterator ql= m_phlist.begin();ql!=m_phlist.end();ql++){
214 qSum *= (*ql);
215 }
216
217 double trunc = pow(qSum,1/double(nsampl));
218 return trunc;
219 std::cout<<"MdcDedxTrk::cal_dedx()!!!"<<std::endl;
220}

◆ cal_dedx_geometric_trunc()

double MdcDedxTrk::cal_dedx_geometric_trunc ( float truncate)

Definition at line 222 of file MdcDedxTrk.cxx.

223{
224 m_truncate = truncate;
225 sort(m_phlist.begin(),m_phlist.end());
226 int nsampl = (int)( m_phlist.size()*truncate );
227 double qSum = 1.0;
228 unsigned i = 0;
229 for(vector<double>::iterator ql= m_phlist.begin();ql!=m_phlist.end();ql++){
230 i++;
231 if( i<= nsampl )
232 qSum *= (*ql);
233 }
234
235 double trunc = pow(qSum,1/double(nsampl));
236 return trunc;
237
238 std::cout<<"MdcDedxTrk::cal_dedx()!!!"<<std::endl;
239}

◆ cal_dedx_harmonic()

double MdcDedxTrk::cal_dedx_harmonic ( float truncate)

Definition at line 241 of file MdcDedxTrk.cxx.

242{
243 sort(m_phlist.begin(),m_phlist.end());
244
245 int nsampl = m_phlist.size();
246 double qSum = 0;
247 for(vector<double>::iterator ql= m_phlist.begin();ql!=m_phlist.end();ql++){
248 qSum += 1/(*ql);
249 }
250
251 float trunc=nsampl/qSum;
252 return trunc;
253 std::cout<<"MdcDedxTrk::cal_dedx()!!!"<<std::endl;
254}

◆ cal_dedx_harmonic_trunc()

double MdcDedxTrk::cal_dedx_harmonic_trunc ( float truncate)

Definition at line 256 of file MdcDedxTrk.cxx.

257{
258 m_truncate = truncate;
259 sort(m_phlist.begin(),m_phlist.end());
260 int nsampl = (int)( m_phlist.size()*truncate );
261 double qSum = 0;
262 unsigned i = 0;
263 for(vector<double>::iterator ql= m_phlist.begin();ql!=m_phlist.end();ql++){
264 i++;
265 if( i<= nsampl )
266 qSum += 1/(*ql);
267 }
268
269 float trunc= nsampl/qSum;
270 return trunc;
271 std::cout<<"MdcDedxTrk::cal_dedx()!!!"<<std::endl;
272}

◆ cal_dedx_log()

double MdcDedxTrk::cal_dedx_log ( float truncate,
int alg )

Definition at line 291 of file MdcDedxTrk.cxx.

292{
293 double qSum = 0;
294 unsigned i = 0;
295 for(vector<double>::iterator ql= m_phlist.begin();ql!=m_phlist.end();ql++){
296 i++;
297 qSum += log(*ql);
298 }
299
300 float trunc=qSum/m_phlist.size();
301 return trunc;
302 std::cout<<"MdcDedxTrk::cal_dedx_log()!!!"<<std::endl;
303}

◆ cal_dedx_median()

double MdcDedxTrk::cal_dedx_median ( float truncate)

Definition at line 193 of file MdcDedxTrk.cxx.

194{
195 sort(m_phlist.begin(),m_phlist.end());
196
197 int nsample = m_phlist.size();
198 double median;
199 if( fmod(double(nsample),2.0) ) {
200 median = m_phlist[(nsample-1)/2];
201 } else {
202 median= 0.5*( m_phlist[nsample/2] + m_phlist[nsample/2-1] );
203 }
204 return median;
205}
int nsample() const
Definition MdcDedxTrk.h:60

◆ cal_dedx_transform()

double MdcDedxTrk::cal_dedx_transform ( int alg)

Definition at line 274 of file MdcDedxTrk.cxx.

275{
276 sort(m_phlist.begin(),m_phlist.end());
277
278 int nsampl = m_phlist.size();
279 double qSum = 0;
280 for(vector<double>::iterator ql= m_phlist.begin();ql!=m_phlist.end();ql++){
281 qSum += 1/sqrt(*ql);
282 }
283
284 float trunc=1/qSum;
285
286 return trunc;
287 std::cout<<"MdcDedxTrk::cal_dedx()!!!"<<std::endl;
288}

◆ charge()

int MdcDedxTrk::charge ( ) const
inline

Definition at line 63 of file MdcDedxTrk.h.

63{return m_charge;}

◆ chi_dedx()

double MdcDedxTrk::chi_dedx ( int pid) const
inline

Definition at line 122 of file MdcDedxTrk.h.

123{
124 if( pid >= 0 && pid < 5 ) return chi_ex[pid];
125 else return -1;
126}

◆ dedx()

double MdcDedxTrk::dedx ( ) const
inline

Definition at line 62 of file MdcDedxTrk.h.

62{return m_dEdx;}

◆ exp_sigma()

double MdcDedxTrk::exp_sigma ( int pid) const
inline

Definition at line 110 of file MdcDedxTrk.h.

111{
112 if( pid >= 0 && pid < 5 ) return ex_sigma[pid];
113 else return -1;
114}

◆ expect()

double MdcDedxTrk::expect ( int pid) const
inline

Definition at line 104 of file MdcDedxTrk.h.

105{
106 if( pid >= 0 && pid < 5 ) return dedx_exp[pid];
107 else return -1;
108}

◆ get_phlist()

vector< double > MdcDedxTrk::get_phlist ( void )
inline

Definition at line 49 of file MdcDedxTrk.h.

49{return m_phlist;}

◆ get_phlist_hit()

vector< double > MdcDedxTrk::get_phlist_hit ( void )
inline

Definition at line 50 of file MdcDedxTrk.h.

50{return m_phlist_hit;}

◆ getVecDedxHits()

DedxHitRefVec MdcDedxTrk::getVecDedxHits ( ) const
inline

Definition at line 51 of file MdcDedxTrk.h.

51{return m_vecdedxhit;}

◆ nsample()

int MdcDedxTrk::nsample ( ) const
inline

Definition at line 60 of file MdcDedxTrk.h.

60{return m_nsample;}

Referenced by cal_dedx_median(), and set_dEdx().

◆ P()

double MdcDedxTrk::P ( ) const
inline

Definition at line 64 of file MdcDedxTrk.h.

64{return m_P;}

◆ pchi_dedx()

double * MdcDedxTrk::pchi_dedx ( )
inline

Definition at line 75 of file MdcDedxTrk.h.

75{return chi_ex;}

◆ pexp_sigma()

double * MdcDedxTrk::pexp_sigma ( )
inline

Definition at line 73 of file MdcDedxTrk.h.

73{return ex_sigma;}

◆ pexpect()

double * MdcDedxTrk::pexpect ( )
inline

Definition at line 72 of file MdcDedxTrk.h.

72{return dedx_exp;}

◆ phi()

double MdcDedxTrk::phi ( ) const
inline

Definition at line 66 of file MdcDedxTrk.h.

66{return m_phi;}

◆ pprob()

double * MdcDedxTrk::pprob ( )
inline

Definition at line 74 of file MdcDedxTrk.h.

74{return pid_prob;}

◆ prob()

double MdcDedxTrk::prob ( int pid) const
inline

Definition at line 116 of file MdcDedxTrk.h.

117{
118 if( pid >= 0 && pid < 5 ) return pid_prob[pid];
119 else return -1;
120}

◆ Pt()

double MdcDedxTrk::Pt ( ) const
inline

Definition at line 67 of file MdcDedxTrk.h.

67{return m_P*std::sin(m_theta);}

◆ quality()

int MdcDedxTrk::quality ( ) const
inline

Definition at line 61 of file MdcDedxTrk.h.

61{return m_quality;}

◆ set_dEdx()

void MdcDedxTrk::set_dEdx ( int l,
float dEdx_meas,
int trkalg,
int runflag,
int vflag[3],
double t0,
vector< double > & DedxCurve_Parameter,
vector< double > & DedxSigma_Parameter,
MdcDedxCorrection * ex_calib )

Definition at line 307 of file MdcDedxTrk.cxx.

308{
309#ifdef DEBUG
310 cout<<"in MdcDedxTrk::set_dEdx() landau: "<<landau<<" dedx: "<<dEdx<<" nsample(): "<<nsample()<<" ph size: "<<m_phlist.size()<<" m_P: "<<m_P<<" theta: "<<m_theta<<" pl-rp: "<<m_pl_rp<<endl;
311#endif
312
313 m_dEdx = dEdx;
314 int dedxhit_use = (int)(m_phlist.size()*m_truncate);
315
316 //some old data with od methods
317 if(runflag ==1 || runflag ==2 )
318 ex_calib->dedx_pid_exp_old( landau, runflag, (float)dEdx, (int)dedxhit_use,
319 (float)m_P, (float)m_theta, (float)t0,(float)m_pl_rp,
320 dedx_exp, ex_sigma, pid_prob, chi_ex);
321 //for 2009 psip data and after
322 else
323 ex_calib->dedx_pid_exp( vflag, (float)dEdx, trkalg,(int)dedxhit_use,
324 (float)m_P, (float)m_theta, (float)t0,(float)m_pl_rp,
325 dedx_exp, ex_sigma, pid_prob, chi_ex, DedxCurve_Parameter, DedxSigma_Parameter);
326
327#ifdef DEBUG
328 std::cout<<"MdcDedxTrk::set_dEdx()!!!"<<std::endl;
329#endif
330}
void dedx_pid_exp_old(int landau, int runflag, float dedx, int Nhit, float mom, float theta, float t0, float lsamp, double dedx_ex[5], double ex_sigma[5], double pid_prob[5], double chi_dedx[5]) const
void dedx_pid_exp(int vflag[3], float dedx, int trkalg, int Nhit, float mom, float theta, float t0, float lsamp, double dedx_ex[5], double ex_sigma[5], double pid_prob[5], double chi_dedx[5], std::vector< double > &DedxCurve_Parameter, std::vector< double > &DedxSigma_Parameter) const

◆ set_ExTrk()

void MdcDedxTrk::set_ExTrk ( RecMdcTrack & trk)

Definition at line 94 of file MdcDedxTrk.cxx.

95{
96 for( unsigned a = 0; a < 5 ; a++ )
97 {
98 dedx_exp[a]=0.0;
99 ex_sigma[a]=0.0;
100 pid_prob[a]=0.0;
101 chi_ex[a]=0.0;
102 }
103 m_stat = 1;
104 m_trk = &trk;
105 m_trk_id = trk.trackId();
106 m_quality = trk.stat();
107
108 m_charge = ( trk.helix(2) > 0 )? 1 : -1;
109 float m_Pt = 1.0/fabs( trk.helix(2) );
110 m_P = m_Pt*sqrt(1 + trk.helix(4)*trk.helix(4));
111 m_theta = M_PI_2 - atan( trk.helix(4) );
112 m_phi = ( trk.helix(1) < 3*M_PI_2 )? trk.helix(1)+M_PI_2 : trk.helix(1)-3*M_PI_2;
113 m_nsample = trk.getNhits();
114 m_pl_rp = 1.5;
115 //cout<<"set_ExTrk: "<<trk.helix(0)<<" "<<trk.helix(1)<<" "<<trk.helix(2)<<" "<<trk.helix(3)<<" "<<trk.helix(4)<<endl;
116
117#ifdef DEBUG
118 std::cout<<"MdcDedxTrk::set_ExTrk(&trk)!!!"<<std::endl;
119#endif
120}
const int trackId() const
Definition DstMdcTrack.h:52
const int stat() const
Definition DstMdcTrack.h:65
const HepVector helix() const
......
const int getNhits() const
Definition RecMdcTrack.h:56

Referenced by MdcDedxTrk().

◆ set_ExTrk_Kal()

void MdcDedxTrk::set_ExTrk_Kal ( RecMdcKalTrack & trk_kal,
int pid )

Definition at line 122 of file MdcDedxTrk.cxx.

123{
124 DstMdcKalTrack* dstTrk = &trk_kal;
125 for( unsigned a = 0; a < 5 ; a++ )
126 {
127 dedx_exp[a]=0.0;
128 ex_sigma[a]=0.0;
129 pid_prob[a]=0.0;
130 chi_ex[a]=0.0;
131 }
132 if(pid<0 || pid>4) pid = 2;
133 m_stat = 1;
134 m_trk_kal = &trk_kal;
135 m_trk_id = trk_kal.trackId();
136 m_quality = dstTrk->getStat(pid);
137
138 HepVector kal_helix = dstTrk->getFHelix(pid);
139 m_charge = ( kal_helix[2] > 0 )? 1 : -1;
140 float m_Pt = 1.0/fabs( kal_helix[2] );
141 m_P = m_Pt*sqrt(1 + kal_helix[4]*kal_helix[4]);
142 m_theta = M_PI_2 - atan( kal_helix[4] );
143 m_phi = ( kal_helix[1] < 3*M_PI_2 )? kal_helix[1]+M_PI_2 : kal_helix[1]-3*M_PI_2;
144 m_nsample = trk_kal.getNhits(pid);
145 m_pl_rp = 1.5;
146 //cout<<"set_ExTrk_Kal: "<<kal_helix[0]<<" "<<kal_helix[1]<<" "<<kal_helix[2]<<" "<<kal_helix[3]<<" "<<kal_helix[4]<<endl;
147#ifdef DEBUG
148 std::cout<<"MdcDedxTrk::set_ExTrk_Kal(&trk_kal)!!!"<<std::endl;
149#endif
150}
const int getStat(const int pid) const
const int trackId() const
const HepVector & getFHelix(const int pid) const
int getNhits(int pid) const

Referenced by MdcDedxTrk().

◆ set_phlist()

void MdcDedxTrk::set_phlist ( const vector< double > & phlist)
inline

Definition at line 45 of file MdcDedxTrk.h.

45{m_phlist = phlist;}

Referenced by MdcDedxRecon::execute(), MdcDedxRecon::kaltrackrec(), and MdcDedxRecon::mdctrackrec().

◆ set_phlist_hit()

void MdcDedxTrk::set_phlist_hit ( const vector< double > & phlist)
inline

Definition at line 46 of file MdcDedxTrk.h.

46{m_phlist_hit = phlist;}

Referenced by MdcDedxRecon::execute(), MdcDedxRecon::kaltrackrec(), and MdcDedxRecon::mdctrackrec().

◆ setVecDedxHits()

void MdcDedxTrk::setVecDedxHits ( const DedxHitRefVec & vecdedxhit)
inline

Definition at line 47 of file MdcDedxTrk.h.

47{ m_vecdedxhit= vecdedxhit;}

Referenced by MdcDedxRecon::execute(), MdcDedxRecon::kaltrackrec(), and MdcDedxRecon::mdctrackrec().

◆ SpaceChargeCorrec()

double MdcDedxTrk::SpaceChargeCorrec ( double m_theta,
double mom,
int Particle,
double dEdx )

Definition at line 333 of file MdcDedxTrk.cxx.

334{
335 const int par_cand( 5 );
336 const float Charge_Mass[par_cand] = {0.00051100, 0.10566, 0.13957, 0.4937, 0.93827 };
337 double beta_G;
338 double e_Par[5] = {143.349, 1.7315, 0.192616, 2.90437, 1.08248};
339 double Beta_Gamma[22] ={0.373026, 0.479605, 0.586184, 0.692763, 0.799342, 782.779, 1565.56,
340 2348.34, 17.2727, 18.1245, 1.43297, 2.14946, 12.1803, 13.6132, 6.62515, 10.4109,
341 14.1967, 17.9825, 21.7683, 26.0274, 30.7596, 35.4919 };
342 double K_par[22] ={4.64411e-05, 5.86544e-05, 8.05289e-05, 8.46981e-05, 8.92014e-05, 4.74517e-05,
343 4.51684e-05, 5.32732e-05, 6.12803e-05, 6.14592e-05, 8.08608e-05, 6.73184e-05, 5.46448e-05,
344 6.1377e-05, 6.57385e-05, 7.03053e-05, 6.61171e-05, 6.86824e-05, 6.246e-05, 7.25988e-05,
345 7.11034e-05, 6.24924e-05 };
346 double D_par[22] ={0.0871504, 0.0956379, 0.117193, 0.118647, 0.127203, 0.0566449, 0.0529198,
347 0.0642525, 0.0764562, 0.081341, 0.0952263, 0.0987536, 0.0639901, 0.0845994,0.0777062,
348 0.0823206, 0.0783874, 0.079537, 0.0815792, 0.0849875, 0.0824751,0.0776296 };
349 double DSqr_par[22] = {0.00759519, 0.0091466, 0.0137341, 0.0140772, 0.0161807, 0.00320864,
350 0.00280051, 0.00412839, 0.00584555, 0.00661636, 0.00906805, 0.00975227, 0.00409473,
351 0.00715706, 0.00603826, 0.00677668, 0.00614458, 0.00632613, 0.00665516, 0.00722288,
352 0.00680214, 0.00602635};
353
354 beta_G = mom/Charge_Mass[Particle];
355 if(beta_G <0.3) beta_G =0.3;
356 double bet=beta_G/TMath::Sqrt(beta_G*beta_G+1);
357 double fterm=TMath::Log(e_Par[2]+1/pow(beta_G,e_Par[4]));
358 double fitval=e_Par[0]/pow(bet,e_Par[3])*(e_Par[1]-pow(bet,e_Par[3])-fterm);
359 TGraphErrors *gr1 = new TGraphErrors(22,Beta_Gamma, K_par,0,0);
360 TGraphErrors *gr2 = new TGraphErrors(22,Beta_Gamma, DSqr_par,0,0);
361
362 double par[3];
363 par[0] = fitval;
364 par[1] = gr1->Eval(m_theta);
365 par[2] = gr2->Eval(m_theta);
366 Double_t y = fabs(cos(m_theta));
367 double electron_par[3] ={334.032, 6.20658e-05, 0.00525673};
368 double arg= TMath::Sqrt(y*y+ par[2]);
369 //double cal_factor =par[0]*TMath::Exp(-(par[1]* par[0])/arg);
370 double cal_factor =TMath::Exp(-(par[1]* par[0])/arg);
371 double arg_electron = TMath::Sqrt(y*y + electron_par[2]);
372 //double electron_factor = electron_par[0]*TMath::Exp(-(electron_par[1]* electron_par[0])/arg);
373 double electron_factor = TMath::Exp(-(electron_par[1]* electron_par[0])/arg_electron);
374 //cout<<"cal_factor = "<<cal_factor<<" electron_factor = "<<electron_factor<<endl;
375 double dedx_cal = dEdx/(cal_factor/electron_factor);
376 //double dedx_cal = dEdx/cal_factor;
377 //cout<<"m_theta= "<<m_theta<<" y ="<<y<<" beta_G = "<<beta_G <<" dEdx = "<<dEdx<<" cal dedx = "<<dedx_cal<<endl;
378 delete gr1;
379 delete gr2;
380 return dedx_cal;
381}
double cos(const BesAngle a)
Definition BesAngle.h:213
double arg(const EvtComplex &c)
HepMC::GenParticle Particle

Referenced by MdcDedxCorrection::dedx_pid_exp_old().

◆ stat()

int MdcDedxTrk::stat ( ) const
inline

Definition at line 57 of file MdcDedxTrk.h.

57{return m_stat;}

◆ theta()

double MdcDedxTrk::theta ( ) const
inline

Definition at line 65 of file MdcDedxTrk.h.

65{return m_theta;}

◆ trk_id()

int MdcDedxTrk::trk_id ( ) const
inline

Definition at line 58 of file MdcDedxTrk.h.

58{return m_trk_id;}

Referenced by MdcDedxRecon::execute(), MdcDedxRecon::kaltrackrec(), and MdcDedxRecon::mdctrackrec().

◆ trk_ptr()

RecMdcTrack * MdcDedxTrk::trk_ptr ( ) const
inline

Definition at line 53 of file MdcDedxTrk.h.

53{return m_trk;}

◆ trk_ptr_kal()

RecMdcKalTrack * MdcDedxTrk::trk_ptr_kal ( ) const
inline

Definition at line 54 of file MdcDedxTrk.h.

54{return m_trk_kal;}

The documentation for this class was generated from the following files: