MINT2
Public Member Functions | Static Protected Member Functions | Protected Attributes | Friends | List of all members
FitAmpIncoherentSumEvtGen Class Reference

#include <FitAmpIncoherentSumEvtGen.h>

Inheritance diagram for FitAmpIncoherentSumEvtGen:
MINT::IReturnRealForEvent< IDalitzEvent > IFastAmplitudeIntegrable ILookLikeFitAmpSum FitAmpList MINT::IReturnRealForEvent< IDalitzEvent > MINT::IReturnComplexForEvent< IDalitzEvent > IFastAmplitudeIntegrable MINT::IReturnRealForEvent< IDalitzEvent > FitAmpListBase MINT::IReturnRealForEvent< IDalitzEvent > MINT::IReturnComplexForEvent< IDalitzEvent >

Public Member Functions

 FitAmpIncoherentSumEvtGen (const DalitzEventPattern &pat, const char *fname=0, MINT::MinuitParameterSet *pset=0, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")
 
 FitAmpIncoherentSumEvtGen (const DalitzEventPattern &pat, MINT::MinuitParameterSet *pset, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")
 
 FitAmpIncoherentSumEvtGen (const DalitzEventPattern &pat, const std::string &prefix, const std::string &lineshapePrefix="", const std::string &opt="")
 
 FitAmpIncoherentSumEvtGen (const FitAmpIncoherentSumEvtGen &other)
 
 FitAmpIncoherentSumEvtGen (const FitAmpList &other)
 
virtual MINT::counted_ptr< FitAmpListBaseGetCloneSameFitParameters () const
 
virtual DalitzBoxSet makeBoxes (const DalitzEventPattern &pat, double nSigma=2)
 
virtual DalitzBWBoxSet makeBWBoxes (const DalitzEventPattern &pat, TRandom *rnd=gRandom)
 
double getVal (IDalitzEvent &evt)
 
double getVal (IDalitzEvent *evtPtr)
 
virtual void Gradient (IDalitzEvent &evt, std::vector< double > &grad, MINT::MinuitParameterSet *mps)
 
virtual bool useAnalyticGradient ()
 
virtual MINT::counted_ptr< IIntegrationCalculatormakeIntegrationCalculator ()
 
virtual MINT::counted_ptr< IntegCalculatormakeIntegCalculator ()
 
virtual MINT::counted_ptr< FitAmpPairListmakeFitAmpPairList ()
 
virtual double Prob (IDalitzEvent &evt)
 
virtual double RealVal (IDalitzEvent &evt)
 
virtual MINT::counted_ptr< MINT::IUnweightedEventGenerator< IDalitzEvent > > makeEventGenerator (const DalitzEventPattern &pat, TRandom *rnd=gRandom)
 
virtual ~FitAmpIncoherentSumEvtGen ()
 
void printLargestAmp (std::ostream &os=std::cout)
 
virtual void printLargestAmp (IDalitzEvent &evt, std::ostream &os=std::cout)
 
virtual void print (std::ostream &os=std::cout) const
 
virtual void printNonZero (std::ostream &os=std::cout) const
 
FitAmpIncoherentSumEvtGenoperator *= (double r)
 
FitAmpIncoherentSumEvtGenoperator *= (const std::complex< double > &z)
 
FitAmpIncoherentSumEvtGenoperator *= (const MINT::counted_ptr< MINT::IReturnComplex > &irc)
 
FitAmpIncoherentSumEvtGen operator * (double r) const
 
FitAmpIncoherentSumEvtGen operator * (const std::complex< double > &z) const
 
FitAmpIncoherentSumEvtGen operator * (const MINT::counted_ptr< MINT::IReturnComplex > &irc) const
 
FitAmpIncoherentSumEvtGenoperator= (const FitAmpIncoherentSumEvtGen &other)
 
FitAmpIncoherentSumEvtGenoperator= (const FitAmpList &other)
 
FitAmpIncoherentSumEvtGenoperator+= (const FitAmpIncoherentSumEvtGen &other)
 
FitAmpIncoherentSumEvtGen operator+ (const FitAmpIncoherentSumEvtGen &other) const
 
- Public Member Functions inherited from MINT::IReturnRealForEvent< IDalitzEvent >
virtual ~IReturnRealForEvent ()
 
- Public Member Functions inherited from IFastAmplitudeIntegrable
virtual std::complex< double > ComplexVal (IDalitzEvent &evt)
 
virtual ~IFastAmplitudeIntegrable ()
 
- Public Member Functions inherited from MINT::IReturnComplexForEvent< IDalitzEvent >
virtual ~IReturnComplexForEvent ()
 
- Public Member Functions inherited from ILookLikeFitAmpSum
virtual ~ILookLikeFitAmpSum ()
 
- Public Member Functions inherited from FitAmpList
 FitAmpList (const DalitzEventPattern &pat, const char *fname=0, MINT::MinuitParameterSet *pset=0, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")
 
 FitAmpList (const DalitzEventPattern &pat, MINT::MinuitParameterSet *pset, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")
 
 FitAmpList (const DalitzEventPattern &pat, const std::string &prefix, const std::string &lineshapePrefix="", const std::string &opt="")
 
 FitAmpList (const FitAmpList &other)
 
virtual MINT::MinuitParameterSetgetMPS ()
 
virtual MINT::counted_ptr< FitAmpListBaseGetCPConjugateSameFitParameters () const
 
virtual bool createAllAmps (const DalitzEventPattern &thePattern, const std::string &prefix="", const std::string &lineshapePrefix="")
 
virtual bool createAmpsFromFile ()
 
virtual ~FitAmpList ()
 
virtual void printAllAmps (std::ostream &os=std::cout) const
 
virtual void printAllAmps (IDalitzEvent &evt, std::ostream &os=std::cout)
 
virtual void printNonZeroWithValue (IDalitzEvent &evt, std::ostream &os=std::cout)
 
FitAmpListoperator *= (double r)
 
FitAmpListoperator *= (const std::complex< double > &z)
 
FitAmpListoperator *= (const MINT::counted_ptr< MINT::IReturnComplex > &irc)
 
FitAmpList operator * (double r) const
 
FitAmpList operator * (const std::complex< double > &z) const
 
FitAmpList operator * (const MINT::counted_ptr< MINT::IReturnComplex > &irc) const
 
FitAmpListoperator= (const FitAmpList &other)
 
FitAmpListoperator+= (const FitAmpList &other)
 
FitAmpList operator+ (const FitAmpList &other) const
 
- Public Member Functions inherited from FitAmpListBase
 FitAmpListBase ()
 
 FitAmpListBase (const FitAmpListBase &other)
 
 FitAmpListBase (const FitAmpListBase &other, std::string name)
 
virtual int addCopyWithSameFitParameters (const FitAmpListBase &other, double factor=1)
 
virtual int addCopyOfSubsetWithSameFitParameters (const FitAmpListBase &other, std::string name, double factor=1)
 
virtual bool addAmplitude (FitAmplitude *fa)
 
virtual int add (const FitAmpListBase &other, double factor=1)
 
virtual int addAsList (const FitAmpListBase &other, double factor=1)
 
virtual unsigned int size () const
 
virtual FitAmplitudegetAmpPtr (unsigned int i)
 
const FitAmplitudegetAmpPtr (unsigned int i) const
 
virtual bool CPConjugateSameFitParameters ()
 
virtual bool CConjugateFinalStateSameFitParameters ()
 
virtual MINT::counted_ptr< FitAmpListBaseGetCConjugateFinalStateSameFitParameters () const
 
virtual bool CConjugateInitialStateSameFitParameters ()
 
virtual MINT::counted_ptr< FitAmpListBaseGetCConjugateInitialStateSameFitParameters () const
 
virtual bool setLSameFitParameters (int L)
 
virtual MINT::counted_ptr< FitAmpListBaseGetDifferentLSameFitParameters (int L) const
 
virtual MINT::counted_ptr< FitAmpListBaseGetCloneOfSubsetSameFitParameters (std::string name) const
 
DalitzBoxSet makeBoxes (const DalitzEventPattern &pat, MINT::IReturnRealForEvent< IDalitzEvent > *pdf, double nSigma=2)
 
DalitzBWBoxSet makeBWBoxes (const DalitzEventPattern &pat, MINT::IReturnRealForEvent< IDalitzEvent > *pdf, TRandom *rnd=gRandom)
 
void setAllAmpsTo (const std::complex< double > z)
 
virtual ~FitAmpListBase ()
 
void setEfficiency (const MINT::counted_ptr< MINT::IReturnRealForEvent< IDalitzEvent > > &eff)
 
double efficiency (IDalitzEvent &evt)
 
virtual void multiply (double r)
 
virtual void multiply (const std::complex< double > &z)
 
virtual void multiply (const MINT::counted_ptr< MINT::IReturnComplex > irc)
 
virtual void multiply (MINT::counted_ptr< MINT::IReturnComplexForEvent< IDalitzEvent > > irc)
 
FitAmpListBaseoperator *= (double r)
 
FitAmpListBaseoperator *= (const std::complex< double > &z)
 
FitAmpListBaseoperator *= (const MINT::counted_ptr< MINT::IReturnComplex > &irc)
 
FitAmpListBase operator * (double r) const
 
FitAmpListBase operator * (const std::complex< double > &z) const
 
FitAmpListBase operator * (const MINT::counted_ptr< MINT::IReturnComplex > &irc) const
 
void normalizeAmps (DalitzEventList &evtList)
 
std::vector< double > normFactors (DalitzEventList &evtList)
 
void randomizeStartVals (int seed=0)
 
void randomizePhaseStartVals (int seed=0)
 
void setTag (int tag)
 
FitAmpListBaseoperator= (const FitAmpListBase &other)
 
FitAmpListBaseoperator+= (const FitAmpListBase &other)
 
FitAmpListBase operator+ (const FitAmpListBase &other) const
 

Static Protected Member Functions

static std::string IncPrefix ()
 

Protected Attributes

MINT::NamedParameter< int > _useAnalyticGradient
 
- Protected Attributes inherited from FitAmpList
DalitzEventPattern _pat
 
std::string _paraFName
 
MINT::MinuitParameterSet_minuitParaSet
 
std::string _opt
 
- Protected Attributes inherited from FitAmpListBase
std::vector< FitAmplitude * > _fitAmps
 
std::vector< MINT::counted_ptr< FitAmpListBase > > _fitAmpLists
 
MINT::counted_ptr< MINT::IReturnRealForEvent< IDalitzEvent > > _efficiency
 

Friends

class FitAmplitude
 

Additional Inherited Members

- Protected Member Functions inherited from MINT::IReturnRealForEvent< IDalitzEvent >
 IReturnRealForEvent ()
 
- Protected Member Functions inherited from MINT::IReturnComplexForEvent< IDalitzEvent >
 IReturnComplexForEvent ()
 
- Protected Member Functions inherited from FitAmpListBase
virtual void deleteAll ()
 

Detailed Description

Definition at line 19 of file FitAmpIncoherentSumEvtGen.h.

Constructor & Destructor Documentation

◆ FitAmpIncoherentSumEvtGen() [1/5]

FitAmpIncoherentSumEvtGen::FitAmpIncoherentSumEvtGen ( const DalitzEventPattern pat,
const char *  fname = 0,
MINT::MinuitParameterSet pset = 0,
const std::string &  prefix = "",
const std::string &  lineshapePrefix = "",
const std::string &  opt = "" 
)

Definition at line 20 of file FitAmpIncoherentSumEvtGen.cpp.

27  : FitAmpList(pat, fname, pset, FitAmpIncoherentSumEvtGen::IncPrefix()+ prefix, lineshapePrefix, opt)
28  , _useAnalyticGradient("useAnalyticGradient",0)
29 {
30  /*
31  //Important! Ensures everything is initialised
32  DalitzEventList eventTest;
33  eventTest.generatePhaseSpaceEvents(1,pat);
34  this->getVal(eventTest[0]);
35  */
36 }
MINT::NamedParameter< int > _useAnalyticGradient
FitAmpList(const DalitzEventPattern &pat, const char *fname=0, MINT::MinuitParameterSet *pset=0, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")
Definition: FitAmpList.cpp:19

◆ FitAmpIncoherentSumEvtGen() [2/5]

FitAmpIncoherentSumEvtGen::FitAmpIncoherentSumEvtGen ( const DalitzEventPattern pat,
MINT::MinuitParameterSet pset,
const std::string &  prefix = "",
const std::string &  lineshapePrefix = "",
const std::string &  opt = "" 
)

Definition at line 38 of file FitAmpIncoherentSumEvtGen.cpp.

44  : FitAmpList(pat, pset, FitAmpIncoherentSumEvtGen::IncPrefix() + prefix, lineshapePrefix, opt)
45  , _useAnalyticGradient("useAnalyticGradient",0)
46 {
47  /*
48  //Important! Ensures everything is initialised
49  DalitzEventList eventTest;
50  eventTest.generatePhaseSpaceEvents(1,pat);
51  this->getVal(eventTest[0]);
52  */
53 }
MINT::NamedParameter< int > _useAnalyticGradient
FitAmpList(const DalitzEventPattern &pat, const char *fname=0, MINT::MinuitParameterSet *pset=0, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")
Definition: FitAmpList.cpp:19

◆ FitAmpIncoherentSumEvtGen() [3/5]

FitAmpIncoherentSumEvtGen::FitAmpIncoherentSumEvtGen ( const DalitzEventPattern pat,
const std::string &  prefix,
const std::string &  lineshapePrefix = "",
const std::string &  opt = "" 
)

Definition at line 54 of file FitAmpIncoherentSumEvtGen.cpp.

59  : FitAmpList(pat, FitAmpIncoherentSumEvtGen::IncPrefix() + prefix, lineshapePrefix, opt)
60  , _useAnalyticGradient("useAnalyticGradient",0)
61 {
62  /*
63  //Important! Ensures everything is initialised
64  DalitzEventList eventTest;
65  eventTest.generatePhaseSpaceEvents(1,pat);
66  this->getVal(eventTest[0]);
67  */
68 }
MINT::NamedParameter< int > _useAnalyticGradient
FitAmpList(const DalitzEventPattern &pat, const char *fname=0, MINT::MinuitParameterSet *pset=0, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")
Definition: FitAmpList.cpp:19

◆ FitAmpIncoherentSumEvtGen() [4/5]

FitAmpIncoherentSumEvtGen::FitAmpIncoherentSumEvtGen ( const FitAmpIncoherentSumEvtGen other)

Definition at line 70 of file FitAmpIncoherentSumEvtGen.cpp.

74  , FitAmpList(other), _useAnalyticGradient("useAnalyticGradient",0)
75 {
76  /*
77  //Important! Ensures everything is initialised
78  DalitzEventList eventTest;
79  eventTest.generatePhaseSpaceEvents(1,_pat);
80  this->getVal(eventTest[0]);
81  */
82 }
MINT::NamedParameter< int > _useAnalyticGradient
FitAmpList(const DalitzEventPattern &pat, const char *fname=0, MINT::MinuitParameterSet *pset=0, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")
Definition: FitAmpList.cpp:19

◆ FitAmpIncoherentSumEvtGen() [5/5]

FitAmpIncoherentSumEvtGen::FitAmpIncoherentSumEvtGen ( const FitAmpList other)

Definition at line 84 of file FitAmpIncoherentSumEvtGen.cpp.

88  , FitAmpList(other), _useAnalyticGradient("useAnalyticGradient",0)
89 {
90  /*
91  //Important! Ensures everything is initialised
92  DalitzEventList eventTest;
93  eventTest.generatePhaseSpaceEvents(1,_pat);
94  this->getVal(eventTest[0]);
95  */
96 }
MINT::NamedParameter< int > _useAnalyticGradient
FitAmpList(const DalitzEventPattern &pat, const char *fname=0, MINT::MinuitParameterSet *pset=0, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")
Definition: FitAmpList.cpp:19

◆ ~FitAmpIncoherentSumEvtGen()

FitAmpIncoherentSumEvtGen::~FitAmpIncoherentSumEvtGen ( )
virtual

Definition at line 286 of file FitAmpIncoherentSumEvtGen.cpp.

286  {
287  deleteAll();
288 }
virtual void deleteAll()

Member Function Documentation

◆ GetCloneSameFitParameters()

counted_ptr< FitAmpListBase > FitAmpIncoherentSumEvtGen::GetCloneSameFitParameters ( ) const
virtual

Reimplemented from FitAmpList.

Definition at line 97 of file FitAmpIncoherentSumEvtGen.cpp.

97  {
98 // need to reform these one day...
99 // ... it all relies on the copy-constructur/=operator in FitAmpitude
100 // not copying the fit parameters, but just their pointers
101 // which will need to be reviewed.
102 //
103  bool dbThis=false;
104  if(dbThis) cout << "FitAmpSum::GetCloneSameFitParameters()" << endl;
105  /*
106  There'll be 'physical' copies of all Amplitudes, but the
107  FitParameters remain the same (pointers to the same
108  FitParameter Object). This is useful for the CP-con coding
109  as it is now, but perhaps a bit counter-intuitive. needs to
110  be reviewed at some point. This behaviour is defined in the
111  copy constructor of the FitAmplitude class.
112  */
113 
114  /*
115  counted_ptr<FitAmpIncoherentSumEvtGen>
116  newList(new FitAmpIncoherentSumEvtGen((IDalitzEventList*) this->getEventRecord()
117  , _paraFName.c_str(), _minuitParaSet));
118  */
120  newList->deleteAll();
121 
122  newList->add(*this);
123  if(dbThis) cout << "cloning FitAmpIncoherentSumEvtGen " << newList->size() << endl;
124  return newList;
125 }
FitAmpIncoherentSumEvtGen(const DalitzEventPattern &pat, const char *fname=0, MINT::MinuitParameterSet *pset=0, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")

◆ getVal() [1/2]

double FitAmpIncoherentSumEvtGen::getVal ( IDalitzEvent evt)

Definition at line 138 of file FitAmpIncoherentSumEvtGen.cpp.

138  {
139  bool dbthis=false;
140 
141  double sum(0);
142 
143  if(0 == this->size()){
146  }
147 
148  for(unsigned int i=0; i< this->size(); i++){
149  if(dbthis){
150  cout << "FitAmpIncoherentSumEvtGen::getVal()"
151  << "\n > for " << getAmpPtr(i)->theBareDecay().oneLiner()
152  << "\n > I get " << getAmpPtr(i)->getVal(evt)
153  << endl;
154  }
155  evt.setPermutationIndex(0);
156  sum += norm(this->getAmpPtr(i)->getNewOnePermutationsVal(evt));
157  evt.setPermutationIndex(1);
158  sum += norm(this->getAmpPtr(i)->getNewOnePermutationsVal(evt));
159  }
160 
161  if(dbthis) cout << "FitAmpIncoherentSumEvtGen::getVal(evt):"
162  << " returning this: " << sum
163  << endl;
164 
165  if(false && sum > 200){
166  cout << "large FitAmpIncoherentSumEvtGen " << sum
167  << " the largest amplitude is: "
168  << endl;
169  printLargestAmp();
170  }
171 
172  return efficiency(evt)*sum;
173 
174 }
virtual FitAmplitude * getAmpPtr(unsigned int i)
void printLargestAmp(std::ostream &os=std::cout)
virtual std::complex< double > getVal(IDalitzEvent &evt)
virtual void setPermutationIndex(int i)=0
DecayTree theBareDecay() const
Definition: FitAmplitude.h:166
double efficiency(IDalitzEvent &evt)
virtual const DalitzEventPattern & eventPattern() const =0
void oneLiner(std::stringstream &seam, int generation=0) const
Definition: DDTree.h:375
virtual unsigned int size() const
virtual bool createAllAmps(const DalitzEventPattern &thePattern, const std::string &prefix="", const std::string &lineshapePrefix="")
Definition: FitAmpList.cpp:125

◆ getVal() [2/2]

double FitAmpIncoherentSumEvtGen::getVal ( IDalitzEvent evtPtr)
inline

Definition at line 73 of file FitAmpIncoherentSumEvtGen.h.

73  {
74  if(0 == evtPtr) return 0;
75  return getVal(*evtPtr);
76  }
double getVal(IDalitzEvent &evt)

◆ Gradient()

void FitAmpIncoherentSumEvtGen::Gradient ( IDalitzEvent evt,
std::vector< double > &  grad,
MINT::MinuitParameterSet mps 
)
virtual

Reimplemented from IFastAmplitudeIntegrable.

Definition at line 176 of file FitAmpIncoherentSumEvtGen.cpp.

176  {
177 
178  for (unsigned int i=0; i<mps->size(); i++) {
179  if(mps->getParPtr(i)->hidden())continue;
180 
181  string name_i= mps->getParPtr(i)->name();
182  if(name_i.find("Inco")==std::string::npos)continue;
183  if(name_i.find("_Re")!=std::string::npos){
184  if(mps->getParPtr(i)->iFixInit() && mps->getParPtr(i+1)->iFixInit()){
185  i++;
186  continue;
187  }
188  //name_i.replace(name_i.find("Inco_"),5,"");
189  name_i.replace(name_i.find("_Re"),3,"");
190  for(unsigned int j=0; j< this->size(); j++){
191  if(A_is_in_B(name_i, this->getAmpPtr(j)->name())){
192  if(i+1 >= grad.size()){
193  cout << "WARNING in FitAmpIncoherentSumEvtGen::Gradient"
194  << " have to increase size of grad to avoid memory issues" << endl;
195  grad.resize(i+2);
196  }
197  double tmp = 2.*std::norm(this->getAmpPtr(j)->getValWithoutFitParameters(evt));
198  grad[i]= tmp * this->getAmpPtr(j)->AmpPhase().real();
199  grad[i+1]= tmp * this->getAmpPtr(j)->AmpPhase().imag();
200  i++;
201  break;
202  }
203  }
204  }
205  else if(mps->getParPtr(i)->iFixInit())continue;
206  else {
207  std::cout << "FitAmpIncoherentSumEvtGen::Gradient() called. Sorry, I don't know how to calculate the derivative with respect to the fit parameter " << mps->getParPtr(i)->name() << " ! Please implement me or set useAnalytic Gradient to 0 in your options file. I'll crash now. " << std::endl;
208  throw "crash";
209  }
210 
211  }
212 
213 }
std::complex< double > AmpPhase() const
Definition: FitAmplitude.h:153
virtual FitAmplitude * getAmpPtr(unsigned int i)
virtual int iFixInit() const =0
IMinuitParameter * getParPtr(unsigned int i)
unsigned int size() const
virtual const std::string & name() const =0
bool A_is_in_B(const std::string &a, const std::string &b)
Definition: Utils.cpp:34
virtual bool hidden() const =0
virtual unsigned int size() const

◆ IncPrefix()

std::string FitAmpIncoherentSumEvtGen::IncPrefix ( )
staticprotected

Definition at line 16 of file FitAmpIncoherentSumEvtGen.cpp.

16  {
17  return "Inco_";
18 }

◆ makeBoxes()

virtual DalitzBoxSet FitAmpIncoherentSumEvtGen::makeBoxes ( const DalitzEventPattern pat,
double  nSigma = 2 
)
inlinevirtual

Definition at line 63 of file FitAmpIncoherentSumEvtGen.h.

64  {
65  return FitAmpList::makeBoxes(pat, this, nSigma);}
DalitzBoxSet makeBoxes(const DalitzEventPattern &pat, MINT::IReturnRealForEvent< IDalitzEvent > *pdf, double nSigma=2)

◆ makeBWBoxes()

virtual DalitzBWBoxSet FitAmpIncoherentSumEvtGen::makeBWBoxes ( const DalitzEventPattern pat,
TRandom *  rnd = gRandom 
)
inlinevirtual

Implements ILookLikeFitAmpSum.

Definition at line 67 of file FitAmpIncoherentSumEvtGen.h.

68  {
69  return FitAmpList::makeBWBoxes(pat, this, rnd);}
DalitzBWBoxSet makeBWBoxes(const DalitzEventPattern &pat, MINT::IReturnRealForEvent< IDalitzEvent > *pdf, TRandom *rnd=gRandom)

◆ makeEventGenerator()

virtual MINT::counted_ptr<MINT::IUnweightedEventGenerator<IDalitzEvent> > FitAmpIncoherentSumEvtGen::makeEventGenerator ( const DalitzEventPattern pat,
TRandom *  rnd = gRandom 
)
inlinevirtual

Implements IFastAmplitudeIntegrable.

Definition at line 111 of file FitAmpIncoherentSumEvtGen.h.

111  {
113  ptr(new DalitzBWBoxSet(makeBWBoxes(pat, rnd)));
114  return ptr;
115  }
virtual DalitzBWBoxSet makeBWBoxes(const DalitzEventPattern &pat, TRandom *rnd=gRandom)

◆ makeFitAmpPairList()

counted_ptr< FitAmpPairList > FitAmpIncoherentSumEvtGen::makeFitAmpPairList ( )
virtual

Implements IFastAmplitudeIntegrable.

Definition at line 244 of file FitAmpIncoherentSumEvtGen.cpp.

244  {
246  for(unsigned int i=0; i < _fitAmps.size(); i++){
247  if(_fitAmps[i]->canBeIgnored()) continue;
248  l->addAmps( (_fitAmps[i]), (_fitAmps[i]));
249  }
250 
251  for(unsigned int i=0; i < _fitAmpLists.size(); i++){
252  l->append(_fitAmpLists[i]->makeFitAmpPairList());
253  }
254 
255  cout << "FitAmpIncoherentSumEvtGen: setting efficiency POINTER "
256  << " in integCalculator to "
257  << _efficiency.get();
258  if(0 == _efficiency.get()){
259  cout << " (0 means no pointer, 100% efficiency).";
260  }
261  cout << endl;
262 
263  l->setEfficiency(_efficiency);
264  return l;
265 }
MINT::counted_ptr< MINT::IReturnRealForEvent< IDalitzEvent > > _efficiency
virtual MINT::counted_ptr< FitAmpPairList > makeFitAmpPairList()
std::vector< FitAmplitude * > _fitAmps
std::vector< MINT::counted_ptr< FitAmpListBase > > _fitAmpLists
X * get() const
Definition: counted_ptr.h:123

◆ makeIntegCalculator()

counted_ptr< IntegCalculator > FitAmpIncoherentSumEvtGen::makeIntegCalculator ( )
virtual

Implements IFastAmplitudeIntegrable.

Definition at line 220 of file FitAmpIncoherentSumEvtGen.cpp.

220  {
222  for(unsigned int i=0; i < _fitAmps.size(); i++){
223  if(_fitAmps[i]->canBeIgnored()) continue;
224  l->addAmps( (_fitAmps[i]), (_fitAmps[i]));
225  }
226 
227  for(unsigned int i=0; i < _fitAmpLists.size(); i++){
228  l->append(_fitAmpLists[i]->makeIntegCalculator());
229  }
230 
231  cout << "FitAmpIncoherentSumEvtGen: setting efficiency POINTER "
232  << " in integCalculator to "
233  << _efficiency.get();
234  if(0 == _efficiency.get()){
235  cout << " (0 means no pointer, 100% efficiency).";
236  }
237  cout << endl;
238 
239  l->setEfficiency(_efficiency);
240  return l;
241 }
MINT::counted_ptr< MINT::IReturnRealForEvent< IDalitzEvent > > _efficiency
std::vector< FitAmplitude * > _fitAmps
virtual MINT::counted_ptr< IntegCalculator > makeIntegCalculator()
std::vector< MINT::counted_ptr< FitAmpListBase > > _fitAmpLists
X * get() const
Definition: counted_ptr.h:123

◆ makeIntegrationCalculator()

counted_ptr< IIntegrationCalculator > FitAmpIncoherentSumEvtGen::makeIntegrationCalculator ( )
virtual

Implements IFastAmplitudeIntegrable.

Definition at line 216 of file FitAmpIncoherentSumEvtGen.cpp.

◆ operator *() [1/3]

FitAmpIncoherentSumEvtGen FitAmpIncoherentSumEvtGen::operator * ( double  r) const

Definition at line 316 of file FitAmpIncoherentSumEvtGen.cpp.

316  {
317  FitAmpIncoherentSumEvtGen fas(*this);
318  fas.multiply(r);
319  return fas;
320 }

◆ operator *() [2/3]

FitAmpIncoherentSumEvtGen FitAmpIncoherentSumEvtGen::operator * ( const std::complex< double > &  z) const

◆ operator *() [3/3]

FitAmpIncoherentSumEvtGen FitAmpIncoherentSumEvtGen::operator * ( const MINT::counted_ptr< MINT::IReturnComplex > &  irc) const

Definition at line 326 of file FitAmpIncoherentSumEvtGen.cpp.

326  {
327  FitAmpIncoherentSumEvtGen fas(*this);
328  fas.multiply(irc);
329  return fas;
330 }

◆ operator *=() [1/3]

FitAmpIncoherentSumEvtGen & FitAmpIncoherentSumEvtGen::operator *= ( double  r)

Definition at line 303 of file FitAmpIncoherentSumEvtGen.cpp.

303  {
304  multiply(r);
305  return *this;
306 }
virtual void multiply(double r)

◆ operator *=() [2/3]

FitAmpIncoherentSumEvtGen& FitAmpIncoherentSumEvtGen::operator *= ( const std::complex< double > &  z)

◆ operator *=() [3/3]

FitAmpIncoherentSumEvtGen & FitAmpIncoherentSumEvtGen::operator *= ( const MINT::counted_ptr< MINT::IReturnComplex > &  irc)

Definition at line 311 of file FitAmpIncoherentSumEvtGen.cpp.

311  {
312  multiply(irc);
313  return *this;
314 }
virtual void multiply(double r)

◆ operator+()

FitAmpIncoherentSumEvtGen FitAmpIncoherentSumEvtGen::operator+ ( const FitAmpIncoherentSumEvtGen other) const

Definition at line 296 of file FitAmpIncoherentSumEvtGen.cpp.

296  {
297  FitAmpIncoherentSumEvtGen fas(*this);
298  fas.add(rhs);
299  return fas;
300 }

◆ operator+=()

FitAmpIncoherentSumEvtGen & FitAmpIncoherentSumEvtGen::operator+= ( const FitAmpIncoherentSumEvtGen other)

Definition at line 291 of file FitAmpIncoherentSumEvtGen.cpp.

291  {
292  add(other);
293  return *this;
294 }
virtual int add(const FitAmpListBase &other, double factor=1)

◆ operator=() [1/2]

FitAmpIncoherentSumEvtGen & FitAmpIncoherentSumEvtGen::operator= ( const FitAmpIncoherentSumEvtGen other)

Definition at line 127 of file FitAmpIncoherentSumEvtGen.cpp.

127  {
128  if(&other == this) return *this;
129  (FitAmpList)(*this) = (FitAmpList) (other);
130  return *this;
131 }
FitAmpList(const DalitzEventPattern &pat, const char *fname=0, MINT::MinuitParameterSet *pset=0, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")
Definition: FitAmpList.cpp:19

◆ operator=() [2/2]

FitAmpIncoherentSumEvtGen & FitAmpIncoherentSumEvtGen::operator= ( const FitAmpList other)

Definition at line 132 of file FitAmpIncoherentSumEvtGen.cpp.

132  {
133  if(&other == this) return *this;
134  (FitAmpIncoherentSumEvtGen)(*this) = other;
135  return *this;
136 }
FitAmpIncoherentSumEvtGen(const DalitzEventPattern &pat, const char *fname=0, MINT::MinuitParameterSet *pset=0, const std::string &prefix="", const std::string &lineshapePrefix="", const std::string &opt="")

◆ print()

void FitAmpIncoherentSumEvtGen::print ( std::ostream &  os = std::cout) const
virtual

Implements IFastAmplitudeIntegrable.

Definition at line 267 of file FitAmpIncoherentSumEvtGen.cpp.

267  {
268  os << "FitAmpIncoherentSumEvtGen::print\n====================";
269 
270  for(unsigned int i=0; i< this->size(); i++){
271  os << "\n\t" << this->getAmpPtr(i)->theBareDecay().oneLiner()
272  << endl;
273  }
274 }
virtual FitAmplitude * getAmpPtr(unsigned int i)
DecayTree theBareDecay() const
Definition: FitAmplitude.h:166
void oneLiner(std::stringstream &seam, int generation=0) const
Definition: DDTree.h:375
virtual unsigned int size() const

◆ printLargestAmp() [1/2]

void FitAmpIncoherentSumEvtGen::printLargestAmp ( std::ostream &  os = std::cout)

◆ printLargestAmp() [2/2]

virtual void FitAmpIncoherentSumEvtGen::printLargestAmp ( IDalitzEvent evt,
std::ostream &  os = std::cout 
)
inlinevirtual

Reimplemented from FitAmpList.

Definition at line 120 of file FitAmpIncoherentSumEvtGen.h.

120  {
121  FitAmpList::printLargestAmp(evt, os);}
virtual void printLargestAmp(IDalitzEvent &evt, std::ostream &os=std::cout)
Definition: FitAmpList.cpp:231

◆ printNonZero()

void FitAmpIncoherentSumEvtGen::printNonZero ( std::ostream &  os = std::cout) const
virtual

Reimplemented from FitAmpList.

Definition at line 275 of file FitAmpIncoherentSumEvtGen.cpp.

275  {
276  os << "FitAmpSum::print\n====================";
277 
278  for(unsigned int i=0; i < this->size(); i++){
279  if(this->getAmpPtr(i)->isZero()) continue;
280  os << "\n\t" << this->getAmpPtr(i)->theBareDecay().oneLiner()
281  << endl;
282  }
283 }
bool isZero() const
Definition: FitAmplitude.h:98
virtual FitAmplitude * getAmpPtr(unsigned int i)
DecayTree theBareDecay() const
Definition: FitAmplitude.h:166
void oneLiner(std::stringstream &seam, int generation=0) const
Definition: DDTree.h:375
virtual unsigned int size() const

◆ Prob()

virtual double FitAmpIncoherentSumEvtGen::Prob ( IDalitzEvent evt)
inlinevirtual

Definition at line 90 of file FitAmpIncoherentSumEvtGen.h.

90  {
91  return getVal(evt);
92  }
double getVal(IDalitzEvent &evt)

◆ RealVal()

virtual double FitAmpIncoherentSumEvtGen::RealVal ( IDalitzEvent evt)
inlinevirtual

Implements ILookLikeFitAmpSum.

Definition at line 100 of file FitAmpIncoherentSumEvtGen.h.

100  {
101  return Prob(evt);
102  }
virtual double Prob(IDalitzEvent &evt)

◆ useAnalyticGradient()

virtual bool FitAmpIncoherentSumEvtGen::useAnalyticGradient ( )
inlinevirtual

Reimplemented from IFastAmplitudeIntegrable.

Definition at line 79 of file FitAmpIncoherentSumEvtGen.h.

79 {return _useAnalyticGradient;}
MINT::NamedParameter< int > _useAnalyticGradient

Friends And Related Function Documentation

◆ FitAmplitude

friend class FitAmplitude
friend

Definition at line 126 of file FitAmpIncoherentSumEvtGen.h.

Member Data Documentation

◆ _useAnalyticGradient

MINT::NamedParameter<int> FitAmpIncoherentSumEvtGen::_useAnalyticGradient
protected

Definition at line 26 of file FitAmpIncoherentSumEvtGen.h.


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