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++ )
83 unsigned int st = ( *it )->status();
87 if ( hitst->
layer() == 1 ) tof1count.push_back( goodtof1trk );
90 if ( tof1count.size() != 1 )
return irc;
91 it = tofTrk.begin() + tof1count[0];
92 double tof = ( *it )->tof();
96 int cntr = ( *it )->tofID();
97 double path = ( ( *it )->path() ) * 10.0;
99 m_ph1 = ( *it )->ph();
100 m_zhit1 = ( ( *it )->zrhit() ) * 10;
102 m_mass2 = ptrk * ptrk * ( 1 / beta2 - 1 );
103 if ( ( m_mass2 > 20 ) || ( m_mass2 < -1 ) )
return irc;
104 if ( tof <= 0 )
return irc;
105 double chitemp = 99.;
107 double sigma_tmp = ( *it )->sigma( 0 );
108 for (
int i = 0; i < 5; i++ )
111 m_offset[i] = tof - ( *it )->texp( i ) -
112 ( *it )->toffset( i );
113 if ( sigma_tmp != 0 )
115 m_sigma[i] = 1.2 * sigma_tmp;
116 if ( i < 2 ) m_sigma[i] = sigma_tmp;
119 m_chi[i] = m_offset[i] / m_sigma[i];
121 if ( fabs( m_chi[i] ) < chitemp ) chitemp = fabs( m_chi[i] );
123 if ( fabs( ppp ) > pdftemp ) pdftemp = fabs( ppp );
128 if ( fabs( m_chimin ) >
chiMinCut() )
return irc;
129 for (
int i = 0; i < 5; i++ ) { m_prob[i] =
probCalculate( m_chi[i] * m_chi[i], 1 ); }
157 betagamma = ptrk / 139.57;
161 betagamma = ptrk / 493.68;
166 betagamma = ptrk / 938.27;
178 double beta = betagamma / TMath::Sqrt( 1 + betagamma * betagamma );
179 double Q0 =
sampleQ0( betagamma, beta );
180 double func[15] = { 0. };
182 func[1] = 1. / sqrt( Q );
183 func[2] = z / sqrt( Q );
184 func[3] = z * z / sqrt( Q );
188 func[7] = 1. / ( 0.84 * 0.84 + z * z );
191 func[10] = z * z * z;
192 func[11] = 1. / sqrt( Q0 );
193 func[12] = z / sqrt( Q0 );
194 func[13] = z * z / sqrt( Q0 );
195 func[14] = z * z * z / sqrt( Q0 );
197 for (
int i = 0; i < 15; i++ ) {
offset += m_pars[i] * func[i]; }
206 double cosz =
cos( ztof / 1000.0 );
212 sigma = 0.132405 - 0.135638 * cosz + 0.105528 * cosz * cosz;
217 sigma = 0.164057 - 0.199648 * cosz + 0.139481 * cosz * cosz;
222 sigma = 0.132943 - 0.0996678 * cosz + 0.0785578 * cosz * cosz;
226 sigma = 0.146572 - 0.124672 * cosz + 0.0920656 * cosz * cosz;
231 sigma = 0.1513 - 0.0806081 * cosz + 0.0607409 * cosz * cosz;
235 default:
sigma = 0.100;
break;
EvtRecTrack * PidTrk() const
double probCalculate(double chi2, int n)
double pdfCalculate(double offset, double sigma)
double pdfMinSigmaCut() const