Go to the documentation of this file. 1 #ifndef __JPHYSICS__JGEANT__
2 #define __JPHYSICS__JGEANT__
57 const double dx = 0.0001)
61 const double n0 =
geanx.
n - 0.02;
62 const double n1 =
geanx.
n + 0.02;
67 const double y0 = g0.
evaluate(-1.0, +1.0);
68 const double y1 =
g1.evaluate(-1.0, +1.0);
70 const double c = 1.0 / (y0 * 2*
PI);
74 for (
double x = -2.0; x < 1.0; x += dx) {
75 (*this)[x] = c * g0.
evaluate(x + 1.0/n0);
82 a1 = (y1 - y0) / y0 / (n1 - n0);
92 JGeantFunction1D_t::compile();
111 const double ct)
const
115 return y * (
a0 -
a1*
n);
130 const double xmax)
const
132 const double x_min = std::max(xmin - 1.0/
n,
buffer. begin()->getX());
133 const double x_max = std::min(xmax - 1.0/
n,
buffer.rbegin()->getX());
137 return y * (
a0 -
a1*
n);
152 in >> static_cast<JGeantFunction1D_t&>(
geant);
171 out << static_cast<const JGeantFunction1D_t&>(
geant);
Interface for binary input.
double a1
slope of the normalisation dependence
static const JGeanx geanx(0.35, -5.40)
Function object for the number of photons from EM-shower as a function of emission angle.
Double_t g1(const Double_t x)
Function.
double operator()(const double n, const double xmin, const double xmax) const
Integral number of photons from EM-shower between two emission angles.
Auxiliary classes and methods for calculation of PDF and muon energy loss.
double a0
offset of the normalisation dependence
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
friend JWriter & operator<<(JWriter &out, const JGeant &geant)
Write geant to output.
virtual void compile()
Function compilation.
Interface for binary output.
JTOOLS::JGridPolint1Function1D_t JGeantFunction1D_t
Function object for the probability density function of photon emission from EM-shower as a function ...
const double n
index of refraction
static const JGeant geant(geanx, 0.0001)
Function object for the number of photons from EM-shower as a function of emission angle.
JGeant(const JGeanx &geanx, const double dx=0.0001)
Constructor.
Probability density function of photon emission from EM-shower as a function of cosine of the emissio...
double operator()(const double n, const double ct) const
Number of photons from EM-shower as a function of emission angle.
JGeant()
Default constructor.
friend JReader & operator>>(JReader &in, JGeant &geant)
Read geant from input.
JGeantFunction1D_t buffer
double evaluate(const double ct) const
Functional dependence.