28 int main(
int argc,
char **argv)
46 JParser<> zap(
"Program to plot PDF of Cherenkov light from bright point using interpolation tables.");
50 zap[
'E'] =
make_field(E,
"shower energy [GeV]") = 1.0;
53 zap[
'T'] =
make_field(TTS_ns,
"PMT time smearing [ns]") = 0.0;
59 catch(
const exception &error) {
60 FATAL(error.what() << endl);
70 const int N = inputFile.size();
77 for (
int i = 0; i != N; ++i) {
79 NOTICE(
"loading input from file " << inputFile[i] <<
"... " << flush);
83 pdf [i].load(inputFile[i].c_str());
85 pdf [i].setExceptionHandler(
new JFunction1D_t::JDefaultResult(
JMATH::zero));
95 FATAL(error.what() << endl);
101 for (
double dt; cin >> dt; ) {
103 for (
int i = 0; i != N; ++i) {
105 JFunction1D_t::result_type
y = pdf[i](D, ct, dt);
107 cout << setw(2) << type[i] <<
' '
109 <<
FIXED(5,1) << D <<
' '
110 <<
FIXED(5,2) << ct <<
' '
111 <<
FIXED(5,1) << dt <<
' '
127 if (inputFile.size() == 1 &&
133 const double t0 = 0.0;
153 for (
int i = 1; i <= h0.GetNbinsX(); ++i) {
155 const double dt = h0.GetBinCenter(i) - t0;
159 for (
int j = 0;
j != N; ++
j) {
160 Y += pdf[
j](D, ct, dt) * E;
Various implementations of functional maps.
General purpose messaging.
Numbering scheme for PDF types.
Utility class to parse command line options.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
int main(int argc, char **argv)
I/O formatting auxiliaries.
Utility class to parse command line options.
Multi-dimensional PDF table for arrival time of Cherenkov light.
JAbstractHistogram< double > JHistogram_t
Type definition for scan along axis.
std::string getLabel(const JLocation &location)
Get module label for monitoring and other applications.
static const JZero zero
Function object to assign zero value.
@ SCATTERED_LIGHT_FROM_BRIGHT_POINT
scattered light from bright point
int getPDFType(const std::string &file_name)
Get PDF type.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
Auxiliary data structure for floating point format specification.
Auxiliary data structure for floating point format specification.