ParametricMuonProfile.h
Go to the documentation of this file.
1 
9 #ifndef __ParametricMuonProfile__
10 #define __ParametricMuonProfile__
11 
12 #include <tls/VMuonProfile.h>
13 #include <tls/MuonProfileUtilities.h>
14 
15 #include <boost/multi_array.hpp>
16 
17 #include <vector>
18 
19 namespace utl { class Branch; }
20 
21 namespace ParametricMuonProfileNS {
31  public:
32 
34 
37 
38  inline
39  void CachedSetProfile(double theta, double phi, double energy)
40  {
41  if (theta < GetThetaMin()) theta = GetThetaMin();
42  else if (theta > GetThetaMax()) theta = GetThetaMax();
43 
44  if (theta == fTheta && phi == fPhi && energy == fEnergy) return;
45 
46  fEnergy = energy;
47  fTheta = theta;
48  fPhi = phi;
49  fBPsi = tls::GetBpsi(theta, phi);
50  fNMuonNumber = TotalMuonNumber(theta,energy);
51 
53  }
54 
55  double NMuon(double xpos, double ypos, double theta, double phi, double energy)
56  { return EvaluateProfile(eNMuTank, xpos, ypos, theta, phi, energy); }
57 
58  double ThetaMuon(double xpos, double ypos, double theta, double phi, double energy)
59  { return EvaluateProfile(eCosTheta, xpos, ypos, theta, phi, energy); }
60 
61  double EnergyMuon(double xpos, double ypos, double theta, double phi, double energy)
62  { return EvaluateProfile(eLogEnergy, xpos, ypos, theta, phi, energy); }
63 
64  double GetThetaMax();
65  double GetThetaMin();
66 
67  private:
68 
69  double D(double theta) const;
70 
71  double TotalMuonNumber(double theta, double energy) const;
72 
73  void BuildLocalModel();
74 
75  double EvaluateProfile(ProfileType type, double x, double y, double theta, double phi, double energy);
76 
77  double EvaluateLocalProfile(ProfileType type, double sqr, double zeta) const;
78 
79  typedef boost::multi_array<double,6> ModelDataType;
81 
82  typedef boost::multi_array<double,3> LocalDataType;
84 
85  void ReadModelData(const utl::Branch& modelBranch,
86  ModelDataType& tensor,
87  LocalDataType& tensorLocal) const;
88 
89  double fBiasCorrection[3];
90 
91  typedef std::vector<double> ArrayType;
92 
94 
96 
99 
100  double fTheta;
101  double fPhi;
102  double fEnergy;
103  double fBPsi;
104  double fNMuonNumber;
105  };
106 } // NS ParametricMuonProfileNS
107 
108 #endif
double ThetaMuon(double xpos, double ypos, double theta, double phi, double energy)
Expected average muon inclination angle on the ground, at the given coordinates on the ground...
void ReadModelData(const utl::Branch &modelBranch, ModelDataType &tensor, LocalDataType &tensorLocal) const
double NMuon(double xpos, double ypos, double theta, double phi, double energy)
Expected average number of muons per tank, at the given coordinates on the ground, for a certain combination of theta, phi, and energy of the primary particle.
double GetBpsi(const double theta, const double phi)
double EnergyMuon(double xpos, double ypos, double theta, double phi, double energy)
Expected average muon energy on the ground, at the given coordinates on the ground, for a certain combination of theta, phi, and energy of the primary particle.
double TotalMuonNumber(double theta, double energy) const
Class representing a document branch.
Definition: Branch.h:107
double EvaluateProfile(ProfileType type, double x, double y, double theta, double phi, double energy)
double GetThetaMax()
Maximum zenith angle, at which the tank response function is defined.
This class wraps the muon profile implementation, which is based on a multi-dimensional parameterisat...
double GetThetaMin()
Minimum zenith angle, at which the tank response function is defined.
void CachedSetProfile(double theta, double phi, double energy)
double EvaluateLocalProfile(ProfileType type, double sqr, double zeta) const
This is the virtual base class for muon numbers. The implementation has to provide these virtual meth...
Definition: VMuonProfile.h:11

, generated on Tue Sep 26 2023.