1 //--------------------------------------------------------------------------
4 // This software is part of the EvtGen package developed jointly
5 // for the BaBar and CLEO collaborations. If you use all or part
6 // of it, please give an appropriate acknowledgement.
8 // Copyright Information: See EvtGen/COPYRIGHT
9 // Copyright (C) 1998 Caltech, UCSB
11 // Module: EvtCBTo3piP00.cc
13 // Description: Routine to decay B+/-->pi0 pi0 pi+/-
14 // and has CP violation.
16 // Modification history:
18 // RYD,Versille May 6, 1997 Module created
20 //------------------------------------------------------------------------
22 #include "EvtGenBase/EvtPatches.hh"
24 #include "EvtGenBase/EvtParticle.hh"
25 #include "EvtGenBase/EvtGenKine.hh"
26 #include "EvtGenBase/EvtPDL.hh"
27 #include "EvtGenBase/EvtReport.hh"
28 #include "EvtGenModels/EvtCBTo3piP00.hh"
31 //Below you will have do modify the declaration to be appropriate
32 //for your new routine for the calculation of the amplitude
36 extern void EVT3PIONSP00(double *,int *,
40 double *,double *,double *,double *);
44 extern void evt3pionsp00_(double *,int *,
48 double *,double *,double *,double *);
52 EvtCBTo3piP00::~EvtCBTo3piP00() {}
54 std::string EvtCBTo3piP00::getName(){
61 EvtDecayBase* EvtCBTo3piP00::clone(){
63 return new EvtCBTo3piP00;
67 void EvtCBTo3piP00::init(){
69 // check that there are 1 argument
73 checkSpinParent(EvtSpinType::SCALAR);
75 checkSpinDaughter(0,EvtSpinType::SCALAR);
76 checkSpinDaughter(1,EvtSpinType::SCALAR);
77 checkSpinDaughter(2,EvtSpinType::SCALAR);
83 void EvtCBTo3piP00::initProbMax(){
91 void EvtCBTo3piP00::decay( EvtParticle *p ){
93 //added by Lange Jan4,2000
94 static EvtId BM=EvtPDL::getId("B-");
95 static EvtId BP=EvtPDL::getId("B+");
97 EvtParticle *pi1,*pi2,*pi3;
99 p->makeDaughters(getNDaug(),getDaugs());
105 double alpha = getArg(0);
117 double p4pi1[4],p4Gamma11[4],p4Gamma12[4];
118 double p4Gamma21[4],p4Gamma22[4];
120 double realA,imgA,realbarA,imgbarA;
122 evt3pionsp00_(&alpha,&iset,
126 &realA,&imgA,&realbarA,&imgbarA);
128 p4[0].set(p4pi1[3],p4pi1[0],p4pi1[1],p4pi1[2]);
129 p4[1].set(p4Gamma11[3]+p4Gamma12[3],
130 p4Gamma11[0]+p4Gamma12[0],
131 p4Gamma11[1]+p4Gamma12[1],
132 p4Gamma11[2]+p4Gamma12[2]);
133 p4[2].set(p4Gamma21[3]+p4Gamma22[3],
134 p4Gamma21[0]+p4Gamma22[0],
135 p4Gamma21[1]+p4Gamma22[1],
136 p4Gamma21[2]+p4Gamma22[2]);
138 pi1->init( getDaug(0), p4[0] );
139 pi2->init( getDaug(1), p4[1] );
140 pi3->init( getDaug(2), p4[2] );
142 EvtComplex A(realA,imgA);
143 EvtComplex Abar(realbarA, imgbarA);