36 _exampleDecay->addDgtr(211, 113)->addDgtr(211,-211);
38 return *_exampleDecay;
42 return getExampleDecay();
48 _exampleDecay->addDgtr(211, 113)->addDgtr(211,-211);
49 _exampleDecay->getVal().setL(2);
51 return *_exampleDecay;
55 return getExampleDecay();
62 if(fsPS.size() < 3) fsPS.reserve(3);
63 for(
int i=0; i< theDecay(pat).nDgtr(); i++){
65 theDecay(pat).getDgtrTreePtr(i);
68 else if(dgtr->
getVal().
SVPAT() ==
"P") fsPS[0] = dgtr;
70 if(0==V || 0==fsPS[0]){
71 cout <<
"ERROR in SF_AtoVP1_VtoP2P3::parseTree" 72 <<
" Didn't find V or P1 " << V.
get() <<
", " << fsPS[0].get() << endl;
77 cout <<
"ERROR in SF_AtoVP1_VtoP2P3::parseTree" 78 <<
" V should have 2 daughters, but it says it has " 83 fsPS[1] = V->getDgtrTreePtr(0);
84 fsPS[2] = V->getDgtrTreePtr(1);
89 cout <<
"parsed Tree: V:\n" 92 for(
int i=0; i<3; i++){
93 cout <<
"fsPS[" << i <<
"]\n" 103 bool debugThis =
false;
105 if(! ( fsPS[0] && fsPS[1] && fsPS[2] )) parseTree(evt.
eventPattern());
107 TLorentzVector pV = p(1, evt) + p(2, evt);
108 TLorentzVector qV = p(1, evt) - p(2, evt);
109 TLorentzVector pA = p(0, evt) + p(1, evt) + p(2, evt);
111 double MassV = mRes(V, evt);
115 complex<double> sfm(LV.Dot(e.
Re()),LV.Dot(e.
Im()));
122 if(! ( fsPS[0] && fsPS[1] && fsPS[2]) )
return;
123 os <<
"spin factor SF_AtoVP1_VtoP2P3" 124 <<
"\n\t parsed tree " << theDecay().oneLiner()
125 <<
"\n like this:" << endl;
126 this->printParsing(os);
131 bool debugThis =
false;
133 if(! ( fsPS[0] && fsPS[1] && fsPS[2] )) parseTree(evt.
eventPattern());
135 TLorentzVector pV = p(1, evt) + p(2, evt);
136 TLorentzVector qV = p(1, evt) - p(2, evt);
137 TLorentzVector pA = p(0, evt) + p(1, evt) + p(2, evt);
138 TLorentzVector qA = p(0, evt) - pV;
140 double MassV = mRes(V, evt);
146 TLorentzVector tmp = LA.Contract(LV);
148 complex<double> sfm(tmp.Dot(e.Re()),tmp.Dot(e.Im()));
157 if(! ( fsPS[0] && fsPS[1] && fsPS[2]) )
return;
158 os <<
"spin factor SF_AtoVP1_VtoP2P3_D" 159 <<
"\n\t parsed tree " << theDecay().oneLiner()
160 <<
"\n like this:" << endl;
161 this->printParsing(os);
167 if(0==_exampleDecay){
169 _exampleDecay->addDgtr(211, 9010221)->addDgtr(211,-211);
171 return *_exampleDecay;
175 return getExampleDecay();
179 bool debugThis=
false;
181 if(fsPS.size() < 3) fsPS.reserve(3);
182 for(
int i=0; i< theDecay(pat).nDgtr(); i++){
184 theDecay(pat).getDgtrTreePtr(i);
187 else if(dgtr->
getVal().
SVPAT() ==
"P") fsPS[0] = dgtr;
189 if(0==S || 0==fsPS[0]){
190 cout <<
"ERROR in SF_AtoSP1_StoP2P3::parseTree" 191 <<
" Didn't find S or P1 " << S.
get() <<
", " << fsPS[0].get() << endl;
196 cout <<
"ERROR in SF_AtoSP1_StoP2P3::parseTree" 197 <<
" S should have 2 daughters, but it says it has " 202 fsPS[1] = S->getDgtrTreePtr(0);
203 fsPS[2] = S->getDgtrTreePtr(1);
208 cout <<
"parsed Tree: S:\n" 211 for(
int i=0; i<3; i++){
212 cout <<
"fsPS[" << i <<
"]\n" 222 bool debugThis =
false;
224 if(! ( fsPS[0] && fsPS[1] && fsPS[2] )) parseTree(evt.
eventPattern());
226 TLorentzVector pS = p(1, evt) + p(2, evt);
227 TLorentzVector pA = p(0, evt) + pS;
228 TLorentzVector qA = p(0, evt) - pS;
233 complex<double> sfm(LA.Dot(e.
Re()),LA.Dot(e.
Im()));
241 if(! ( fsPS[0] && fsPS[1] && fsPS[2]) )
return;
242 os <<
"spin factor SF_AtoSP1_StoP2P3" 243 <<
"\n\t parsed tree " << theDecay().oneLiner()
244 <<
"\n like this:" << endl;
245 this->printParsing(os);
251 if(0==_exampleDecay){
253 _exampleDecay->addDgtr(321, 113)->addDgtr(211,-211);
255 return *_exampleDecay;
259 return getExampleDecay();
263 bool debugThis=
false;
265 if(fsPS.size() < 3) fsPS.reserve(3);
266 for(
int i=0; i< theDecay(pat).nDgtr(); i++){
268 theDecay(pat).getDgtrTreePtr(i);
271 else if(dgtr->
getVal().
SVPAT() ==
"P") fsPS[0] = dgtr;
273 if(0==V0 || 0==fsPS[0]){
274 cout <<
"ERROR in SF_VtoV0P1_V0toP2P3::parseTree" 275 <<
" Didn't find V0 or P1 " << V0.
get() <<
", " << fsPS[0].get() << endl;
279 if(V0->nDgtr() != 2){
280 cout <<
"ERROR in SF_VtoV0P1_V0toP2P3::parseTree" 281 <<
" V0 should have 2 daughters, but it says it has " 282 << V0->
nDgtr() <<
"." 286 fsPS[1] = V0->getDgtrTreePtr(0);
287 fsPS[2] = V0->getDgtrTreePtr(1);
292 cout <<
"parsed Tree: S:\n" 295 for(
int i=0; i<3; i++){
296 cout <<
"fsPS[" << i <<
"]\n" 306 bool debugThis =
false;
308 if(! ( fsPS[0] && fsPS[1] && fsPS[2] )) parseTree(evt.
eventPattern());
310 TLorentzVector pV0 = p(1, evt) + p(2, evt);
311 TLorentzVector qV0 = p(1, evt) - p(2, evt);
312 TLorentzVector pV = p(0, evt) + pV0;
313 TLorentzVector qV = p(0, evt) - pV0;
328 if(! ( fsPS[0] && fsPS[1] && fsPS[2]) )
return;
329 os <<
"spin factor SF_VtoV0P1_V0toP2P3" 330 <<
"\n\t parsed tree " << theDecay().oneLiner()
331 <<
"\n like this:" << endl;
332 this->printParsing(os);
338 if(0==_exampleDecay){
340 _exampleDecay->addDgtr(443, 9010221)->addDgtr(211,-211);
342 return *_exampleDecay;
346 return getExampleDecay();
350 bool debugThis=
false;
352 if(fsPS.size() < 3) fsPS.reserve(3);
353 for(
int i=0; i< theDecay(pat).nDgtr(); i++){
355 theDecay(pat).getDgtrTreePtr(i);
358 else if(dgtr->
getVal().
SVPAT() ==
"V") fsPS[0] = dgtr;
360 if(0==S || 0==fsPS[0]){
361 cout <<
"ERROR in SF_VtoSV0_StoP2P3::parseTree" 362 <<
" Didn't find S or V0 " << S.
get() <<
", " << fsPS[0].get() << endl;
367 cout <<
"ERROR in SF_VtoSV0_StoP2P3::parseTree" 368 <<
" S should have 2 daughters, but it says it has " 373 fsPS[1] = S->getDgtrTreePtr(0);
374 fsPS[2] = S->getDgtrTreePtr(1);
379 cout <<
"parsed Tree: S:\n" 382 for(
int i=0; i<3; i++){
383 cout <<
"fsPS[" << i <<
"]\n" 393 bool debugThis =
false;
395 if(! ( fsPS[0] && fsPS[1] && fsPS[2] )) parseTree(evt.
eventPattern());
397 TLorentzVector pV0 = p(0, evt);
398 TLorentzVector pV = p(1, evt) + p(2, evt) + pV0;
411 if(! ( fsPS[0] && fsPS[1] && fsPS[2]) )
return;
412 os <<
"spin factor SF_VtoSV0_StoP2P3" 413 <<
"\n\t parsed tree " << theDecay().oneLiner()
414 <<
"\n like this:" << endl;
415 this->printParsing(os);
421 if(0==_exampleDecay){
423 _exampleDecay->addDgtr(321, 120553)->addDgtr(443,-211);
425 return *_exampleDecay;
429 return getExampleDecay();
433 bool debugThis=
false;
435 if(fsPS.size() < 3) fsPS.reserve(3);
436 for(
int i=0; i< theDecay(pat).nDgtr(); i++){
438 theDecay(pat).getDgtrTreePtr(i);
441 else if(dgtr->
getVal().
SVPAT() ==
"P") fsPS[1] = dgtr;
443 if(0==A || 0==fsPS[1]){
444 cout <<
"ERROR in SF_VtoAP1_AtoV0P2::parseTree" 445 <<
" Didn't find A or P1 " << A.
get() <<
", " << fsPS[1].get() << endl;
450 cout <<
"ERROR in SF_VtoAP1_AtoV0P2::parseTree" 451 <<
" A should have 2 daughters, but it says it has " 458 if(A->getDgtrTreePtr(0)->getVal().SVPAT() ==
"V") {
459 fsPS[0] = A->getDgtrTreePtr(0);
460 fsPS[2] = A->getDgtrTreePtr(1);
462 else if(A->getDgtrTreePtr(1)->getVal().SVPAT() ==
"V") {
463 fsPS[0] = A->getDgtrTreePtr(1);
464 fsPS[2] = A->getDgtrTreePtr(0);
467 if(0==fsPS[2] || 0==fsPS[0]){
468 cout <<
"ERROR in SF_VtoAP1_AtoV0P2::parseTree" 469 <<
" Didn't find V0 or P2 " << fsPS[0].get() <<
", " << fsPS[2].get() << endl;
476 cout <<
"parsed Tree: A:\n" 479 for(
int i=0; i<3; i++){
480 cout <<
"fsPS[" << i <<
"]\n" 490 bool debugThis =
false;
492 if(! ( fsPS[0] && fsPS[1] && fsPS[2] )) parseTree(evt.
eventPattern());
494 TLorentzVector pV0 = p(0, evt);
495 TLorentzVector pV = p(1, evt) + p(2, evt) + pV0;
496 TLorentzVector pA = p(2, evt) + pV0;
514 if(! ( fsPS[0] && fsPS[1] && fsPS[2]) )
return;
515 os <<
"spin factor SF_VtoAP1_AtoV0P2" 516 <<
"\n\t parsed tree " << theDecay().oneLiner()
517 <<
"\n like this:" << endl;
518 this->printParsing(os);
static const DecayTree & getExampleDecay()
virtual void printYourself(std::ostream &os=std::cout) const
virtual bool parseTree(const DalitzEventPattern &pat)
virtual const DecayTree & exampleDecay()
virtual void printYourself(std::ostream &os=std::cout) const
virtual const DecayTree & exampleDecay()
std::string SVPAT() const
virtual void printYourself(std::ostream &os=std::cout) const
virtual std::complex< double > getNewVal(IDalitzEvent &evt)
const TLorentzVector & Re() const
const ValueType & getVal() const
virtual std::complex< double > getNewVal(IDalitzEvent &evt)
static DecayTree * _exampleDecay
complex< double > Dot(const TLorentzVectorC &rhs)
static const DecayTree & getExampleDecay()
virtual const DecayTree & exampleDecay()
virtual bool parseTree(const DalitzEventPattern &pat)
static DecayTree * _exampleDecay
static const DecayTree & getExampleDecay()
virtual const DecayTree & exampleDecay()
virtual const DalitzEventPattern & eventPattern() const =0
virtual void printYourself(std::ostream &os=std::cout) const
virtual std::complex< double > getNewVal(IDalitzEvent &evt)
static DecayTree * _exampleDecay
const TLorentzVector & Im() const
virtual std::complex< double > getNewVal(IDalitzEvent &evt)
double LeviCivita(const TLorentzVector &p0, const TLorentzVector &p1, const TLorentzVector &p2, const TLorentzVector &p3)
static DecayTree * _exampleDecay
static DecayTree * _exampleDecay
virtual const DecayTree & exampleDecay()
static DecayTree * _exampleDecay
virtual bool parseTree(const DalitzEventPattern &pat)
DDTree< DecayTreeItem > DecayTree
virtual bool parseTree(const DalitzEventPattern &pat)
virtual const DecayTree & exampleDecay()
static const DecayTree & getExampleDecay()
virtual void printYourself(std::ostream &os=std::cout) const
static const DecayTree & getExampleDecay()
virtual std::complex< double > getNewVal(IDalitzEvent &evt)
virtual void printYourself(std::ostream &os=std::cout) const
virtual bool parseTree(const DalitzEventPattern &pat)
virtual std::complex< double > getNewVal(IDalitzEvent &evt)
static const DecayTree & getExampleDecay()