BOSS 7.1.2
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 Member Functions inherited from EvtPdf< T >
- Protected Attributes inherited from EvtPdf< T >
EvtValError _itg
 

Detailed Description

template<class T>
class EvtAmpAmpPdf< T >

Definition at line 24 of file EvtAmpAmpPdf.hh.

Constructor & Destructor Documentation

◆ EvtAmpAmpPdf() [1/3]

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

Definition at line 27 of file EvtAmpAmpPdf.hh.

27{}

Referenced by EvtAmpAmpPdf< T >::clone().

◆ EvtAmpAmpPdf() [2/3]

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

Definition at line 28 of file EvtAmpAmpPdf.hh.

29 : EvtPdf<T>(), _type(type), _amp1(amp1.clone()), _amp2(amp2.clone())
30 {}
virtual EvtAmplitude< T > * clone() const =0
EvtPdf()
Definition EvtPdf.hh:60

◆ EvtAmpAmpPdf() [3/3]

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

Definition at line 31 of file EvtAmpAmpPdf.hh.

32 : EvtPdf<T>(other), _type(other._type), COPY_PTR(_amp1), COPY_PTR(_amp2)
33 {}
#define COPY_PTR(X)
Definition EvtMacros.hh:15
Index other(Index i, Index j)

◆ ~EvtAmpAmpPdf()

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

Definition at line 34 of file EvtAmpAmpPdf.hh.

35 {
36 delete _amp1;
37 delete _amp2;
38 }

Member Function Documentation

◆ clone()

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

Implements EvtPdf< T >.

Definition at line 40 of file EvtAmpAmpPdf.hh.

40{ return new EvtAmpAmpPdf(*this); }

◆ pdf()

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

Implements EvtPdf< T >.

Definition at line 42 of file EvtAmpAmpPdf.hh.

43 {
44 EvtComplex amp1 = _amp1->evaluate(p);
45 EvtComplex amp2 = _amp2->evaluate(p);
46 EvtComplex pr = amp1 * conj(amp2);
47
48 if(_type == POSRE) return real(pr) > 0 ? real(pr) : 0.;
49 if(_type == NEGRE) return real(pr) < 0 ? -real(pr) : 0.;
50 if(_type == POSIM) return imag(pr) > 0 ? imag(pr) : 0.;
51 if(_type == NEGIM) return imag(pr) < 0 ? -imag(pr) : 0.;
52
53 assert(0);
54 }
Evt3Rank3C conj(const Evt3Rank3C &t2)
@ NEGRE
@ POSIM
@ POSRE
@ NEGIM
double imag(const EvtComplex &c)

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