65 double ptrk = mdcTrk->
p();
71 SmartRefVector<RecTofTrack> tofTrk = recTrk->
tofTrack();
72 SmartRefVector<RecTofTrack>::iterator it;
74 const std::vector<TTofTrack* >& tofTrk = recTrk->
tofTrack();
75 std::vector<TTofTrack* >::const_iterator it;
79 std::vector<int> tof1count;
81 for(it = tofTrk.begin(); it!=tofTrk.end(); it++,goodtof1trk++) {
82 unsigned int st = (*it)->status();
86 if( hitst->
layer()==1 ) tof1count.push_back(goodtof1trk);
89 if(tof1count.size()!=1)
return irc;
90 it = tofTrk.begin()+tof1count[0];
91 double tof = (*it)->tof();
95 int cntr = (*it)->tofID();
96 double path = ((*it)->path())*10.0;
99 m_zhit1 = ((*it)->zrhit())*10;
101 m_mass2 = ptrk * ptrk * (1/beta2 -1);
102 if ((m_mass2>20)||(m_mass2<-1))
return irc;
103 if(tof <=0 )
return irc;
104 double chitemp = 99.;
106 double sigma_tmp= (*it)->sigma(0);
107 for(
int i = 0; i < 5; i++) {
109 m_offset[i] = tof - (*it)->texp(i)-(*it)->toffset(i);
111 m_sigma[i] = 1.2*sigma_tmp;
112 if(i<2) m_sigma[i]=sigma_tmp;
115 m_chi[i] = m_offset[i]/m_sigma[i];
117 if(fabs(m_chi[i]) < chitemp) chitemp = fabs(m_chi[i]);
119 if(fabs(ppp) > pdftemp) pdftemp = fabs(ppp);
124 if(fabs(m_chimin) >
chiMinCut())
return irc;
125 for(
int i = 0; i < 5; i++) {
204 double cosz =
cos(ztof/1000.0);
209 sigma = 0.132405-0.135638*cosz+0.105528*cosz*cosz;
214 sigma = 0.164057 -0.199648*cosz+ 0.139481*cosz*cosz;
219 sigma = 0.132943-0.0996678*cosz+0.0785578*cosz*cosz;
223 sigma = 0.146572 -0.124672*cosz+0.0920656*cosz*cosz;
228 sigma = 0.1513 -0.0806081*cosz+0.0607409*cosz*cosz;
EvtRecTrack * PidTrk() const
double probCalculate(double chi2, int n)
double pdfCalculate(double offset, double sigma)
double pdfMinSigmaCut() const