29 double dr(0),phi0(0),kappa(0),dz(0),tanl(0);
37 if (kappa > 0.0000000001)
39 else if (kappa < -0.0000000001)
43 if(kappa!=0) pxy = 1.0/fabs(kappa);
45 double px = pxy * (-
sin(phi0));
46 double py = pxy *
cos(phi0);
47 double pz = pxy * tanl;
49 double e = sqrt( pxy*pxy + pz*pz +
mass*
mass );
51 return HepLorentzVector(px, py, pz, e);
60 HepLorentzVector pchange(0,0,0,0);
62 int nvalid= kaonid.size()+pionid.size();
66 HepSymMatrix Evx(3, 0);
67 double bx = 1E+6; Evx[0][0] = bx*bx;
68 double by = 1E+6; Evx[1][1] = by*by;
69 double bz = 1E+6; Evx[2][2] = bz*bz;
71 double xmass[5] = {0.000511, 0.105658, 0.139570,0.493677, 0.938272};
78 HepLorentzVector pold(0,0,0,0);
80 for(
int i=0; i<kaonid.size();++i){
83 pold+=
getp4(mdcKalTrk, 3);
88 for(
int i=0; i<pionid.size();++i){
91 pold+=
getp4(mdcKalTrk, 2);
93 vtxfit->
AddTrack(kaonid.size()+i, wtrk);
103 HepLorentzVector pnew(0,0,0,0);
105 for(
int i=0; i<nvalid;++i){
107 HepVector trk_val = HepVector(7,0);
109 HepLorentzVector P_trk(trk_val[0],trk_val[1],trk_val[2],trk_val[3]);
HepLorentzVector vfit(string channel, vector< int > kaonid, vector< int > pionid, HepPoint3D vx, EvtRecTrackIterator charged_begin)