BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtAmpAmpPdf< T > Class Template Reference

#include <EvtAmpAmpPdf.hh>

Inheritance diagram for EvtAmpAmpPdf< T >:

Public Member Functions

 EvtAmpAmpPdf ()
 EvtAmpAmpPdf (int type, const EvtAmplitude< T > &amp1, const EvtAmplitude< T > &amp2)
 EvtAmpAmpPdf (const EvtAmpAmpPdf< T > &other)
virtual ~EvtAmpAmpPdf ()
virtual EvtAmpAmpPdf< T > * clone () const
virtual double pdf (const T &p) const
Public Member Functions inherited from EvtPdf< T >
 EvtPdf ()
 EvtPdf (const EvtPdf &other)
virtual ~EvtPdf ()
double evaluate (const T &p) const
EvtPdfMax< T > findMax (const EvtPdf< T > &pc, int N)
EvtValError findGenEff (const EvtPdf< T > &pc, int N, int nFindMax)
void setItg (EvtValError itg)
EvtValError getItg () const
EvtValError getItg (int N) const
virtual EvtValError compute_integral () const
virtual EvtValError compute_integral (int N) const
EvtValError compute_mc_integral (const EvtPdf< T > &pc, int N)
EvtPredGen< EvtPdfGen< T >, EvtPdfPred< T > > accRejGen (const EvtPdf< T > &pc, int nMax, double factor=1.)
virtual T randomPoint ()

Additional Inherited Members

Protected Attributes inherited from EvtPdf< T >
EvtValError _itg

Detailed Description

template<class T>
class EvtAmpAmpPdf< T >

Definition at line 23 of file EvtAmpAmpPdf.hh.

Constructor & Destructor Documentation

◆ EvtAmpAmpPdf() [1/3]

template<class T>
EvtAmpAmpPdf< T >::EvtAmpAmpPdf ( )
inline

Definition at line 25 of file EvtAmpAmpPdf.hh.

25{}

Referenced by clone(), and EvtAmpAmpPdf().

◆ EvtAmpAmpPdf() [2/3]

template<class T>
EvtAmpAmpPdf< T >::EvtAmpAmpPdf ( int type,
const EvtAmplitude< T > & amp1,
const EvtAmplitude< T > & amp2 )
inline

Definition at line 26 of file EvtAmpAmpPdf.hh.

27 : EvtPdf<T>(), _type( type ), _amp1( amp1.clone() ), _amp2( amp2.clone() ) {}
virtual EvtAmpAmpPdf< T > * clone() const
EvtPdf()
Definition EvtPdf.hh:59

◆ EvtAmpAmpPdf() [3/3]

template<class T>
EvtAmpAmpPdf< T >::EvtAmpAmpPdf ( const EvtAmpAmpPdf< T > & other)
inline

Definition at line 28 of file EvtAmpAmpPdf.hh.

29 : EvtPdf<T>( other ), _type( other._type ), COPY_PTR( _amp1 ), COPY_PTR( _amp2 ) {}
#define COPY_PTR(X)
Definition EvtMacros.hh:15

◆ ~EvtAmpAmpPdf()

template<class T>
virtual EvtAmpAmpPdf< T >::~EvtAmpAmpPdf ( )
inlinevirtual

Definition at line 30 of file EvtAmpAmpPdf.hh.

30 {
31 delete _amp1;
32 delete _amp2;
33 }

Member Function Documentation

◆ clone()

template<class T>
virtual EvtAmpAmpPdf< T > * EvtAmpAmpPdf< T >::clone ( ) const
inlinevirtual

Implements EvtPdf< T >.

Definition at line 35 of file EvtAmpAmpPdf.hh.

35{ return new EvtAmpAmpPdf( *this ); }

Referenced by EvtAmpAmpPdf().

◆ pdf()

template<class T>
virtual double EvtAmpAmpPdf< T >::pdf ( const T & p) const
inlinevirtual

Implements EvtPdf< T >.

Definition at line 37 of file EvtAmpAmpPdf.hh.

37 {
38 EvtComplex amp1 = _amp1->evaluate( p );
39 EvtComplex amp2 = _amp2->evaluate( p );
40 EvtComplex pr = amp1 * conj( amp2 );
41
42 if ( _type == POSRE ) return real( pr ) > 0 ? real( pr ) : 0.;
43 if ( _type == NEGRE ) return real( pr ) < 0 ? -real( pr ) : 0.;
44 if ( _type == POSIM ) return imag( pr ) > 0 ? imag( pr ) : 0.;
45 if ( _type == NEGIM ) return imag( pr ) < 0 ? -imag( pr ) : 0.;
46
47 assert( 0 );
48 }
Evt3Rank3C conj(const Evt3Rank3C &t2)
double imag(const EvtComplex &c)
double evaluate(const T &p) const
Definition EvtPdf.hh:64

The documentation for this class was generated from the following file: