Jpp test-rotations-old
the software that should make you happy
Loading...
Searching...
No Matches
JMuonStartParameters_t.hh
Go to the documentation of this file.
1#ifndef __JRECONSTRUCTION__JMUONSTARTPARAMETERS__
2#define __JRECONSTRUCTION__JMUONSTARTPARAMETERS__
3
4#include <limits>
5
6#include <TROOT.h>
7#include <TObject.h>
8
9/**
10 * \author mdejong
11 */
12
13namespace JRECONSTRUCTION {}
14namespace JPP { using namespace JRECONSTRUCTION; }
15
16namespace JRECONSTRUCTION
17{
18 /**
19 * Data structure for fit parameters.
20 */
22 public TObject
23 {
24 /**
25 * Default constructor.
26 */
28 {
29 this->reset();
30 }
31
32 /**
33 * Virtual destructor.
34 */
36 {}
37
38 /**
39 * Reset fit parameters.
40 */
41 void reset()
42 {
43 roadWidth_m = std::numeric_limits<double>::max();
44 R_Hz = 6.0e3;
46 TMin_ns = -25.0;
47 TMax_ns = +75.0;
48 Pmin1 = 0.0;
49 Pmin2 = 0.0;
50 Nmax2 = 2;
51 }
52
53 /**
54 * Equality
55 *
56 * \param parameters fit parameters
57 * \return true if equals; else false
58 */
59 bool equals(const JMuonStartParameters_t& parameters) const
60 {
61 return (this->roadWidth_m == parameters.roadWidth_m &&
62 this->R_Hz == parameters.R_Hz &&
63 this->numberOfPrefits == parameters.numberOfPrefits &&
64 this->TMin_ns == parameters.TMin_ns &&
65 this->TMax_ns == parameters.TMax_ns &&
66 this->Pmin1 == parameters.Pmin1 &&
67 this->Pmin2 == parameters.Pmin2 &&
68 this->Nmax2 == parameters.Nmax2);
69 }
70
72
73 double roadWidth_m; ///< road width [m]
74 double R_Hz; ///< default rate [Hz]
75 size_t numberOfPrefits; ///< number of prefits
76 double TMin_ns; ///< minimal time w.r.t. Cherenkov hypothesis [ns]
77 double TMax_ns; ///< maximal time w.r.t. Cherenkov hypothesis [ns]
78 double Pmin1; ///< minimal probability single observation
79 double Pmin2; ///< minimal probability for twofold observations
80 int Nmax2; ///< maximal number for twofold observations
81 };
82}
83
84/**
85 * Read fit parameters from input.
86 *
87 * \param in input stream
88 * \param parameters fit parameters
89 * \return input stream
90 */
91std::istream& operator>>(std::istream& in, JRECONSTRUCTION::JMuonStartParameters_t& parameters);
92
93/**
94 * Write fit parameters to output.
95 *
96 * \param out output stream
97 * \param parameters fit parameters
98 * \return output stream
99 */
100std::ostream& operator<<(std::ostream& out, const JRECONSTRUCTION::JMuonStartParameters_t& parameters);
101
102#endif
std::istream & operator>>(std::istream &in, JRECONSTRUCTION::JMuonStartParameters_t &parameters)
Read fit parameters from input.
std::ostream & operator<<(std::ostream &out, const JRECONSTRUCTION::JMuonStartParameters_t &parameters)
Write fit parameters to output.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
Model fits to data.
Data structure for fit parameters.
virtual ~JMuonStartParameters_t()
Virtual destructor.
ClassDef(JMuonStartParameters_t, 3)
int Nmax2
maximal number for twofold observations
double Pmin1
minimal probability single observation
bool equals(const JMuonStartParameters_t &parameters) const
Equality.
double TMin_ns
minimal time w.r.t. Cherenkov hypothesis [ns]
double Pmin2
minimal probability for twofold observations
double TMax_ns
maximal time w.r.t. Cherenkov hypothesis [ns]