BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtMassAmp.cc
Go to the documentation of this file.
1//-----------------------------------------------------------------------
2// File and Version Information:
3// $Id: EvtMassAmp.cc,v 1.2 2011/01/06 22:57:56 pingrg Exp $
4//
5// Environment:
6// This software is part of the EvtGen package developed jointly
7// for the BaBar and CLEO collaborations. If you use all or part
8// of it, please give an appropriate acknowledgement.
9//
10// Copyright Information:
11// Copyright (C) 1998 Caltech, UCSB
12//
13// Module creator:
14// Alexei Dvoretskii, Caltech, 2001-2002.
15//-----------------------------------------------------------------------
16#include "EvtPatches.hh"
17
18#include "EvtMassAmp.hh"
19
22 , _prop( prop )
23 , _vd( vd )
24 , _vb( 0 )
25 , _useBirthFact( false )
26 , _useDeathFact( false )
27 , _useBirthFactFF( false )
28 , _useDeathFactFF( false )
29 , _fixUpMassForMax( false )
30 , _addfactor( 0. ) {}
31
33 : EvtAmplitude<EvtPoint1D>( other )
34 , _prop( other._prop )
35 , _vd( other._vd )
36 , _vb( other._vb ? new EvtTwoBodyVertex( *other._vb ) : 0 )
37 , _useBirthFact( other._useBirthFact )
38 , _useDeathFact( other._useDeathFact )
39 , _useBirthFactFF( other._useBirthFactFF )
40 , _useDeathFactFF( other._useDeathFactFF )
41 , _fixUpMassForMax( other._fixUpMassForMax )
42 , _addfactor( other._addfactor ) {}
43
45 if ( _vb ) delete _vb;
46}
47
49 // Modified vertex
50
51 double m = p.value();
52 // keep things from crashing..
53
54 if ( m < ( _vd.mA() + _vd.mB() ) ) return EvtComplex( 0., 0. );
55
56 EvtTwoBodyKine vd( _vd.mA(), _vd.mB(), m );
57
58 // Compute mass-dependent width for relativistic propagator
59
60 EvtPropBreitWignerRel bw( _prop.m0(), _prop.g0() * _vd.widthFactor( vd ) );
61 EvtComplex amp = bw.evaluate( m );
62
63 // Birth vertex factors
64
65 if ( _useBirthFact )
66 {
67
68 assert( _vb );
69 if ( ( m + _vb->mB() ) < _vb->mAB() )
70 {
71 EvtTwoBodyKine vb( m, _vb->mB(), _vb->mAB() );
72 double phsp = _vb->phaseSpaceFactor( vb, EvtTwoBodyKine::AB );
73 amp *= phsp;
74
75 if ( _fixUpMassForMax ) { amp *= sqrt( ( vb.p() / _vb->pD() ) ); }
76 if ( _useBirthFactFF )
77 {
78
79 assert( _vb );
80 amp *= _vb->formFactor( vb );
81 }
82 }
83 else
84 {
85 if ( _vb->L() != 0 ) amp = 0.;
86 }
87 }
88
89 // Decay vertex factors
90
91 if ( _useDeathFact )
92 {
93 amp *= _vd.phaseSpaceFactor( vd, EvtTwoBodyKine::AB );
94 if ( _fixUpMassForMax ) { amp *= sqrt( ( vd.p() / _vd.pD() ) ); }
95 }
96 if ( _useDeathFactFF ) amp *= _vd.formFactor( vd );
97
98 // AddFactorPn
99
100 if ( fabs( _addfactor ) > 0.00000001 )
101 { // addFactorPn, pingrg-2011-1-6
102 assert( _vb );
103 double phsp;
104 if ( ( m + _vb->mB() ) < _vb->mAB() )
105 {
106 EvtTwoBodyKine vb( m, _vb->mB(), _vb->mAB() );
107 phsp = vb.p( EvtTwoBodyKine::AB );
108 }
109 else
110 {
111 if ( _vb->L() != 0 ) phsp = 0.;
112 }
113
114 amp *= pow( phsp, _addfactor );
115 // std::cout<<"EvtMassAmp::addFactorPn= "<<pow(phsp,_addfactor)<<std::endl;
116 }
117
118 return amp;
119}
EvtComplex evaluate(const T &p) const
EvtMassAmp(const EvtPropBreitWignerRel &prop, const EvtTwoBodyVertex &vd)
Definition EvtMassAmp.cc:20
virtual ~EvtMassAmp()
Definition EvtMassAmp.cc:44
virtual EvtComplex amplitude(const EvtPoint1D &p) const
Definition EvtMassAmp.cc:48
double value() const
Definition EvtPoint1D.hh:25
double p(Index i=AB) const