124   typedef JTriggeredFileScanner_t::multi_pointer_type       multi_pointer_type;
 
  128   JTriggeredFileScanner_t  inputFile;
 
  141     JParser<> zap(
"Program to test JMuonStart.");
 
  143     zap[
'f'] = 
make_field(inputFile,    
"input file (output of JXXXMuonReconstruction.sh)");
 
  145     zap[
'n'] = 
make_field(numberOfEvents)      = JLimit::max();
 
  154   catch(
const exception& error) {
 
  155     FATAL(error.what() << endl);
 
  199   while (inputFile.hasNext()) {
 
  201     STATUS(
"event: " << setw(10) << inputFile.getCounter() << 
'\r'); 
DEBUG(endl);
 
  203     multi_pointer_type ps = inputFile.next();
 
  209     summary.update(*tev);
 
  216         if (muon == event->mc_trks.end() || track->E > muon->E) {
 
  222     if (muon == event->mc_trks.end()) {
 
  226     if (muon->len == 0.0) {
 
  227       muon->len = 
gWater(muon->E);
 
  233     JRange_t za(JRange_t::DEFAULT_RANGE());   
 
  234     JRange_t zb(JRange_t::DEFAULT_RANGE());   
 
  235     JRange_t zd(JRange_t::DEFAULT_RANGE());   
 
  245       za.setLowerLimit(ta.
getZ());
 
  246       za.setLength(fabs(muon->len));
 
  252     buildL0(*tev, moduleRouter, 
true, back_inserter(dataL0));
 
  259       JEvt::const_iterator track = evt->begin();
 
  274         for (buffer_type::const_iterator i = dataL0.begin(); i != dataL0.end(); ++i) {
 
  281             top[hit.getModuleID()].insert(hit.getPMTAddress());
 
  287           double getZ()
 const { 
return z; }
 
  288           double getP()
 const { 
return p; }
 
  296         for (JDetector::const_iterator module = 
detector.begin(); module != 
detector.end(); ++module) {
 
  298           if (summary.hasSummaryFrame(module->getID())) {
 
  304             pos.transform(R, tz.getPosition());
 
  308               const double z = pos.getZ()  -  pos.getX() / 
getTanThetaC();
 
  311               data.push_back({ z, p });
 
  323           if (track_start == 
data. end()) { track_start = 
data. begin(); }
 
  324           if (track_end   == 
data.rend()) { track_end   = 
data.rbegin(); }
 
  326           zd = 
JRange_t(track_start->getZ(), track_end->getZ());
 
  333     H1[
"B"]->Fill(zb.getLength() - za.getLength());
 
  334     H1[
"D"]->Fill(zd.getLength() - za.getLength());
 
  336     H2[
"B"]->Fill(zb.getLowerLimit() - za.getLowerLimit(), zb.getUpperLimit() - za.getUpperLimit());
 
  337     H2[
"D"]->Fill(zd.getLowerLimit() - za.getLowerLimit(), zd.getUpperLimit() - za.getUpperLimit());
 
#define DEBUG(A)
Message macros.
 
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
 
Router for direct addressing of module data in detector data structure.
 
Router for direct addressing of PMT data in detector data structure.
 
Data structure for fit of straight line paralel to z-axis.
 
JAxis3D & rotate(const JRotation3D &R)
Rotate axis.
 
Data structure for position in three dimensions.
 
JPosition3D & rotate(const JRotation3D &R)
Rotate.
 
JTime & add(const JTime &value)
Addition operator.
 
double getZ() const
Get z position.
 
Utility class to parse command line options.
 
File router for fast addressing of summary data.
 
Data structure for L0 hit.
 
Data storage class for rate measurements of all PMTs in one module.
 
static const int JMUONSTART
 
static const int JSTART_LENGTH_METRES
distance between first and last hits in metres from JStart.cc
 
JDirection3D getDirection(const Vec &dir)
Get direction.
 
JTrack3E getTrack(const Trk &track)
Get track.
 
JPosition3D getPosition(const Vec &pos)
Get position.
 
bool is_muon(const Trk &track)
Test whether given track is a (anti-)muon.
 
Vec getOffset(const JHead &header)
Get offset.
 
JAbstractHistogram< double > JHistogram_t
Type definition for scan along axis.
 
void load(const std::string &file_name, JDetector &detector)
Load detector from input file.
 
double getProbability(const size_t N, const size_t M, const JK40Rates &R_Hz, const double T_ns)
Get probability due to random background.
 
double getP(const double expval, bool hit)
Get Poisson probability to observe a hit or not for given expectation value for the number of hits.
 
JComparator< JResult_t T::*, JComparison::lt > make_comparator(JResult_t T::*member)
Helper method to create comparator between values of data member.
 
static const JGeaneWater gWater
Function object for energy loss of muon in sea water.
 
double getTanThetaC()
Get average tangent of Cherenkov angle of water corresponding to group velocity.
 
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
 
std::vector< JHitW0 > buffer_type
hits
 
bool qualitySorter(const JFit &first, const JFit &second)
Comparison of fit results.
 
Head getHeader(const JMultipleFileScanner_t &file_list)
Get Monte Carlo header.
 
KM3NeT DAQ data structures and auxiliaries.
 
const JK40Rates & getK40Rates()
Get K40 rates.
 
The Evt class respresent a Monte Carlo (MC) event as well as an offline event.
 
Type definition of range.
 
Template specialisation of class JModel to match hit with muon trajectory along z-axis.
 
Empty structure for specification of parser element that is initialised (i.e. does not require input)...
 
Auxiliary class for K40 rates.
 
const JRateL1_t & getMultiplesRates() const
Get multiples rate.
 
Data structure for fit parameters.
 
double roadWidth_m
road width [m]
 
size_t numberOfPrefits
number of prefits
 
int Nmax2
maximal number for twofold observations
 
double R_Hz
default rate [Hz]
 
double Pmin1
minimal probability single observation
 
double TMin_ns
minimal time w.r.t. Cherenkov hypothesis [ns]
 
double Pmin2
minimal probability for twofold observations
 
double TMax_ns
maximal time w.r.t. Cherenkov hypothesis [ns]
 
Auxiliary class for start or end point evaluation.
 
Auxiliary class to set-up Hit.
 
Auxiliary class for defining the range of iterations of objects.
 
const JLimit & getLimit() const
Get limit.
 
Auxiliary class to synchronously read DAQ events and Monte Carlo events (and optionally other events)...
 
The Vec class is a straightforward 3-d vector, which also works in pyroot.