43 #include "reportingUtils.hpp"
51 #ifdef USE_STD_COMPLEX_TREE_LEAFS
56 bool amplitudeTreeLeaf::_debug =
false;
59 amplitudeTreeLeaf::amplitudeTreeLeaf()
65 amplitudeTreeLeaf::Class()->IgnoreTObjectStreamer();
99 printErr <<
"cannot add " << *
this << endl
100 <<
"and " << amp << endl
101 <<
"because the two amplitudes have different incoherent sub-amplitudes. "
102 <<
"aborting." << endl;
115 printErr <<
"cannot subtract " << amp << endl
116 <<
"from " << *
this << endl
117 <<
"because the two amplitudes have different incoherent sub-amplitudes. "
118 <<
"aborting." << endl;
142 printErr <<
"cannot find subamp '" << subAmpLabel <<
"'. aborting." << endl;
145 return entry->second;
155 printErr <<
"subamp index " << subAmpIndex <<
" is out of range. aborting." << endl;
164 const unsigned int nmbSubAmps = subAmpLabels.size();
166 printWarn <<
"vector with subamp labels '" << subAmpLabels <<
"' has less than 2 entries. "
167 <<
"using single amplitude value." << endl;
169 vector<string> uniqueLabels = subAmpLabels;
170 sort(uniqueLabels.begin(), uniqueLabels.end());
171 uniqueLabels.erase(unique(uniqueLabels.begin(), uniqueLabels.end()), uniqueLabels.end());
172 if (uniqueLabels.size() < nmbSubAmps) {
173 printErr <<
"vector with subamp labels '" << subAmpLabels <<
"' contains dublicate entries. "
174 <<
"aborting." << endl;
186 out <<
"amplitude tree leaf:" << endl;
188 if (nmbSubAmps > 1) {
189 out <<
" number of incoherent sub-amps ... " << nmbSubAmps << endl;
190 out <<
" amplitude value(s):" << endl;
191 for (
unsigned int i = 0;
i < nmbSubAmps; ++
i)
194 }
else if (nmbSubAmps == 1)
197 out <<
" no amplitude value" << endl;