298 {
299
300
301
302 MsgStream log(
msgSvc(), name());
303 log << MSG::INFO << "in execute()" << endreq;
304
305 setFilterPassed(false);
306
307 SmartDataPtr<Event::EventHeader> eventHeader(eventSvc(),"/Event/EventHeader");
308 int runNo=eventHeader->runNumber();
309 int event=eventHeader->eventNumber();
310 log << MSG::DEBUG <<"runNo, evtnum = "
312 << event <<endreq;
313
315
316
318 log << MSG::INFO << "get event tag OK" << endreq;
319 log << MSG::DEBUG <<"ncharg, nneu, tottks = "
320 << evtRecEvent->totalCharged() << " , "
321 << evtRecEvent->totalNeutral() << " , "
322 << evtRecEvent->totalTracks() <<endreq;
323
324
325
327
328
329
330
331 if(evtRecEvent->totalNeutral()>100) {
332 return StatusCode::SUCCESS;
333 }
334
335 Vint iGood, ipip, ipim;
336 iGood.clear();
337 ipip.clear();
338 ipim.clear();
340 ppip.clear();
341 ppim.clear();
342
343 Hep3Vector xorigin(0,0,0);
344
345
347 Gaudi::svcLocator()->service("VertexDbSvc", vtxsvc);
351
352
353 xorigin.setX(dbv[0]);
354 xorigin.setY(dbv[1]);
355 xorigin.setZ(dbv[2]);
356 }
357
358 int nCharge = 0;
359 for(int i = 0; i < evtRecEvent->totalCharged(); i++){
361 if(!(*itTrk)->isMdcTrackValid()) continue;
362 if (!(*itTrk)->isMdcKalTrackValid()) continue;
364
365 double pch =mdcTrk->
p();
366 double x0 =mdcTrk->
x();
367 double y0 =mdcTrk->
y();
368 double z0 =mdcTrk->
z();
369 double phi0=mdcTrk->
helix(1);
370 double xv=xorigin.x();
371 double yv=xorigin.y();
372 double Rxy=fabs((x0-xv)*
cos(phi0)+(y0-yv)*
sin(phi0));
373
374 double m_vx0 = x0;
375 double m_vy0 = y0;
376 double m_vz0 = z0-xorigin.z();
377 double m_vr0 = Rxy;
378 double m_Vctc=z0/sqrt(Rxy*Rxy+z0*z0);
380
381
382
383 if(fabs(m_vz0) >= m_vz0cut) continue;
384 if(m_vr0 >= m_vr0cut) continue;
385
386 iGood.push_back((*itTrk)->trackId());
387 nCharge += mdcTrk->
charge();
388 }
389
390
391
392
393 int nGood = iGood.size();
394
395 log << MSG::DEBUG << "ngood, totcharge = " << nGood << " , " << nCharge << endreq;
396 if((nGood != 4)||(nCharge!=0)){
397 return StatusCode::SUCCESS;
398 }
399
401
403 iGam.clear();
404 for(int i = evtRecEvent->totalCharged(); i< evtRecEvent->totalTracks(); i++) {
406 if(!(*itTrk)->isEmcShowerValid()) continue;
408 Hep3Vector emcpos(emcTrk->
x(), emcTrk->
y(), emcTrk->
z());
409
410 double dthe = 200.;
411 double dphi = 200.;
412 double dang = 200.;
413 log << MSG::DEBUG << "liuf neu= " <<i <<endreq;
414 for(int j = 0; j < evtRecEvent->totalCharged(); j++) {
416 if(!(*jtTrk)->isExtTrackValid()) continue;
420 log << MSG::DEBUG << "liuf charge= " <<j <<endreq;
421
422 double angd = extpos.angle(emcpos);
423 double thed = extpos.theta() - emcpos.theta();
424 double phid = extpos.deltaPhi(emcpos);
425 thed = fmod(thed+CLHEP::twopi+CLHEP::twopi+
pi, CLHEP::twopi) - CLHEP::pi;
426 phid = fmod(phid+CLHEP::twopi+CLHEP::twopi+
pi, CLHEP::twopi) - CLHEP::pi;
427
428
429
430 if(angd < dang) {
431 dang = angd;
432 dthe = thed;
433 dphi = phid;
434 }
435 }
436 if(dang>=200) continue;
437 double eraw = emcTrk->
energy();
438 dthe = dthe * 180 / (CLHEP::pi);
439 dphi = dphi * 180 / (CLHEP::pi);
440 dang = dang * 180 / (CLHEP::pi);
441
442 double m_dthe = dthe;
443 double m_dphi = dphi;
444 double m_dang = dang;
445 double m_eraw = eraw;
446
447
448 log << MSG::DEBUG << "eraw dang= " << eraw << " , " <<dang <<"," <<i <<endreq;
449 if(eraw < m_energyThreshold) continue;
450 if(dang < m_gammaAngCut) continue;
451
452
453
454
455 iGam.push_back((*itTrk)->trackId());
456 }
457
458
459
460
461 int nGam = iGam.size();
462
463 log << MSG::DEBUG << "num Good Photon " << nGam << " , " <<evtRecEvent->totalNeutral()<<endreq;
464 if(nGam<2){
465 return StatusCode::SUCCESS;
466 }
467
469
470
471
472
473
474
475
476
478 pGam.clear();
479 for(int i = 0; i < nGam; i++) {
482 double eraw = emcTrk->
energy();
483 double phi = emcTrk->
phi();
484 double the = emcTrk->
theta();
485 HepLorentzVector
ptrk;
490
491
492
493 pGam.push_back(
ptrk);
494 }
495
496
497 for(int i = 0; i < nGood; i++) {
499 if (!(*itTrk)->isMdcTrackValid()) continue;
501 if (!(*itTrk)->isMdcKalTrackValid()) continue;
504 if(mdcKalTrk->
charge() >0 ) {
505 ipip.push_back(iGood[i]);
506 HepLorentzVector
ptrk;
507 ptrk.setPx(mdcKalTrk->
px());
508 ptrk.setPy(mdcKalTrk->
py());
509 ptrk.setPz(mdcKalTrk->
pz());
510 double p3 =
ptrk.mag();
512 ppip.push_back(
ptrk);
513 } else {
514 ipim.push_back(iGood[i]);
515 HepLorentzVector
ptrk;
516 ptrk.setPx(mdcKalTrk->
px());
517 ptrk.setPy(mdcKalTrk->
py());
518 ptrk.setPz(mdcKalTrk->
pz());
519 double p3 =
ptrk.mag();
521 ppim.push_back(
ptrk);
522 }
523 }
524
525
526 int npip = ipip.size();
527 int npim = ipim.size();
528 if(npip!=2||npim != 2) return SUCCESS;
529
530
531
532
534
535
536
537
538
539
540
541
542 HepLorentzVector pTot0(0.011*3.6862,0,0,3.6862);
543 HepLorentzVector pTrec1,pTrec2,pTrec3,pTrec4;
544 HepLorentzVector pTrecf;
545 double m_recjpsi1,m_recjpsi2,m_recjpsi3,m_recjpsi4,m_recppf;
546 double deljp1,deljp2,deljp3,deljp4;
547 pTrec1 = pTot0 - ppip[0] - ppim[0];
548 pTrec2 = pTot0 - ppip[0] - ppim[1];
549 pTrec3 = pTot0 - ppip[1] - ppim[0];
550 pTrec4 = pTot0 - ppip[1] - ppim[1];
551 m_recjpsi1 = pTrec1.m();
552 m_recjpsi2 = pTrec2.m();
553 m_recjpsi3 = pTrec3.m();
554 m_recjpsi4 = pTrec4.m();
555 deljp1=fabs(m_recjpsi1-3.097);
556 deljp2=fabs(m_recjpsi2-3.097);
557 deljp3=fabs(m_recjpsi3-3.097);
558 deljp4=fabs(m_recjpsi4-3.097);
559
560 int itmp,itmp1,itmp2;
561 HepLorentzVector ptmp,ptmp1,ptmp2;
562
563 pTrecf =pTrec1;
564 m_recppf=pTrec1.m();
565
566 if(deljp2<deljp1&&deljp2<deljp3&&deljp2<deljp4)
567 { itmp= ipim[1];
568 ipim[1]=ipim[0];
569 ipim[0]=itmp;
570
571 ptmp =ppim[1];
572 ppim[1]=ppim[0];
573 ppim[0]=ptmp;
574
575 pTrecf =pTrec2;
576 m_recppf=pTrec2.m();
577 }
578
579 if(deljp3<deljp1&&deljp3<deljp2&&deljp3<deljp4)
580 { itmp= ipip[1];
581 ipip[1]=ipip[0];
582 ipip[0]=itmp;
583
584 ptmp =ppip[1];
585 ppip[1]=ppip[0];
586 ppip[0]=ptmp;
587
588 pTrecf =pTrec3;
589 m_recppf=pTrec3.m();
590 }
591
592 if(deljp4<deljp1&&deljp4<deljp2&&deljp4<deljp3)
593 { itmp1= ipip[1];
594 ipip[1]=ipip[0];
595 ipip[0]=itmp1;
596 itmp2= ipim[1];
597 ipim[1]=ipim[0];
598 ipim[0]=itmp2;
599
600 ptmp1 =ppip[1];
601 ppip[1]=ppip[0];
602 ppip[0]=ptmp1;
603 ptmp2 =ppim[1];
604 ppim[1]=ppim[0];
605 ppim[0]=ptmp2;
606
607 pTrecf =pTrec4;
608 m_recppf=pTrec4.m();
609 }
610
611 if(fabs(m_recppf-3.097)>0.2) return SUCCESS;
612
613 log << MSG::DEBUG << "ngood track ID after jpsi = " << ipip[0] << " , "
614 << ipim[0]<< " , " << ipip[1] << " , " << ipim[1] << endreq;
616
617 HepLorentzVector ppi2_no1 = ppip[0] + ppim[0];
618 HepLorentzVector ppi2_no2 = ppip[1] + ppim[1];
619 HepLorentzVector ppi2_no3 = ppip[0] + ppim[1];
620 HepLorentzVector ppi2_no4 = ppip[1] + ppim[0];
621 HepLorentzVector p4pi_no = ppi2_no1+ ppi2_no2;
622
623 double emcTg1=0.0;
624 double emcTg2=0.0;
625 double emcTg3=0.0;
626 double emcTg4=0.0;
627 double laypi1=-1.0;
628 double laypi2=-1.0;
629 double laypi3=-1.0;
630 double laypi4=-1.0;
631
637
638 double phi01=mdcTrkp1->
helix(1);
639 double m_p1vx = mdcTrkp1->
x();
640 double m_p1vy = mdcTrkp1->
y();
641 double m_p1vz = mdcTrkp1->
z()-xorigin.z();
642 double m_p1vr = fabs((mdcTrkp1->
x()-xorigin.x())*
cos(phi01)+(mdcTrkp1->
y()-xorigin.y())*
sin(phi01));
643 double m_p1vct=
cos(mdcTrkp1->
theta());
644 double m_p1ptot=mdcKalTrkp1->
p();
645 double m_p1pxy=sqrt(mdcKalTrkp1->
px()*mdcKalTrkp1->
px()+mdcKalTrkp1->
py()*mdcKalTrkp1->
py());
646
647 if((*itTrkp1)->isEmcShowerValid()){
648 emcTg1=emcTrkp1->
energy();
649 }
650 if((*itTrkp1)->isMucTrackValid()){
652 }
653 double m_laypip1=laypi1;
654
660
661 double phi02=mdcTrkm1->
helix(1);
662 double m_m1vx = mdcTrkm1->
x();
663 double m_m1vy = mdcTrkm1->
y();
664 double m_m1vz = mdcTrkm1->
z()-xorigin.z();
665 double m_m1vr = fabs((mdcTrkm1->
x()-xorigin.x())*
cos(phi02)+(mdcTrkm1->
y()-xorigin.y())*
sin(phi02));
666 double m_m1vct=
cos(mdcTrkm1->
theta());
667 double m_m1ptot=mdcKalTrkm1->
p();
668 double m_m1pxy=sqrt(mdcKalTrkm1->
px()*mdcKalTrkm1->
px()+mdcKalTrkm1->
py()*mdcKalTrkm1->
py());
669
670 if((*itTrkm1)->isEmcShowerValid()){
671 emcTg2= emcTrkm1->
energy();
672 }
673 if((*itTrkm1)->isMucTrackValid()){
675 }
676 double m_laypim1=laypi2;
677
683
684 double phi03=mdcTrkp2->
helix(1);
685 double m_p2vx = mdcTrkp2->
x();
686 double m_p2vy = mdcTrkp2->
y();
687 double m_p2vz = mdcTrkp2->
z()-xorigin.z();
688 double m_p2vr = fabs((mdcTrkp2->
x()-xorigin.x())*
cos(phi03)+(mdcTrkp2->
y()-xorigin.y())*
sin(phi03));
689 double m_p2vct=
cos(mdcTrkp2->
theta());
690 double m_p2ptot=mdcKalTrkp2->
p();
691 double m_p2pxy=sqrt(mdcKalTrkp2->
px()*mdcKalTrkp2->
px()+mdcKalTrkp2->
py()*mdcKalTrkp2->
py());
692
693 if((*itTrkp2)->isEmcShowerValid()){
694 emcTg3= emcTrkp2->
energy();
695 }
696 if((*itTrkp2)->isMucTrackValid()){
698 }
699 double m_laypip2=laypi3;
700
706
707 double phi04=mdcTrkm2->
helix(1);
708 double m_m2vx = mdcTrkm2->
x();
709 double m_m2vy = mdcTrkm2->
y();
710 double m_m2vz = mdcTrkm2->
z()-xorigin.z();
711 double m_m2vr = fabs((mdcTrkm2->
x()-xorigin.x())*
cos(phi04)+(mdcTrkm2->
y()-xorigin.y())*
sin(phi04));
712 double m_m2vct=
cos(mdcTrkm2->
theta());
713 double m_m2ptot=mdcKalTrkm2->
p();
714 double m_m2pxy=sqrt(mdcKalTrkm2->
px()*mdcKalTrkm2->
px()+mdcKalTrkm2->
py()*mdcKalTrkm2->
py());
715
716 if((*itTrkm2)->isEmcShowerValid()){
717 emcTg4= emcTrkm2->
energy();
718 }
719 if((*itTrkm2)->isMucTrackValid()){
721 }
722 double m_laypim2=laypi4;
723
724 double m_emcTp1 =emcTg1;
725 double m_emcTm1 =emcTg2;
726 double m_emcTp2 =emcTg3;
727 double m_emcTm2 =emcTg4;
728
729 if(fabs(m_p1vz) >= m_vz1cut) return SUCCESS;
730 if(m_p1vr >= m_vr1cut) return SUCCESS;
731 if(fabs(m_p1vct)>=m_cthcut) return SUCCESS;
732
733 if(fabs(m_m1vz) >= m_vz1cut) return SUCCESS;
734 if(m_m1vr >= m_vr1cut) return SUCCESS;
735 if(fabs(m_m1vct)>=m_cthcut) return SUCCESS;
737
738 HepLorentzVector p4muonp = ppip[1];
739 HepLorentzVector p4muonm = ppim[1];
740 HepLorentzVector p4uu = pTrecf;
741
742
743 Hep3Vector p3jpsiUnit = (p4uu.vect()).
unit();
744 double jBeta = p4uu.beta();
745
746
747
748
749
750
751
752
753 HepLorentzVector pTot;
754 double minpi0=999.0;
755 for(int i = 0; i < nGam - 1; i++){
756 for(int j = i+1; j < nGam; j++) {
757 HepLorentzVector p2g = pGam[i] + pGam[j];
758 pTot = ppip[0] + ppim[0] + ppip[1] + ppim[1];
759 pTot += p2g;
760 if(fabs(p2g.m()-0.135)<minpi0){
761 minpi0 = fabs(p2g.m()-0.135);
762
763 double m_m2gg = p2g.m();
764
765 HepLorentzVector prho0_no = ppi2_no2;
766 HepLorentzVector prhop_no = ppip[1] + p2g;
767 HepLorentzVector prhom_no = ppim[1] + p2g;
768 HepLorentzVector prho0pi0 = ppi2_no2 + p2g;
769 HepLorentzVector frho1pi0 = ppi2_no1 + p2g;
770 HepLorentzVector frho2pi0 = ppi2_no3 + p2g;
771 HepLorentzVector frho3pi0 = ppi2_no4 + p2g;
772 HepLorentzVector prho0g1 = ppi2_no2 + pGam[i];
773 HepLorentzVector prho0g2 = ppi2_no2 + pGam[j];
774 HepLorentzVector frho1g1 = ppi2_no1 + pGam[i];
775 HepLorentzVector frho1g2 = ppi2_no1 + pGam[j];
776 HepLorentzVector frho2g1 = ppi2_no3 + pGam[i];
777 HepLorentzVector frho2g2 = ppi2_no3 + pGam[j];
778 HepLorentzVector frho3g1 = ppi2_no4 + pGam[i];
779 HepLorentzVector frho3g2 = ppi2_no4 + pGam[j];
780 HepLorentzVector p5pi_no = p4pi_no + p2g;
781
782
783 double m_prho0_no = prho0_no.m();
784 double m_prhop_no = prhop_no.m();
785 double m_prhom_no = prhom_no.m();
786 double m_prho0pi0 = prho0pi0.m();
787 double m_frho1pi0 = frho1pi0.m();
788 double m_frho2pi0 = frho2pi0.m();
789 double m_frho3pi0 = frho3pi0.m();
790 double m_prho0g1 = prho0g1.m();
791 double m_prho0g2 = prho0g2.m();
792 double m_frho1g1 = frho1g1.m();
793 double m_frho1g2 = frho1g2.m();
794 double m_frho2g1 = frho2g1.m();
795 double m_frho2g2 = frho2g2.m();
796 double m_frho3g1 = frho3g1.m();
797 double m_frho3g2 = frho3g2.m();
798 double m_p4pi_no = p4pi_no.m();
799 double m_p5pi_no = p5pi_no.m();
800 double m_mdcpx1=ppip[0].px();
801 double m_mdcpy1=ppip[0].py();
802 double m_mdcpz1=ppip[0].pz();
803 double m_mdcpe1=ppip[0].e();
804 double m_mdcpx2=ppim[0].px();
805 double m_mdcpy2=ppim[0].py();
806 double m_mdcpz2=ppim[0].pz();
807 double m_mdcpe2=ppim[0].e();
808 double m_mdcpx3=ppip[1].px();
809 double m_mdcpy3=ppip[1].py();
810 double m_mdcpz3=ppip[1].pz();
811 double m_mdcpe3=ppip[1].e();
812 double m_mdcpx4=ppim[1].px();
813 double m_mdcpy4=ppim[1].py();
814 double m_mdcpz4=ppim[1].pz();
815 double m_mdcpe4=ppim[1].e();
816 double m_mdcpxg1=pGam[i].px();
817 double m_mdcpyg1=pGam[i].py();
818 double m_mdcpzg1=pGam[i].pz();
819 double m_mdcpeg1=pGam[i].e();
820 double m_mdcpxg2=pGam[j].px();
821 double m_mdcpyg2=pGam[j].py();
822 double m_mdcpzg2=pGam[j].pz();
823 double m_mdcpeg2=pGam[j].e();
824 double m_etot = pTot.e();
825 double m_mrecjp1=m_recjpsi1;
826 double m_mrecjp2=m_recjpsi2;
827 double m_mrecjp3=m_recjpsi3;
828 double m_mrecjp4=m_recjpsi4;
829
830
831 }
832 }
833 }
835
836
837
838
839
840
842 HepSymMatrix Evx(3, 0);
843 double bx = 1E+6;
844 double by = 1E+6;
845 double bz = 1E+6;
846 Evx[0][0] = bx*bx;
847 Evx[1][1] = by*by;
848 Evx[2][2] = bz*bz;
849
853
856
857
858
859
860 RecMdcKalTrack *pipTrk1 = (*(evtRecTrkCol->begin()+ipip[0]))->mdcKalTrack();
861 RecMdcKalTrack *pimTrk1 = (*(evtRecTrkCol->begin()+ipim[0]))->mdcKalTrack();
862 RecMdcKalTrack *pipTrk2 = (*(evtRecTrkCol->begin()+ipip[1]))->mdcKalTrack();
863 RecMdcKalTrack *pimTrk2 = (*(evtRecTrkCol->begin()+ipim[1]))->mdcKalTrack();
864
870
874 if(!vtxfit->
Fit(0))
return SUCCESS;
876
878
881
883
884
885
886
887 int igbf1 = -1;
888 int igbf2 = -1;
889 HepLorentzVector pTgam1(0,0,0,0);
890 HepLorentzVector pTgam2(0,0,0,0);
891
892 if(m_test4C==1) {
893
894 HepLorentzVector
ecms(0.011*3.6862,0,0,3.6862);
895
896
897
898
902 double chisq = 9999.;
903 int ig11 = -1;
904 int ig21 = -1;
905 double chikk=9999.;
906 for(int i = 0; i < nGam-1; i++) {
907 RecEmcShower *g1Trk = (*(evtRecTrkCol->begin()+iGam[i]))->emcShower();
908 for(int j = i+1; j < nGam; j++) {
909 RecEmcShower *g2Trk = (*(evtRecTrkCol->begin()+iGam[j]))->emcShower();
919 bool oksq = kmfit->
Fit();
920 if(oksq&&kmfit->
chisq()<chikk) {
921 chikk = kmfit->
chisq();
922 }
923 }
924 }
926
927
928
929
930
931 chisq = 9999.;
932 int ig1 = -1;
933 int ig2 = -1;
934 for(int i = 0; i < nGam-1; i++) {
935 RecEmcShower *g1Trk = (*(evtRecTrkCol->begin()+iGam[i]))->emcShower();
936 for(int j = i+1; j < nGam; j++) {
937 RecEmcShower *g2Trk = (*(evtRecTrkCol->begin()+iGam[j]))->emcShower();
947 bool oksq = kmfit->
Fit();
948 if(oksq) {
949 double chi2 = kmfit->
chisq();
950 if(chi2 < chisq) {
951 chisq = chi2;
952 ig1 = iGam[i];
953 ig2 = iGam[j];
954 igbf1 = iGam[i];
955 igbf2 = iGam[j];
956 pTgam1=pGam[i];
957 pTgam2=pGam[j];
958 }
959 }
960 }
961 }
962
963
964 if(chisq > 200) return SUCCESS;
966
967
969 jGood.clear();
970 jGood.push_back(ipip[0]);
971 jGood.push_back(ipim[0]);
972 jGood.push_back(ipip[1]);
973 jGood.push_back(ipim[1]);
974
975
976
978 jGgam.clear();
979 jGgam.push_back(igbf1);
980 jGgam.push_back(igbf2);
981
982 double chi1_pp=9999.0;
983
984 RecEmcShower *g1Trk = (*(evtRecTrkCol->begin()+ig1))->emcShower();
985 RecEmcShower *g2Trk = (*(evtRecTrkCol->begin()+ig2))->emcShower();
994 bool oksq = kmfit->
Fit();
995 if(oksq) {
996 chi1_pp = kmfit->
chisq();
997 HepLorentzVector ppi0 = kmfit->
pfit(4) + kmfit->
pfit(5);
998 HepLorentzVector prho0= kmfit->
pfit(2) + kmfit->
pfit(3);
999 HepLorentzVector prhop= kmfit->
pfit(2) + ppi0;
1000 HepLorentzVector prhom= kmfit->
pfit(3) + ppi0;
1001 HepLorentzVector pjjj = prho0 + ppi0;
1002
1003 HepLorentzVector p2pi1=kmfit->
pfit(0) + kmfit->
pfit(1);
1004 HepLorentzVector f2pi1g1= p2pi1 + kmfit->
pfit(4);
1005 HepLorentzVector f2pi1g2= p2pi1 + kmfit->
pfit(5);
1006 HepLorentzVector f2pi1pi0=p2pi1 + ppi0;
1007
1008 HepLorentzVector t2pi2g1= prho0 + kmfit->
pfit(4);
1009 HepLorentzVector t2pi2g2= prho0 + kmfit->
pfit(5);
1010
1011 HepLorentzVector p2pi3=kmfit->
pfit(0) + kmfit->
pfit(3);
1012 HepLorentzVector f2pi3g1= p2pi3 + kmfit->
pfit(4);
1013 HepLorentzVector f2pi3g2= p2pi3 + kmfit->
pfit(5);
1014 HepLorentzVector f2pi3pi0=p2pi3 + ppi0;
1015
1016 HepLorentzVector p2pi4=kmfit->
pfit(1) + kmfit->
pfit(2);
1017 HepLorentzVector f2pi4g1= p2pi4 + kmfit->
pfit(4);
1018 HepLorentzVector f2pi4g2= p2pi4 + kmfit->
pfit(5);
1019 HepLorentzVector f2pi4pi0=p2pi4 + ppi0;
1020
1021 HepLorentzVector p4pi= p2pi1 + prho0;
1022 HepLorentzVector p4pig1= p4pi + kmfit->
pfit(4);
1023 HepLorentzVector p4pig2= p4pi + kmfit->
pfit(5);
1024 HepLorentzVector ppptot= p4pi + ppi0;
1025
1026
1027 HepLorentzVector be4cpi0= pTgam1 + pTgam2;
1028 HepLorentzVector be4c_ppi1 = ppip[0] + ppim[0];
1029 HepLorentzVector be4c_ppi2 = ppip[1] + ppim[1];
1030 HepLorentzVector be4cjp= be4cpi0 + be4c_ppi2;
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1426
1427 }
1428 }
1429
1430
1431
1432
1433
1434
1435
1436 setFilterPassed(true);
1437
1438 (*(evtRecTrkCol->begin()+ipip[0]))->setPartId(2);
1439 (*(evtRecTrkCol->begin()+ipim[0]))->setPartId(2);
1440 (*(evtRecTrkCol->begin()+ipip[1]))->setPartId(2);
1441 (*(evtRecTrkCol->begin()+ipim[1]))->setPartId(2);
1442
1443
1444 return StatusCode::SUCCESS;
1445}
EvtRecTrackCol::iterator EvtRecTrackIterator
*******INTEGER m_nBinMax INTEGER m_NdiMax !No of bins in histogram for cell exploration division $ !Last vertex $ !Last active cell $ !Last cell in buffer $ !No of sampling when dividing cell $ !No of function total $ !Flag for random ceel for $ !Flag for type of for WtMax $ !Flag which decides whether vertices are included in the sampling $ entire domain is hyp !Maximum effective eevents per saves r n generator level $ !Flag for chat level in !Latex Output unit
std::vector< HepLorentzVector > Vp4
double sin(const BesAngle a)
double cos(const BesAngle a)
const Hep3Vector emcPosition() const
const int emcVolumeNumber() const
static void setPidType(PidType pidType)
const double theta() const
const HepVector helix() const
......
virtual bool isVertexValid()=0
virtual double * SigmaPrimaryVertex()=0
virtual double * PrimaryVertex()=0
static KinematicFit * instance()
void setDynamicerror(const bool dynamicerror=1)
void AddFourMomentum(int number, HepLorentzVector p4)
HepLorentzVector pfit(int n) const
const HepVector & getZHelix() const
const HepSymMatrix & getZError() const
HepSymMatrix & getZErrorK()
void AddTrack(const int number, const double mass, const RecMdcTrack *trk)
WTrackParameter wtrk(int n) const
void AddVertex(int number, VertexParameter vpar, std::vector< int > lis)
static VertexFit * instance()
void setEvx(const HepSymMatrix &eVx)
void setVx(const HepPoint3D &vx)
_EXTERN_ std::string EvtRecEvent
_EXTERN_ std::string EvtRecTrackCol