55 JParser<> zap(
"Example program to check contents of acoustic events.");
57 zap[
'f'] =
make_field(inputFile,
"output of JKatoomba[.sh]");
58 zap[
'n'] =
make_field(numberOfEvents) = JLimit_t::max();
66 catch(
const exception &error) {
67 FATAL(error.what() << endl);
83 STATUS(
"loading input from file(s) " << inputFile <<
"... " << flush);
85 dynamics.load(inputFile);
91 const double Z = cylinder.getZmax() * 0.5;
96 Double_t
xmin = numeric_limits<Double_t>::max();
97 Double_t
xmax = numeric_limits<Double_t>::lowest();
101 if (!string->second.empty()) {
102 xmin = min(
xmin, string->second.getXmin());
103 xmax = max(xmax, string->second.getXmax());
107 const JFormat_t format(4, 0, std::ios_base::fmtflags(),
'0');
109 JManager<int, TH2D> H2(
new TH2D (
"[%].tilt", NULL, 300, -3.0, +3.0, 300, -3.0, +3.0),
'%', format);
117 TH1D* ho = HO[
string->first];
118 TH1D* ha = HA[
string->first];
120 for (Int_t
i = 1;
i <= HO->GetXaxis()->GetNbins(); ++
i) {
122 const Double_t
x = HO->GetXaxis()->GetBinCenter(
i);
131 catch(
const exception& error) {
140 if (string->second.size() > 1) {
142 TH2D* h2 = H2[
string->first];
143 TH1D* ht = HT[
string->first];
147 const double t1 = q->getX() - p->getX();
152 const double tx = 600.0e3 * ((q->getY().tx + q->getY().tx2 *
Z) - (p->getY().tx + p->getY().tx2 *
Z)) / t1;
153 const double ty = 600.0e3 * ((q->getY().ty + q->getY().ty2 *
Z) - (p->getY().ty + p->getY().ty2 *
Z)) / t1;
155 if (t1 > 0 && t1 < Tmax_s) {
162 ZO[
string->first].put(
i->getX(),
i->getY().getAngle());
163 ZA[
string->first].put(
i->getX(),
i->getY().getLength());
171 out << *H2 << H2 << *HT << HT << HO << HA;
Utility class to parse command line options.
double getAngle() const
Get angle.
#define MAKE_CSTRING(A)
Make C-string.
Auxiliary data structure to build TGraph.
data_type::const_iterator const_iterator
Auxiliary class for defining the range of iterations of objects.
Auxiliary class to manage set of compatible ROOT objects (e.g. histograms) using unique keys...
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
set_variable E_E log10(E_{fit}/E_{#mu})"
Auxiliary data structure for sequence of same character.
Dynamic detector calibration.
void load(const std::string &file_name, JDetector &detector)
Load detector from input file.
General purpose class for object reading from a list of file names.
do set_variable MODULE getModule a $WORKDIR detector_a datx L $STRING JEditDetector a $WORKDIR detector_a datx M $MODULE setz o $WORKDIR detector_a datx JEditDetector a $WORKDIR detector_b datx M $MODULE setz o $WORKDIR detector_b datx done echo Output stored at $WORKDIR detector_a datx and $WORKDIR tripod_a txt JDrawDetector2D a $WORKDIR detector_a datx a $WORKDIR detector_b datx L BL o detector $FORMAT $BATCH JDrawDetector2D T $WORKDIR tripod_a txt T $WORKDIR tripod_b txt L BL o tripod $FORMAT $BATCH JCompareDetector a $WORKDIR detector_a datx b $WORKDIR detector_b datx o $WORKDIR abc root &dev null for KEY in X Y Z
const JLimit & getLimit() const
Get limit.
do set_variable DETECTOR_TXT $WORKDIR detector
double getLength() const
Get length.