31int main(
int argc,
char **argv)
54 JParser<> zap(
"Auxiliary program to draw PDF of Cherenkov light from muon.");
59 zap[
'e'] =
make_field(epsilon,
"precision for integration") = 1.0e-10;
60 zap[
'E'] =
make_field(E,
"muon energy at vertex [GeV]") = 1.0;
61 zap[
'R'] =
make_field(R,
"distance of approach [m]");
62 zap[
'z'] =
make_field(z,
"PMT z-position [m]");
63 zap[
'D'] =
make_field(dir,
"(theta, phi) of PMT [rad]");
70 catch(
const exception &error) {
71 FATAL(error.what() << endl);
76 pdf(NAMESPACE::getPhotocathodeArea(),
78 PDF::getAngularAcceptance,
79 PDF::getAbsorptionLength,
80 PDF::getScatteringLength,
81 PDF::getScatteringProbability,
82 NAMESPACE::getAmbientPressure(),
83 getMinimalWavelength(),
84 getMaximalWavelength(),
88 const double z_0 = z - R/getTanThetaC();
89 const double E_0 = gWater.getE(E, z_0);
94 cout <<
"enter time (^C to exit) > " << flush;
96 for (
double dt; cin >> dt; ) {
98 for (vector<int>::const_iterator F = function.begin(); F != function.end(); ++F) {
100 cout << setw(2) << *F <<
' '
102 <<
FIXED(5,1) << R <<
' '
103 <<
FIXED(5,1) << z <<
' '
106 <<
FIXED(5,1) << dt <<
' '
117 const double t0 = 0.0;
121 if (function.size() == 1 && function[0] == DIRECT_LIGHT_FROM_MUON) {
139 if (E_0 >= MASS_MUON* (1.0/SIN_THETA_C_WATER)) {
141 if (z_0 >= 0 && z_0 <= gWater(E)) {
143 for (
int i = 1; i <= h0.GetNbinsX(); ++i) {
145 const double dt = h0.GetBinCenter(i) - t0;
149 for (vector<int>::const_iterator F = function.begin(); F != function.end(); ++F) {
153 h0.SetBinContent(i, value);
165 const double T_ns = 5;
169 const double t1 = quantiles.
getX();
170 const double y = f1(t1 + T_ns).v - f1(t1 - T_ns).v;
172 DEBUG(
"E " << E << endl);
173 DEBUG(
"E_0 " << E_0 << endl);
174 DEBUG(
"R " << R << endl);
175 DEBUG(
"z " << z << endl);
179 DEBUG(
"t1 " << t1 << endl);
180 DEBUG(
"max " << quantiles.
getY() << endl);
182 DEBUG(
"int[] " << y << endl);
184 catch(
const exception&) {}
Properties of Antares PMT and deep-sea water.
General purpose messaging.
#define DEBUG(A)
Message macros.
Utility class to parse command line options.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
I/O formatting auxiliaries.
Utility class to parse parameter values.
Properties of KM3NeT PMT and deep-sea water.
Utility class to parse parameter values.
Data structure for angles in three dimensions.
double getTheta() const
Get theta angle.
double getPhi() const
Get phi angle.
Utility class to parse command line options.
Probability Density Functions of the time response of a PMT with an implementation of the JAbstractPM...
double getLightFromMuon(const int type, const double E_GeV, const double R_m, const double theta, const double phi, const double t_ns) const
Probability density function for light from muon.
static const JZero zero
Function object to assign zero value.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
Auxiliary data structure for floating point format specification.
Empty structure for specification of parser element that is initialised (i.e. does not require input)...
Auxiliary data structure for complete configuration.
JProperties getProperties()
Get properties.
Manipulator for help output.
Auxiliary data structure for floating point format specification.