LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
NDKGen_module.cc
Go to the documentation of this file.
1 //
3 //
4 // NDK neutrino event generator
5 //
6 // echurch@fnal.gov
7 //
9 #include <cstdlib>
10 #include <fstream>
11 #include <iomanip>
12 #include <iostream>
13 #include <memory>
14 #include <sstream>
15 #include <stdio.h>
16 #include <string>
17 #include <vector>
18 
19 // ROOT includes
20 #include "TDatabasePDG.h"
21 #include "TH1.h"
22 #include "TH2.h"
23 #include "TStopwatch.h"
24 
25 #include "CLHEP/Random/RandFlat.h"
26 
27 // Framework includes
33 #include "art_root_io/TFileService.h"
34 #include "fhiclcpp/ParameterSet.h"
35 
36 // art extensions
41 
42 // LArSoft includes
45 
46 namespace evgen {
48  class NDKGen : public art::EDProducer {
49  public:
50  explicit NDKGen(fhicl::ParameterSet const& pset);
51 
52  private:
53  void produce(art::Event& evt) override;
54  void beginJob() override;
55  void beginRun(art::Run& run) override;
56  void endJob() override;
57 
58  std::string ParticleStatus(int StatusCode);
59  std::string ReactionChannel(int ccnc, int mode);
60 
61  void FillHistograms(simb::MCTruth const& mc);
62 
63  std::string fNdkFile;
64  std::ifstream fEventFile;
65 
66  std::string fNDKModuleLabel;
67  CLHEP::HepRandomEngine& fEngine;
68 
69  TH1F* fGenerated[6];
70 
71  TH1F* fVertexX;
72  TH1F* fVertexY;
73  TH1F* fVertexZ;
74 
75  TH2F* fVertexXY;
76  TH2F* fVertexXZ;
77  TH2F* fVertexYZ;
78 
79  TH1F* fDCosX;
80  TH1F* fDCosY;
81  TH1F* fDCosZ;
82 
83  TH1F* fMuMomentum;
84  TH1F* fMuDCosX;
85  TH1F* fMuDCosY;
86  TH1F* fMuDCosZ;
87 
88  TH1F* fEMomentum;
89  TH1F* fEDCosX;
90  TH1F* fEDCosY;
91  TH1F* fEDCosZ;
92 
93  TH1F* fCCMode;
94  TH1F* fNCMode;
95 
96  TH1F* fECons;
97  };
98 } // namespace
99 
100 namespace evgen {
101 
102  //____________________________________________________________________________
104  : EDProducer{pset}
105  , fNdkFile{pset.get<std::string>("NdkFile")}
107  // create a default random engine; obtain the random seed from NuRandomService,
108  // unless overridden in configuration with key "Seed"
109  , fEngine(art::ServiceHandle<rndm::NuRandomService>()->registerAndSeedEngine(createEngine(0),
110  pset,
111  "Seed"))
112  {
113  produces<std::vector<simb::MCTruth>>();
114  produces<sumdata::RunData, art::InRun>();
115 
116  if (!fEventFile.good()) {
117  throw cet::exception("NDKGen") << "Could not open file: " << fNdkFile << '\n';
118  }
119  }
120 
121  //___________________________________________________________________________
122 
124  {
126 
127  fGenerated[0] = tfs->make<TH1F>("fGenerated_necc", "", 100, 0.0, 20.0);
128  fGenerated[1] = tfs->make<TH1F>("fGenerated_nebcc", "", 100, 0.0, 20.0);
129  fGenerated[2] = tfs->make<TH1F>("fGenerated_nmcc", "", 100, 0.0, 20.0);
130  fGenerated[3] = tfs->make<TH1F>("fGenerated_nmbcc", "", 100, 0.0, 20.0);
131  fGenerated[4] = tfs->make<TH1F>("fGenerated_nnc", "", 100, 0.0, 20.0);
132  fGenerated[5] = tfs->make<TH1F>("fGenerated_nbnc", "", 100, 0.0, 20.0);
133 
134  fDCosX = tfs->make<TH1F>("fDCosX", ";dx/ds", 200, -1., 1.);
135  fDCosY = tfs->make<TH1F>("fDCosY", ";dy/ds", 200, -1., 1.);
136  fDCosZ = tfs->make<TH1F>("fDCosZ", ";dz/ds", 200, -1., 1.);
137 
138  fMuMomentum = tfs->make<TH1F>("fMuMomentum", ";p_{#mu} (GeV/c)", 500, 0., 50.);
139  fMuDCosX = tfs->make<TH1F>("fMuDCosX", ";dx/ds;", 200, -1., 1.);
140  fMuDCosY = tfs->make<TH1F>("fMuDCosY", ";dy/ds;", 200, -1., 1.);
141  fMuDCosZ = tfs->make<TH1F>("fMuDCosZ", ";dz/ds;", 200, -1., 1.);
142 
143  fEMomentum = tfs->make<TH1F>("fEMomentum", ";p_{e} (GeV/c)", 500, 0., 50.);
144  fEDCosX = tfs->make<TH1F>("fEDCosX", ";dx/ds;", 200, -1., 1.);
145  fEDCosY = tfs->make<TH1F>("fEDCosY", ";dy/ds;", 200, -1., 1.);
146  fEDCosZ = tfs->make<TH1F>("fEDCosZ", ";dz/ds;", 200, -1., 1.);
147 
148  fCCMode = tfs->make<TH1F>("fCCMode", ";CC Interaction Mode;", 5, 0., 5.);
149  fCCMode->GetXaxis()->SetBinLabel(1, "QE");
150  fCCMode->GetXaxis()->SetBinLabel(2, "Res");
151  fCCMode->GetXaxis()->SetBinLabel(3, "DIS");
152  fCCMode->GetXaxis()->SetBinLabel(4, "Coh");
153  fCCMode->GetXaxis()->SetBinLabel(5, "kInverseMuDecay");
154  fCCMode->GetXaxis()->CenterLabels();
155 
156  fNCMode = tfs->make<TH1F>("fNCMode", ";NC Interaction Mode;", 5, 0., 5.);
157  fNCMode->GetXaxis()->SetBinLabel(1, "QE");
158  fNCMode->GetXaxis()->SetBinLabel(2, "Res");
159  fNCMode->GetXaxis()->SetBinLabel(3, "DIS");
160  fNCMode->GetXaxis()->SetBinLabel(4, "Coh");
161  fNCMode->GetXaxis()->SetBinLabel(5, "kNuElectronElastic");
162  fNCMode->GetXaxis()->CenterLabels();
163 
164  fECons = tfs->make<TH1F>("fECons", ";#Delta E(#nu,lepton);", 500, -5., 5.);
165 
167  double x = 2.1 * geo->DetHalfWidth();
168  double y = 2.1 * geo->DetHalfHeight();
169  double z = 2. * geo->DetLength();
170  int xdiv = TMath::Nint(2 * x / 5.);
171  int ydiv = TMath::Nint(2 * y / 5.);
172  int zdiv = TMath::Nint(2 * z / 5.);
173 
174  fVertexX = tfs->make<TH1F>("fVertexX", ";x (cm)", xdiv, -x, x);
175  fVertexY = tfs->make<TH1F>("fVertexY", ";y (cm)", ydiv, -y, y);
176  fVertexZ = tfs->make<TH1F>("fVertexZ", ";z (cm)", zdiv, -0.2 * z, z);
177 
178  fVertexXY = tfs->make<TH2F>("fVertexXY", ";x (cm);y (cm)", xdiv, -x, x, ydiv, -y, y);
179  fVertexXZ = tfs->make<TH2F>("fVertexXZ", ";z (cm);x (cm)", zdiv, -0.2 * z, z, xdiv, -x, x);
180  fVertexYZ = tfs->make<TH2F>("fVertexYZ", ";z (cm);y (cm)", zdiv, -0.2 * z, z, ydiv, -y, y);
181  }
182 
183  //____________________________________________________________________________
185  {
187  run.put(std::make_unique<sumdata::RunData>(geo->DetectorName()), art::fullRun());
188  }
189 
190  //____________________________________________________________________________
192  {
193  fEventFile.close();
194  }
195 
196  //____________________________________________________________________________
198  {
199 
200  std::cout << std::endl;
201  std::cout << "------------------------------------------------------------------------------"
202  << std::endl;
203  std::cout << "event : " << evt.id().event() << std::endl;
204 
205  std::string name, k, dollar;
206 
207  // event dump format on file output by the two commands ....
208  // gevgen_ndcy -g 1000180400 -m 8 -n 400 -o ndk
209  // gevdump -f ndk.1000.ghep.root > ndk.out
210  std::string Name;
211  int Idx, Ist, PDG, Mother1, Mother2, Daughter1, Daughter2;
212  double Px, Py, Pz, E, m;
213  std::string p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14;
214 
215  int trackid = -1; // set track id to -i as these are all primary particles and have id <= 0
216  std::string primary("primary");
217  int FirstMother = -1;
218  double Mass = -9999;
219  int Status = -9999;
220 
221  double P; // momentum of MCParticle IN GeV/c
222 
223  TLorentzVector Neutrino;
224  TLorentzVector Lepton;
225  TLorentzVector Target;
226  TLorentzVector q;
227  TLorentzVector Hadron4mom;
228 
229  TLorentzVector Tpos;
230 
231  std::unique_ptr<std::vector<simb::MCTruth>> truthcol(new std::vector<simb::MCTruth>);
232  simb::MCTruth truth;
233 
235  CLHEP::RandFlat flat(fEngine);
236 
237  double const fvCut{5.0}; // force vtx to be this far from any wall.
238 
239  // Find boundary of active volume
240  double minx = 1e9;
241  double maxx = -1e9;
242  double miny = 1e9;
243  double maxy = -1e9;
244  double minz = 1e9;
245  double maxz = -1e9;
246  for (auto const& tpc : geo->Iterate<geo::TPCGeo>(geo::CryostatID{0})) {
247  auto const world = tpc.GetCenter();
248  if (minx > world.X() - tpc.HalfWidth()) minx = world.X() - tpc.HalfWidth();
249  if (maxx < world.X() + tpc.HalfWidth()) maxx = world.X() + tpc.HalfWidth();
250  if (miny > world.Y() - tpc.HalfHeight()) miny = world.Y() - tpc.HalfHeight();
251  if (maxy < world.Y() + tpc.HalfHeight()) maxy = world.Y() + tpc.HalfHeight();
252  if (minz > world.Z() - tpc.Length() / 2.) minz = world.Z() - tpc.Length() / 2.;
253  if (maxz < world.Z() + tpc.Length() / 2.) maxz = world.Z() + tpc.Length() / 2.;
254  }
255 
256  // Assign vertice position
257  double X0 = 0.0 + flat.fire(minx + fvCut, maxx - fvCut);
258  double Y0 = 0.0 + flat.fire(miny + fvCut, maxy - fvCut);
259  double Z0 = 0.0 + flat.fire(minz + fvCut, maxz - fvCut);
260 
261  std::cout << "NDKGen_module: X, Y, Z of vtx: " << X0 << ", " << Y0 << ", " << Z0 << std::endl;
262 
263  int GenieEvt = -999;
264 
265  if (!fEventFile.good()) std::cout << "NdkFile: Problem reading Ndk file" << std::endl;
266 
267  while (getline(fEventFile, k)) {
268 
269  if (k.find("** Event:") != std::string::npos) {
270  std::istringstream in;
271  in.clear();
272  in.str(k);
273  std::string dummy;
274  in >> dummy >> dummy >> dummy >> dummy >> dummy >> dummy >> dummy >> dummy >> dummy >>
275  dummy >> GenieEvt;
276  std::cout << "Genie Evt " << GenieEvt << " art evt " << evt.id().event() << "\n";
277  }
278 
279  if (GenieEvt + 1 != static_cast<int>(evt.id().event()))
280  continue;
281  else {
282 
283  if (!k.compare(0, 25, "GENIE Interaction Summary")) // testing for new event.
284  break;
285  if (k.compare(0, 1, "|") || k.compare(1, 2, " "))
286  continue; // uninteresting line if it doesn't start with "|" and if second and third characters aren't spaces.
287  if (k.find("Fin-Init") != std::string::npos) continue; // Meh.
288  if (k.find("Ar") != std::string::npos) continue; // Meh.
289  if (k.find("Cl") != std::string::npos) continue; // ignore chlorine nucleus in nnbar events
290  if (k.find("HadrBlob") != std::string::npos) continue; // Meh.
291  if (k.find("NucBindE") != std::string::npos) continue; // Meh. atmo
292  if (k.find("FLAGS") != std::string::npos) break; // Event end. gevgen_ndcy
293  if (k.find("Vertex") != std::string::npos) break; // Event end. atmo
294 
295  if (!k.compare(26, 1, "1")) // New event or stable particles.
296  {
297 
298  std::istringstream in;
299  in.clear();
300  in.str(k);
301 
302  in >> p1 >> Idx >> p2 >> Name >> p3 >> Ist >> p4 >> PDG >> p5 >> Mother1 >> p6 >>
303  Mother2 >> p7 >> Daughter1 >> p8 >> Daughter2 >> p9 >> Px >> p10 >> Py >> p11 >> Pz >>
304  p12 >> E >> p13 >> m >> p14;
305  if (Ist != 1) continue;
306 
307  std::cout << "PDG = " << PDG << std::endl;
308 
309  const TDatabasePDG* databasePDG = TDatabasePDG::Instance();
310  const TParticlePDG* definition = databasePDG->GetParticle(PDG);
311  Mass = definition->Mass(); // GeV
312  if (E - Mass < 0.001) continue; // KE is too low.
313 
314  Status = 1;
315 
316  simb::MCParticle mcpart(trackid, PDG, primary, FirstMother, Mass, Status);
317 
318  P = std::sqrt(pow(E, 2.) - pow(Mass, 2.)); // GeV/c
319  std::cout << "Momentum = " << P << std::endl;
320 
321  TLorentzVector pos(X0, Y0, Z0, 0);
322 
323  Tpos = pos; // for target
324 
325  TLorentzVector mom(Px, Py, Pz, E);
326 
327  mcpart.AddTrajectoryPoint(pos, mom);
328  truth.Add(mcpart);
329 
330  } // loop over particles in an event
331  truth.SetOrigin(simb::kUnknown);
332  }
333  } // end while loop
334 
336  std::cout << "NDKGen.cxx: Putting " << truth.NParticles() << " tracks on stack." << std::endl;
337  truthcol->push_back(truth);
338  evt.put(std::move(truthcol));
339  }
340 
341  // //......................................................................
342  std::string NDKGen::ParticleStatus(int StatusCode)
343  {
344  switch (StatusCode) {
345  case 0: return "kIStInitialState";
346  case 1: return "kIStFinalState";
347  case 11: return "kIStNucleonTarget";
348  default: return "Status Unknown";
349  }
350  }
351 
352  // //......................................................................
353  std::string NDKGen::ReactionChannel(int ccnc, int mode)
354  {
355  std::string ReactionChannelName = " ";
356 
357  if (ccnc == 0)
358  ReactionChannelName = "kCC";
359  else if (ccnc == 1)
360  ReactionChannelName = "kNC";
361  else
362  std::cout << "Current mode unknown!! " << std::endl;
363 
364  if (mode == 0)
365  ReactionChannelName += "_kQE";
366  else if (mode == 1)
367  ReactionChannelName += "_kRes";
368  else if (mode == 2)
369  ReactionChannelName += "_kDIS";
370  else if (mode == 3)
371  ReactionChannelName += "_kCoh";
372  else if (mode == 4)
373  ReactionChannelName += "_kNuElectronElastic";
374  else if (mode == 5)
375  ReactionChannelName += "_kInverseMuDecay";
376  else
377  std::cout << "interaction mode unknown!! " << std::endl;
378 
379  return ReactionChannelName;
380  }
381 
382  // //......................................................................
384  {
385  // Decide which histograms to put the spectrum in
386  int id = -1;
387  if (mc.GetNeutrino().CCNC() == simb::kCC) {
388  fCCMode->Fill(mc.GetNeutrino().Mode());
389  if (mc.GetNeutrino().Nu().PdgCode() == 12)
390  id = 0;
391  else if (mc.GetNeutrino().Nu().PdgCode() == -12)
392  id = 1;
393  else if (mc.GetNeutrino().Nu().PdgCode() == 14)
394  id = 2;
395  else if (mc.GetNeutrino().Nu().PdgCode() == -14)
396  id = 3;
397  else
398  return;
399  }
400  else {
401  fNCMode->Fill(mc.GetNeutrino().Mode());
402  if (mc.GetNeutrino().Nu().PdgCode() > 0)
403  id = 4;
404  else
405  id = 5;
406  }
407  if (id == -1) abort();
408 
409  // Fill the specta histograms
410  fGenerated[id]->Fill(mc.GetNeutrino().Nu().E());
411 
412  //< fill the vertex histograms from the neutrino - that is always
413  //< particle 0 in the list
414  simb::MCNeutrino mcnu = mc.GetNeutrino();
415  const simb::MCParticle nu = mcnu.Nu();
416 
417  fVertexX->Fill(nu.Vx());
418  fVertexY->Fill(nu.Vy());
419  fVertexZ->Fill(nu.Vz());
420 
421  fVertexXY->Fill(nu.Vx(), nu.Vy());
422  fVertexXZ->Fill(nu.Vz(), nu.Vx());
423  fVertexYZ->Fill(nu.Vz(), nu.Vy());
424 
425  double mom = nu.P();
426  if (std::abs(mom) > 0.) {
427  fDCosX->Fill(nu.Px() / mom);
428  fDCosY->Fill(nu.Py() / mom);
429  fDCosZ->Fill(nu.Pz() / mom);
430  }
431 
432  std::cout << "REACTION: " << ReactionChannel(mc.GetNeutrino().CCNC(), mc.GetNeutrino().Mode())
433  << std::endl;
434  std::cout << "-----------> Particles in the Stack = " << mc.NParticles() << std::endl;
435  std::cout << std::setiosflags(std::ios::left) << std::setw(20) << "PARTICLE"
436  << std::setiosflags(std::ios::left) << std::setw(32) << "STATUS" << std::setw(18)
437  << "E (GeV)" << std::setw(18) << "m (GeV/c2)" << std::setw(18) << "Ek (GeV)"
438  << std::endl
439  << std::endl;
440 
441  const TDatabasePDG* databasePDG = TDatabasePDG::Instance();
442 
443  // Loop over the particle stack for this event
444  for (int i = 0; i < mc.NParticles(); ++i) {
446  std::string name;
447  if (part.PdgCode() == 18040)
448  name = "Ar40 18040";
449  else if (part.PdgCode() != -99999) {
450  name = databasePDG->GetParticle(part.PdgCode())->GetName();
451  }
452 
453  int code = part.StatusCode();
454  std::string status = ParticleStatus(code);
455  double mass = part.Mass();
456  double energy = part.E();
457  double Ek = (energy - mass); // Kinetic Energy (GeV)
458 
459  std::cout << std::setiosflags(std::ios::left) << std::setw(20) << name
460  << std::setiosflags(std::ios::left) << std::setw(32) << status << std::setw(18)
461  << energy << std::setw(18) << mass << std::setw(18) << Ek << std::endl;
462  }
463 
464  if (mc.GetNeutrino().CCNC() == simb::kCC) {
465 
468  for (int i = 0; i < mc.NParticles(); ++i) {
470  if (abs(part.PdgCode()) == 11) {
471  fEMomentum->Fill(part.P());
472  fEDCosX->Fill(part.Px() / part.P());
473  fEDCosY->Fill(part.Py() / part.P());
474  fEDCosZ->Fill(part.Pz() / part.P());
475  fECons->Fill(nu.E() - part.E());
476  break;
477  }
478  else if (abs(part.PdgCode()) == 13) {
479  fMuMomentum->Fill(part.P());
480  fMuDCosX->Fill(part.Px() / part.P());
481  fMuDCosY->Fill(part.Py() / part.P());
482  fMuDCosZ->Fill(part.Pz() / part.P());
483  fECons->Fill(nu.E() - part.E());
484  break;
485  }
486  } // end loop over particles
487  } //end if CC interaction
488  }
489 
491 
492 } // namespace
Float_t x
Definition: compare.C:6
double E(const int i=0) const
Definition: MCParticle.h:234
NDKGen(fhicl::ParameterSet const &pset)
details::range_type< T > Iterate() const
Initializes the specified ID with the ID of the first cryostat.
Definition: GeometryCore.h:541
base_engine_t & createEngine(seed_t seed)
TH1F * fMuMomentum
momentum of outgoing muons
TH2F * fVertexXY
vertex location in xy
int PdgCode() const
Definition: MCParticle.h:213
int CCNC() const
Definition: MCNeutrino.h:148
const simb::MCNeutrino & GetNeutrino() const
Definition: MCTruth.h:77
TH1F * fGenerated[6]
Spectra as generated.
double Py(const int i=0) const
Definition: MCParticle.h:232
TH1F * fMuDCosY
direction cosine of outgoing mu in y
TH1F * fMuDCosZ
direction cosine of outgoing mu in z
TH1F * fECons
histogram to determine if energy is conserved in the event
void AddTrajectoryPoint(TLorentzVector const &position, TLorentzVector const &momentum)
Definition: MCParticle.h:258
constexpr auto fullRun()
void SetOrigin(simb::Origin_t origin)
Definition: MCTruth.h:82
Float_t y
Definition: compare.C:6
TH1F * fEDCosZ
direction cosine of outgoing e in z
std::string fNdkFile
const simb::MCParticle & Nu() const
Definition: MCNeutrino.h:146
TH1F * fEMomentum
momentum of outgoing electrons
EDProducer(fhicl::ParameterSet const &pset)
Definition: EDProducer.cc:6
Length_t DetHalfWidth(TPCID const &tpcid=tpc_zero) const
Returns the half width of the active volume of the specified TPC.
Double_t z
Definition: plot.C:276
TH2F * fVertexXZ
vertex location in xz
Geometry information for a single TPC.
Definition: TPCGeo.h:36
double Px(const int i=0) const
Definition: MCParticle.h:231
constexpr auto abs(T v)
Returns the absolute value of the argument.
TH1F * fVertexY
vertex location of generated events in y
PutHandle< PROD > put(std::unique_ptr< PROD > &&edp, std::string const &instance={})
Definition: Run.h:121
int NParticles() const
Definition: MCTruth.h:75
Particle class.
TH1F * fCCMode
CC interaction mode.
Length_t DetLength(TPCID const &tpcid=tpc_zero) const
Returns the length of the active volume of the specified TPC.
TH1F * fEDCosY
direction cosine of outgoing e in y
void produce(art::Event &evt) override
Definition: Run.h:37
PutHandle< PROD > put(std::unique_ptr< PROD > &&edp, std::string const &instance={})
Definition: Event.h:77
CLHEP::HepRandomEngine & fEngine
art-managed random-number engine
A module to check the results from the Monte Carlo generator.
TString part[npart]
Definition: Style.C:32
#define DEFINE_ART_MODULE(klass)
Definition: ModuleMacros.h:65
Float_t E
Definition: plot.C:20
double P(const int i=0) const
Definition: MCParticle.h:235
TH1F * fMuDCosX
direction cosine of outgoing mu in x
double energy
Definition: plottest35.C:25
TH2F * fVertexYZ
vertex location in yz
TH1F * fVertexZ
vertex location of generated events in z
TH1F * fDCosZ
direction cosine in z
std::string ReactionChannel(int ccnc, int mode)
std::string fNDKModuleLabel
An art service to assist in the distribution of guaranteed unique seeds to all engines within an art ...
const simb::MCParticle & GetParticle(int i) const
Definition: MCTruth.h:76
TH1F * fEDCosX
direction cosine of outgoing e in x
void beginJob() override
std::ifstream fEventFile
double Vx(const int i=0) const
Definition: MCParticle.h:222
constexpr auto const & left(const_AssnsIter< L, R, D, Dir > const &a, const_AssnsIter< L, R, D, Dir > const &b)
Definition: AssnsIter.h:94
ifstream in
Definition: comparison.C:7
void Add(simb::MCParticle const &part)
Definition: MCTruth.h:80
void endJob() override
void FillHistograms(simb::MCTruth const &mc)
double Pz(const int i=0) const
Definition: MCParticle.h:233
double Vz(const int i=0) const
Definition: MCParticle.h:224
EventNumber_t event() const
Definition: EventID.h:116
std::string ParticleStatus(int StatusCode)
Length_t DetHalfHeight(TPCID const &tpcid=tpc_zero) const
Returns the half height of the active volume of the specified TPC.
std::string const & DetectorName() const
Returns a string with the name of the detector, as configured.
Definition: GeometryCore.h:203
void beginRun(art::Run &run) override
TCEvent evt
Definition: DataStructs.cxx:8
Event generator information.
Definition: MCTruth.h:32
TH1F * fNCMode
CC interaction mode.
TH1F * fDCosY
direction cosine in y
Event generator information.
Definition: MCNeutrino.h:18
Namespace collecting geometry-related classes utilities.
int Mode() const
Definition: MCNeutrino.h:149
Event Generation using GENIE, cosmics or single particles.
TH1F * fVertexX
vertex location of generated events in x
TH1F * fDCosX
direction cosine in x
EventID id() const
Definition: Event.cc:23
double Vy(const int i=0) const
Definition: MCParticle.h:223
art framework interface to geometry description
cet::coded_exception< error, detail::translate > exception
Definition: exception.h:33
The data type to uniquely identify a cryostat.
Definition: geo_types.h:192