27 return a1.first < a2.first;
44 std::string longA = FitComplexPolar::makeAmpName(longestName);
45 std::string longP = FitComplexPolar::makePhaseName(longestName);
47 return (longA.size() > longP.size() ? longA : longP);
52 ofstream os(fname.c_str());
56 int nameFieldWidth = longestNameInList().size() +3;
58 FitParameter::printFormat(os, nameFieldWidth);
61 for(AmpInitMap::const_iterator it= ndl->
trees().begin();
62 it != ndl->
trees().end();
66 printList.push_back(*it);
69 sort(printList.begin(), printList.end(), printSorter);
71 for(AmpInitPairList::const_iterator it= printList.begin();
72 it != printList.end();
77 s =
"\"" + FitComplexPolar::makeAmpName(it->first) +
"\"";
78 s.resize(nameFieldWidth,
' ');
79 os <<
s <<
"\t" << FitParameter::getInitString() << endl;
81 s =
"\"" + FitComplexPolar::makePhaseName(it->first) +
"\"";
82 s.resize(nameFieldWidth,
' ');
83 os <<
s <<
"\t" << FitParameter::getInitString() << endl;
95 : _amp(treeWithOpts, this)
96 , _FitAmpPhase(
FitComplexMaker(treeWithOpts.prefix() + yourOwnNameWithoutPrefix, fname, pset, this
100 , _fitFraction(treeWithOpts.prefix() + yourOwnNameWithoutPrefix +
"_Frac", (double) 0, fname
103 , _name(treeWithOpts.prefix() + yourOwnNameWithoutPrefix)
117 : _amp(treeWithOpts, this)
118 , _FitAmpPhase(
FitComplexMaker(treeWithOpts.prefix() + yourOwnNameWithoutPrefix, (char*) 0, pset, this
122 , _fitFraction(treeWithOpts.prefix() + yourOwnNameWithoutPrefix +
"_Frac", (double) 0, (char*) 0
125 , _name(treeWithOpts.prefix() + yourOwnNameWithoutPrefix)
137 : _amp(treeWithOpts, this)
142 , _fitFraction(treeWithOpts.
uniqueName() +
"_Frac", (double) 0, fname
153 : _amp(treeWithOpts, this)
158 , _fitFraction(treeWithOpts.
uniqueName() +
"_Frac", (double) 0
167 ,
const std::string& prefix
168 ,
const std::string& lineshapePrefix
172 : _amp(
AmpInitialiser(StandardisedDecayTreeName, prefix, lineshapePrefix), this)
173 , _FitAmpPhase(
FitComplexMaker(prefix+StandardisedDecayTreeName, fname, pset, this
177 , _fitFraction(prefix+StandardisedDecayTreeName +
"_Frac", (double) 0
180 , _name(prefix+StandardisedDecayTreeName)
187 ,
const std::string& prefix
188 ,
const std::string& lineshapePrefix
191 : _amp(
AmpInitialiser(StandardisedDecayTreeName, prefix, lineshapePrefix), this)
192 , _FitAmpPhase(
FitComplexMaker(prefix+StandardisedDecayTreeName, (char*) 0, pset, this
196 , _fitFraction(prefix+StandardisedDecayTreeName +
"_Frac", (double) 0
199 , _name(prefix+StandardisedDecayTreeName)
208 , _amp(other._amp, this)
209 , _FitAmpPhase(other._FitAmpPhase)
210 , _fitFraction(other._fitFraction)
211 , _preFactors(other._preFactors)
296 if(0 == evt)
return 0;
std::complex< double > AmpPhase() const
std::complex< double > getOnePermutationsVal(IDalitzEvent &evt)
static void AutogenerateFitFile(const std::string &fname="protoFitAmplitudeFile.txt", const DalitzEventPattern &pat=DalitzEventPattern::NoPattern)
bool operator()(const AmpInitPair &a1, const AmpInitPair &a2)
FitAmplitude GetCConjugateFinalStateSameFitParameters() const
bool compatibleWithFinalState(const AmpInitialiser &InitContainsTree) const
FitAmplitude GetDifferentLSameFitParameters(int L) const
bool canBeIgnored() const
virtual std::complex< double > getVal(IDalitzEvent &evt)
bool CPConjugateSameFitParameters()
FitAmplitude(const FitAmplitude &other, IFitParRegister *newDaddy=0)
FitAmplitude & operator *=(double r)
MINT::counted_ptr< MINT::FitComplex > _FitAmpPhase
bool CConjugateInitialStateSameFitParameters()
virtual std::complex< double > getValWithoutFitParameters(IDalitzEvent &evt)
std::pair< std::string, AmpInitialiser > AmpInitPair
bool CConjugateFinalState()
MINT::ComplexProduct _preFactors
std::vector< AmpInitPair > AmpInitPairList
MINT::FitComplex & FitAmpPhase()
bool CConjugateFinalStateSameFitParameters()
bool setLSameFitParameters(int L)
MINT::NamedParameter< double > _fitFraction
MINT::ComplexProductForEvent< IDalitzEvent > _evt_dep_preFactors
static const DalitzEventPattern NoPattern
static NamedDecayTreeList * getMe(const std::string &printopt="printNever")
static std::string longestNameInList()
counted_ptr< FitComplex > FitComplexMaker(const std::string &name, const char *fname=0, MinuitParameterSet *pset=0, MINT::IFitParRegister *daddy=0, FitParameter::FIX_OR_WHAT fow=FitParameter::FIX, NamedParameterBase::VERBOSITY vb=NamedParameterBase::VERBOSE)
virtual std::complex< double > getNewOnePermutationsVal(IDalitzEvent &evt)
std::string anythingToString(const T &anything)
const AmpInitMap & trees(const std::string &opt="ALL") const
std::string getLongestName() const
std::ostream & operator<<(std::ostream &os, const FitAmplitude &fa)
FitAmplitude GetCPConjugateSameFitParameters() const
bool CConjugateInitialState()
FitAmplitude GetCConjugateInitialStateSameFitParameters() const
std::string uniqueName(const DecayTree &dt_in)
void print(std::ostream &os=std::cout) const