1 #include "EvtGenBase/EvtPatches.hh"
2 /*******************************************************************************
3 * Project: BaBar detector at the SLAC PEP-II B-factory
5 * File: $Id: EvtTwoBodyVertex.cc,v 1.6 2004/12/21 19:58:50 ryd Exp $
6 * Author: Alexei Dvoretskii, dvoretsk@slac.stanford.edu, 2001-2002
8 * Copyright (C) 2002 Caltech
9 *******************************************************************************/
14 #include "EvtGenBase/EvtMacros.hh"
15 #include "EvtGenBase/EvtTwoBodyVertex.hh"
20 // Default ctor can sometimes be useful
22 EvtTwoBodyVertex::EvtTwoBodyVertex()
23 : _LL(0), _p0(0), _f(0)
26 EvtTwoBodyVertex::EvtTwoBodyVertex(double mA, double mB, double mAB, int L)
27 : _kine(), _LL(L), _p0(0), _f(0)
29 // Kinematics is initialized only if the decay is above threshold
33 _kine = EvtTwoBodyKine(mA,mB,mAB);
39 EvtTwoBodyVertex::EvtTwoBodyVertex(const EvtTwoBodyVertex& other)
40 : _kine(other._kine), _LL(other._LL), _p0(other._p0),
41 _f( (other._f) ? new EvtBlattWeisskopf(*other._f) : 0 )
44 EvtTwoBodyVertex::~EvtTwoBodyVertex()
50 void EvtTwoBodyVertex::set_f(double R)
53 _f = new EvtBlattWeisskopf(_LL,R,_p0);
57 double EvtTwoBodyVertex::widthFactor(EvtTwoBodyKine x) const
62 double ff = formFactor(x);
63 double factor = pow(p1/_p0,2*_LL+1)*mAB()/x.mAB() * ff * ff;
69 double EvtTwoBodyVertex::phaseSpaceFactor(EvtTwoBodyKine x,EvtTwoBodyKine::Index i) const
72 double factor = pow(p1,_LL);
76 double EvtTwoBodyVertex::formFactor(EvtTwoBodyKine x) const
89 void EvtTwoBodyVertex::print(ostream& os) const
91 os << " mA = " << mA() << endl;
92 os << " mB = " << mB() << endl;
93 os << "mAB = " << mAB() << endl;
94 os << " L = " << _LL << endl;
95 os << " p0 = " << _p0 << endl;
99 ostream& operator<<(ostream& os, const EvtTwoBodyVertex& v)