1 #ifndef __JPHYSICS__JPDFTRANSFORMER__
2 #define __JPHYSICS__JPDFTRANSFORMER__
20 namespace JPP {
using namespace JPHYSICS; }
32 template<
unsigned int N,
class JArgument_t>
46 template<
class JArgument_t>
58 using JMultiMapTransformer_t::getWeight;
113 using namespace JTOOLS;
115 const double R = buffer[0];
124 if (__kmax > __kmin) {
141 using namespace JTOOLS;
143 const double R = buffer[0];
147 if (__kmax > __kmin) {
168 using namespace JTOOLS;
170 const double R = buffer[0];
173 const double ct0 = 1.0 / n;
174 const double st0 = sqrt((1.0 + ct0)*(1.0 - ct0));
176 const double d = sqrt(getRmin()*getRmin() + R*R) / st0;
178 return exp(-d/__ln) / pow(d,__alpha);
222 std::ostream&
print(std::ostream& out)
const
226 out <<
"Effective attenuation length [m] " << __ln << endl;
227 out <<
"Distance dependence (power term) " << __alpha << endl;
228 out <<
"Minimal kappa " << __kmin << endl;
229 out <<
"Maximal kappa " << __kmax << endl;
254 template<
class JArgument_t>
266 using JMultiMapTransformer_t::getWeight;
279 getShowerProbability()
303 getShowerProbability(geant)
305 getShowerProbability.add(bmin);
306 getShowerProbability.compile();
330 using namespace JTOOLS;
332 const double D = buffer[0];
342 if (__kmax > __kmin) {
359 using namespace JTOOLS;
361 const double D = buffer[0];
366 if (__kmax > __kmin) {
387 using namespace JTOOLS;
389 const double D = buffer[0];
390 const double cd = buffer[1];
392 const double d = sqrt(getDmin()*getDmin() + D*D);
410 in >> getShowerProbability;
428 out << getShowerProbability;
440 std::ostream&
print(std::ostream& out)
const
444 out <<
"Effective attenuation length [m] " << __ln << endl;
445 out <<
"Distance dependence (power term) " << __alpha << endl;
446 out <<
"Minimal kappa " << __kmin << endl;
447 out <<
"Maximal kappa " << __kmax << endl;
475 template<
class JArgument_t>
490 using JMultiMapTransformer_t::getWeight;
521 transformer(ln, alpha, kmin, kmax),
551 return transformer.putXn(buffer, xn);
564 return transformer.getXn(buffer, xn);
576 using namespace JTOOLS;
578 const double theta = buffer[1];
579 const double phi = buffer[2];
582 const double ct0 = 1.0 / n;
583 const double st0 = sqrt((1.0 + ct0)*(1.0 - ct0));
585 const double px = sin(theta)*cos(phi);
587 const double pz = cos(theta);
589 const double ct = st0*px + ct0*pz;
606 getAngularAcceptance.compile();
633 std::ostream&
print(std::ostream& out)
const
635 return transformer.print(out);
658 template<
class JArgument_t>
673 using JMultiMapTransformer_t::getWeight;
708 transformer(ln, alpha, kmin, kmax, geant, bmin),
738 return transformer.putXn(buffer, xn);
751 return transformer.getXn(buffer, xn);
763 const double cd = buffer[1];
764 const double theta = buffer[2];
765 const double phi = buffer[3];
767 const double ct0 = cd;
768 const double st0 = sqrt((1.0 + ct0)*(1.0 - ct0));
770 const double px = sin(theta)*cos(phi);
772 const double pz = cos(theta);
774 const double ct = st0*px + ct0*pz;
791 getAngularAcceptance.compile();
818 std::ostream&
print(std::ostream& out)
const
820 return transformer.print(out);
844 template<
class JArgument_t>
860 using JMultiMapTransformer_t::getWeight;
895 transformer(ln, alpha, kmin, kmax, geant, bmin, pmt, amin)
918 return transformer.putXn(buffer.
pop_front(), xn);
931 return transformer.getXn(buffer.
pop_front(), xn);
943 const double E = buffer[0];
944 return transformer.getWeight(buffer.
pop_front()) / E;
982 std::ostream&
print(std::ostream& out)
const
984 return transformer.print(out);
Interface for binary output.
static const JGeant geant(geanx, 0.0001)
Function object for the number of photons from EM-shower as a function of emission angle...
Compiler version dependent expressions, macros, etc.
Interface for binary input.
JClass_t * clone_type
Type definition of return value of method clone().
Function object for the probability density function of photon emission from EM-shower as a function ...
double getAngularAcceptance(const double x)
Angular acceptence of PMT.