Jpp master_rocky-44-g75b7c4f75
the software that should make you happy
Loading...
Searching...
No Matches
JMuonGandalfParameters_t.hh
Go to the documentation of this file.
1#ifndef __JRECONSTRUCTION__JMUONGANDALFPARAMETERS__
2#define __JRECONSTRUCTION__JMUONGANDALFPARAMETERS__
3
4#include <limits>
5
6#include <TROOT.h>
7#include <TObject.h>
8
9/**
10 * \author gmaggi
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 */
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 TTS_ns = 2;
47 E_GeV = 1.0e3;
48 TMin_ns = -50.0;
49 TMax_ns = +450.0;
50 ZMin_m = 0.0;
51 ZMax_m = 0.0;
52 VMax_npe = 10.0;
53 NMax = 1000;
54 reprocess = false;
55 }
56
57 /**
58 * Equality
59 *
60 * \param parameters fit parameters
61 * \return true if equals; else false
62 */
63 bool equals(const JMuonGandalfParameters_t& parameters) const
64 {
65 return (this->roadWidth_m == parameters.roadWidth_m &&
66 this->R_Hz == parameters.R_Hz &&
67 this->numberOfPrefits == parameters.numberOfPrefits &&
68 this->TTS_ns == parameters.TTS_ns &&
69 this->E_GeV == parameters.E_GeV &&
70 this->TMin_ns == parameters.TMin_ns &&
71 this->TMax_ns == parameters.TMax_ns &&
72 this->ZMin_m == parameters.ZMin_m &&
73 this->ZMax_m == parameters.ZMax_m &&
74 this->VMax_npe == parameters.VMax_npe &&
75 this->NMax == parameters.NMax &&
76 this->reprocess == parameters.reprocess);
77 }
78
80
81 double roadWidth_m; ///< road width [m]
82 double R_Hz; ///< default rate [Hz]
83 size_t numberOfPrefits; ///< number of prefits
84 double TTS_ns; ///< transition-time spread [ns]
85 double E_GeV; ///< energy [GeV]
86 double TMin_ns; ///< minimal time w.r.t. Cherenkov hypothesis [ns]
87 double TMax_ns; ///< maximal time w.r.t. Cherenkov hypothesis [ns]
88 double ZMin_m; ///< minimal z-positon [m]
89 double ZMax_m; ///< maximal z-positon [m]
90 double VMax_npe; ///< maximum number of of photo-electrons
91 int NMax; ///< maximum number of iterations
92 bool reprocess; ///< reprocess
93 };
94}
95
96/**
97 * Read fit parameters from input.
98 *
99 * \param in input stream
100 * \param parameters fit parameters
101 * \return input stream
102 */
103std::istream& operator>>(std::istream& in, JRECONSTRUCTION::JMuonGandalfParameters_t& parameters);
104
105/**
106 * Write fit parameters to output.
107 *
108 * \param out output stream
109 * \param parameters fit parameters
110 * \return output stream
111 */
112std::ostream& operator<<(std::ostream& out, const JRECONSTRUCTION::JMuonGandalfParameters_t& parameters);
113
114#endif
std::ostream & operator<<(std::ostream &out, const JRECONSTRUCTION::JMuonGandalfParameters_t &parameters)
Write fit parameters to output.
std::istream & operator>>(std::istream &in, JRECONSTRUCTION::JMuonGandalfParameters_t &parameters)
Read fit parameters from input.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
Model fits to data.
ClassDef(JMuonGandalfParameters_t, 2)
double TMin_ns
minimal time w.r.t. Cherenkov hypothesis [ns]
double TMax_ns
maximal time w.r.t. Cherenkov hypothesis [ns]
double VMax_npe
maximum number of of photo-electrons
bool equals(const JMuonGandalfParameters_t &parameters) const
Equality.