25 namespace JPP {
using namespace JFIT; }
42 __x( -std::numeric_limits<double>::max() ),
43 __y( -std::numeric_limits<double>::max() ),
44 __z( -std::numeric_limits<double>::max() ),
48 __t( -std::numeric_limits<double>::max() ),
49 __Q( -std::numeric_limits<double>::max() ),
83 const int status = -1) :
113 const int status = -1):
163 void move(
const double step,
const double velocity)
168 __t += step / velocity;
202 return (i >= 0 && i < (
int)
W.size());
225 double getW(
const int i,
const double value)
const
240 void setW(
const int i,
const double value)
242 if (i >= (
int)
W.size()) {
243 W.resize(i + 1, 0.0);
265 for (JHistory::const_reverse_iterator i = history.rbegin(); i != history.rend(); ++i) {
266 out <<
' ' << i->type;
271 out <<
"x " <<
FIXED(7,2) << fit.
getX() << endl;
272 out <<
"y " <<
FIXED(7,2) << fit.
getY() << endl;
273 out <<
"z " <<
FIXED(7,2) << fit.
getZ() << endl;
274 out <<
"dx " <<
FIXED(7,3) << fit.
getDX() << endl;
275 out <<
"dy " <<
FIXED(7,3) << fit.
getDY() << endl;
276 out <<
"dz " <<
FIXED(7,3) << fit.
getDZ() << endl;
278 out <<
"Q " <<
FIXED(12,5) << fit.
getQ() << endl;
279 out <<
"NDF " << setw(5) << fit.
getNDF() << endl;
281 out <<
"status " << fit.
getStatus() << endl;
283 for (
int i = 0; i != fit.
getN(); ++i) {
284 out <<
"W[" << i <<
"] = " <<
FIXED(10,5) << fit.
getW(i) << endl;
329 template<
class JPredicate_t>
332 this->erase(std::partition(this->begin(), this->end(), select), this->end());
347 out <<
"Event: " << endl;
349 for (JEvt::const_iterator fit = event.begin(); fit !=
event.end(); ++fit) {
friend std::ostream & operator<<(std::ostream &out, const JFit &fit)
Write fit results to output.
JFit(const JHistory &history, const double x, const double y, const double z, const double dx, const double dy, const double dz, const double t, const double Q, const int NDF, const double E=0.0, const int status=-1)
Constructor.
friend std::ostream & operator<<(std::ostream &out, const JEvt &event)
Write event to output.
void setE(const double E)
Set energy.
int getNDF() const
Get number of degrees of freedom.
void setW(const int i, const double value)
Set value.
int getN() const
Get number of values.
Structure to store the ToT mean and standard deviation of the hits produced by a nanobeacon in a sour...
Container for historical events.
This include file serves the purpose of hiding ROOT dependencies and circumphere namespace problems w...
Auxiliary class for a type holder.
Auxiliary data structure for floating point format specification.
Data structure for track fit results.
I/O formatting auxiliaries.
bool hasW(const int i) const
Check availability of value.
JROOT::JTreeParameters getTreeParameters(JLANG::JType< JFIT::JEvt >)
Get TTree parameters for given data type.
double getT() const
Get time.
double getX() const
Get X-position.
double getY() const
Get Y-position.
int getStatus() const
Get status of the fit; negative values should refer to a bad fit.
Data structure for TTree parameters.
JEvt()
Default constructor.
double getDZ() const
Get Z-slope.
double getQ() const
Get quality.
Data structure for set of track fit results.
double getZ() const
Get Z-position.
JFit & add(const JFitApplication_t &type)
Add event to history.
double getW(const int i) const
Get value.
double getW(const int i, const double value) const
Get value.
JFit(const JHistory &history, const double x, const double y, const double z, const int status=-1)
Constructor for storing position only.
double getDY() const
Get Y-slope.
void move(const double step, const double velocity)
Move vertex along this track with given velocity.
const JHistory & getHistory() const
Get history.
void partition(JPredicate_t select)
Select fits.
double getE() const
Get energy.
double getDX() const
Get X-slope.
JHistory & add(const JFitApplication_t &type)
Add event to history.
JFit()
Default constructor.