35 JParser<> zap(
"Auxiliary program to draw the z-positions of the modules in detector.");
43 catch(
const exception &error) {
44 FATAL(error.what() << endl);
57 const double V = 0.61 *
C;
65 for (JDetector::const_iterator module =
detector.begin(); module !=
detector.end(); ++module) {
67 if (module->getFloor() == 1) {
68 z0[module->getString()] = module->getZ() -
getAverage(
make_array(module->begin(), module->end(), &JPMT::getT0)) *
V;
71 z1[module->getString()][module->getFloor()] = module->getZ();
74 for (JDetector::const_iterator module =
detector.begin(); module !=
detector.end(); ++module) {
76 if (module->getFloor() != 0) {
78 const double ds = module->getZ() -
getAverage(
make_array(module->begin(), module->end(), &JPMT::getT0)) *
V - z0[module->getString()];
80 HA[module->getString()].put((Double_t) module->getFloor(), module->getZ());
81 H1[module->getString()]->Fill(ds);
93 for (
auto&
string : z1) {
97 for (
auto& module :
string.second) {
98 if (module.first > 0 &&
string.second.count(module.first - 1) != 0) {
99 g1.
put((Double_t) module.first, module.second -
string.second[module.first - 1]);
Utility class to parse command line options.
void put(const Double_t x, const Double_t y)
Put data.
Data structure for graph data.
std::iterator_traits< T >::value_type getAverage(T __begin, T __end)
Get average.
#define MAKE_CSTRING(A)
Make C-string.
Empty structure for specification of parser element that is initialised (i.e. does not require input)...
Auxiliary data structure to build TGraph.
V(JDAQEvent-JTriggerReprocessor)*1.0/(JDAQEvent+1.0e-10)
then echo The file $DIR KM3NeT_00000001_00000000 root already please rename or remove it first
static const double C
Physics constants.
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
const array_type< JValue_t > & make_array(const JValue_t(&array)[N])
Method to create array of values.
void load(const std::string &file_name, JDetector &detector)
Load detector from input file.
do set_variable DETECTOR_TXT $WORKDIR detector
Double_t g1(const Double_t x)
Function.