73 JParser<> zap(
"Auxiliary program to draw PDF of Cherenkov light from muon.");
81 zap[
'E'] =
make_field(
E,
"muon energy at vertex [GeV]")= 1.0;
82 zap[
'R'] =
make_field(
R,
"distance of approach [m]");
84 zap[
'D'] =
make_field(dir,
"(theta, phi) of PMT [rad]");
91 catch(
const exception &error) {
92 FATAL(error.what() << endl);
110 const double E_emission =
gWater.
getE(
E, z_emission );
114 for (
double dt; cin >> dt; ) {
118 cout << setw(2) << *
F <<
' '
122 <<
FIXED(5,2) << dir.getTheta() <<
' '
123 <<
FIXED(5,2) << dir.getPhi() <<
' '
124 <<
FIXED(5,1) << dt <<
' '
125 <<
SCIENTIFIC(9,3) << pdf.getLightFromMuon(*
F, E_emission,
R, dir.getTheta(), dir.getPhi(), dt) * E_emission << endl;
135 const double t0 = 0.0;
155 JSplineFunction1S_t
f1;
159 if (z_emission >= 0 && z_emission <=
gWater(
E)) {
160 for (
int i = 1;
i <= h0.GetNbinsX(); ++
i) {
162 const double dt = h0.GetBinCenter(
i) - t0;
167 value += pdf.getLightFromMuon(*
F, E_emission,
R, dir.getTheta(), dir.getPhi(), dt);
170 h0.SetBinContent(
i, value);
177 f1.setExceptionHandler(
new JSplineFunction1S_t::JDefaultResult(
JMATH::zero));
182 JQuantiles quantiles(
f1);
184 const double t1 = quantiles.getX();
185 const double y =
f1(t1 +
T).v -
f1(t1 -
T).v;
188 DEBUG(
"E_emission" << E_emission << endl);
191 DEBUG(
"theta " << dir.getTheta() << endl);
192 DEBUG(
"phi " << dir.getPhi() << endl);
193 DEBUG(
"int " << quantiles.getIntegral() << endl);
194 DEBUG(
"t1 " << t1 << endl);
195 DEBUG(
"max " << quantiles.getY() << endl);
196 DEBUG(
"FWHM " << quantiles.getFWHM() << endl);
197 DEBUG(
"int[] " <<
y << endl);
Utility class to parse command line options.
static const double COS_THETA_C_WATER
Average cosine corresponding to the group velocity.
then usage $script< input file >[option[primary[working directory]]] nWhere option can be E
#define gmake_property(A)
macros to convert (template) parameter to JPropertiesElement object
Utility class to parse parameter values.
static const double MASS_MUON
muon mass [GeV]
double absorptionLengthFactor
Scaling of absorption and scattering length.
double getScatteringProbability(const double x)
Function to describe light scattering in water.
Empty structure for specification of parser element that is initialised (i.e. does not require input)...
static const JGeaneWater gWater
Function object for energy loss of muon in sea water.
static const JZero zero
Function object to assign zero value.
double getMinimalWavelength()
Get minimal wavelength for PDF evaluations.
then warning Cannot perform comparison test for histogram
Auxiliary data structure for floating point format specification.
const JPolynome f1(1.0, 2.0, 3.0)
Function.
static double MODULE_RADIUS_M
Radius of optical module [m].
double getMaximalWavelength()
Get maximal wavelength for PDF evaluations.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
double getQE(const double R, const double mu)
Get QE for given ratio of hit probabilities and expectation value of the number of photo-electrons...
do set_variable OUTPUT_DIRECTORY $WORKDIR T
double getAmbientPressure()
Get ambient pressure.
double getPhotocathodeArea()
Get photo-cathode area of PMT.
then JCookie sh JDataQuality D $DETECTOR_ID R
virtual double getE(const double E, const double dx) const override
Get energy of muon after specified distance.
then usage $script[energy[distance[z of PMT]]] fi case set_variable z
double getAbsorptionLength(const double lambda)
Get absorption length.
double getScatteringLength(const double lambda)
Get scattering length.
double scatteringLengthFactor
double getTanThetaC()
Get average tangent of Cherenkov angle of water corresponding to group velocity.
Auxiliary data structure for floating point format specification.
JAbstractHistogram< double > JHistogram_t
Type definition for scan along axis.
#define DEBUG(A)
Message macros.
double getAngularAcceptance(const double x)
Angular acceptence of PMT.