35int main(
int argc,
char **argv)
54 JParser<> zap(
"Program to verify generation of arrival times of Cherenkov photons from a shower using tabulated CDF.");
68 catch(
const exception& error) {
82 const int N = inputFile.size();
88 for (
int i = 0; i != N; ++i) {
90 NOTICE(
"loading input from file " << inputFile[i] <<
"... " << flush);
92 cdf [i].
load(inputFile[i].c_str());
108 cout <<
"> " << flush;
113 for (
int i = 0; i != N; ++i) {
122 catch(
const exception& error) {
136 if (inputFile.size() == 1 && getPDFType(inputFile[0]) == DIRECT_LIGHT_FROM_EMSHOWER) {
143 const double t0 = 0.0;
152 for ( ; x < -10.0; x += 5.0) { X.push_back(t0 + x); }
153 for ( ; x < +20.0; x += 1.0) { X.push_back(t0 + x); }
154 for ( ; x < +50.0; x += 2.0) { X.push_back(t0 + x); }
157 for ( ; x < +100.0; x += 5.0) { X.push_back(t0 + x); }
158 for ( ; x < +250.0; x += 10.0) { X.push_back(t0 + x); }
159 for ( ; x < +500.0; x += 25.0) { X.push_back(t0 + x); }
160 for ( ; x < +900.0; x += 50.0) { X.push_back(t0 + x); }
163 h0 =
new TH1D(
"h0",
NULL, X.size() - 1, X.data());
172 JManager<int, TH1D>
H1(
new TH1D(
"h1[%]",
NULL, 100000, 0.0, +1.0));
174 for (
int i = 0; i != N; ++i) {
176 for (
int j = 1; j <=
H1->GetNbinsX(); ++j) {
180 const double x =
H1->GetBinCenter(j);
183 H1[i]->SetBinContent(j, t);
185 catch(
const exception& error) {
191 if (numberOfEvents > 0) {
197 for (
int counter = 0; counter != numberOfEvents; ++counter) {
199 if (counter%1000== 0) {
205 for (
int i = 0; i != N; ++i) {
211 for (
int j =
gRandom->Poisson(npe); j != 0; --j) {
213 const double x =
gRandom->Rndm();
219 catch(
const exception& error) {
228 const double W = 1.0 / (
double) numberOfEvents;
234 convertToPDF(*h0,
"WE", W);
Various implementations of functional maps.
Dynamic ROOT object management.
General purpose messaging.
#define DEBUG(A)
Message macros.
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)
Auxiliary class for CPU timing and usage.
void print(std::ostream &out, const JScale_t scale=milli_t) const
Print timer data.
Data structure for angles in three dimensions.
double getTheta() const
Get theta angle.
double getPhi() const
Get phi angle.
Template definition of a multi-dimensional oscillation probability interpolation table.
void load()
Load oscillation probability table.
Utility class to parse command line options.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
Auxiliary data structure for floating point format specification.