Jpp - the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Classes | Typedefs | Functions | Variables
JDETECTOR Namespace Reference

Auxiliary classes and methods for detector calibration. More...

Classes

class  JAnchor
 Data structure for anchor position on sea bed. More...
 
class  JCalibration
 Data structure for time calibration. More...
 
struct  JCalibrator
 Auxiliary class to apply (de-)calibration to template hit. More...
 
struct  JCalibrator< T, true >
 Template specialisation of JCalibrator for primitive data types. More...
 
struct  JCalibrator< JHit_t, false >
 Template specialisation of JCalibrator for non-primitive data types. More...
 
class  JTransferFunction1D
 Auxiliary class for a non-linear transfer function of TDC inside FPGA. More...
 
class  JCLBDefaultSimulator
 Default CLB simulation. More...
 
class  JCLBDefaultSimulatorInterface
 Default CLB simulation. More...
 
struct  JCLBInput
 Wrapper for CLB input. More...
 
class  JCLBSimulator
 Interface for CLB simulation. More...
 
class  JCompass
 Data structure for compass in three dimensions. More...
 
class  JDAQHitRouter
 Simple wrapper around JModuleRouter class for direct addressing of PMT data in detector data structure for DAQ hits. More...
 
class  JDetector
 Detector data structure. More...
 
class  JDetectorAddressMap
 Lookup table for PMT addresses in detector. More...
 
struct  JPPM_DU_t
 Type definitions for different detectors.PPM_DU. More...
 
struct  JKM3NeT_t
 KM3NeT More...
 
struct  JMonteCarlo_t
 Monte Carlo .detx file. More...
 
struct  JObsolete_t
 obsolete detector More...
 
class  JTemplateDetectorAddressMap
 Template lookup table for PMT addresses in detector. More...
 
class  JTemplateDetectorAddressMap< JObsolete_t >
 Template specialisation of JTemplateDetectorAddressMap for obsolete detector. More...
 
class  JTemplateDetectorAddressMap< JPPM_DU_t >
 Template specialisation of JTemplateDetectorAddressMap for PPM_DU detector. More...
 
class  JTemplateDetectorAddressMap< JKM3NeT_t >
 Template specialisation of JTemplateDetectorAddressMap for KM3NeT detector. More...
 
class  JTemplateDetectorAddressMap< JMonteCarlo_t >
 Template specialisation of JTemplateDetectorAddressMap for Monte Carlo detector. More...
 
struct  JDetectorAddressMap_t
 Auxiliary class to extract detector address map from detector identifier. More...
 
struct  JDetectorAddressMap_t< JTypeList< JHead_t, JTail_t > >
 
struct  JDetectorAddressMap_t< JTypeList< JHead_t, JNullType > >
 
struct  JPMTCalibration_t
 Auxiliary data structure for PMT time calibration. More...
 
struct  JHVCalibration_t
 Data structure for PMT high-voltage calibration. More...
 
struct  JTHCalibration_t
 Data structure for PMT threshold calibration. More...
 
struct  JModulePosition_t
 Auxiliary data structure for module position. More...
 
struct  JModuleRotation_t
 Auxiliary data structure for module rotation. More...
 
class  JDetectorHeader
 Data structure for detector header. More...
 
class  JDetectorParameters
 Data structure for parameters for detector geometry. More...
 
class  JDetectorParametersHelper
 Auxiliary class for I/O of JDetectorParameters data structure. More...
 
class  JDetectorSimulator
 Detector simulation. More...
 
class  JDetectorSubset_t
 Detector subset without binary search functionality. More...
 
class  JDetectorSubset
 Detector subset with binary search functionality. More...
 
struct  JRotation
 Auxiliary class to get rotation matrix between two optical modules. More...
 
struct  JDetectorVersion
 Detector version. More...
 
struct  JGetDetectorVersion
 Auxiliary class to map detector variant to detector version. More...
 
struct  JPutDetectorVersion
 Auxiliary class to map detector version to detector variant. More...
 
struct  JHydrophone
 Type definition of hydrophone. More...
 
class  JK40DefaultSimulator
 Default implementation of the simulation of K40 background. More...
 
class  JK40DefaultSimulatorInterface
 Default K40 simulator interface. More...
 
class  JK40Simulator
 Interface for simulation of K40 background. More...
 
class  JLocation
 Logical location of module. More...
 
class  JModule
 Data structure for a composite optical module. More...
 
class  JModuleAddress
 Address of module in detector data structure. More...
 
struct  JPMTAddressTranslator
 Data structure to translate PMT physical to readout address. More...
 
class  JModuleAddressMap
 Lookup table for PMT addresses in optical module. More...
 
struct  JModuleComparator3Z_t
 Module comparator according its z-position. More...
 
struct  JModuleComparator3D_t
 Module comparator according its distance to origin. More...
 
class  JModuleGeometry
 Module geometry. More...
 
struct  JUTCDistance
 Auxiliary class for distance beteen UTC times. More...
 
struct  JModuleAttributes
 Data structure for module address and module attributes. More...
 
struct  JMaximalDistance
 Auxiliary class to match modules according maximal distance. More...
 
class  JModuleMapper
 Mapper for directly addressing of associated modules in the detector data structure. More...
 
class  JModuleRouter
 Router for direct addressing of module data in detector data structure. More...
 
class  JMonteCarloDetector
 Monte Carlo detector (i.e. so-called .det file). More...
 
class  JPMT
 Data structure for PMT geometry and calibration. More...
 
class  JPMTAddress
 Address of PMT in detector data structure. More...
 
struct  JPMTAnalogueSignalProcessor
 PMT analogue signal processor. More...
 
class  JPMTChannel
 Auxiliary class to uniquely identify PMT readout channel. More...
 
struct  JModuleAnalogueSignalProcessor
 Auxiliary container for PMT analogue signal processors in same optical module. More...
 
class  JPMTDefaultSimulator
 Default PMT simulation. More...
 
class  JPMTDefaultSimulatorInterface
 Default PMT simulation interface. More...
 
class  JPMTIdentifier
 PMT identifier. More...
 
class  JPMTParameters
 Data structure for PMT parameters. More...
 
class  JPMTParametersMap
 Auxiliary class for map of PMT parameters. More...
 
class  JPMTPhysicalAddress
 Data structure for PMT physical address. More...
 
struct  JPMTRateRange
 Data structure for range of PMT rates. More...
 
class  JPMTReadoutAddress
 Data structure for PMT readout address. More...
 
class  JPMTRouter
 Router for direct addressing of PMT data in detector data structure. More...
 
class  JPMTSignalProcessorInterface
 PMT signal processor interface. More...
 
struct  JPhotoElectron
 Data structure for single photo-electron. More...
 
struct  JPMTSignal
 Data structure for PMT analogue signal. More...
 
struct  JPMTPulse
 Data structure for PMT digital pulse. More...
 
class  JPMTData
 Template data structure for PMT I/O. More...
 
class  JModuleData
 Data structure for PMT data corresponding to a detector module. More...
 
class  JPMTSimulator
 Interface for PMT simulation. More...
 
struct  JTransitionTimeGenerator_t
 Auxiliary base class to generate PMT transition times based on measurements. More...
 
struct  JTransitionTimeGenerator
 Implementation to generate PMT transition times based on measurements by Oleg Kalekin et al. (see also examples/JDetector/JTTS.cc). More...
 
struct  JTransitionTimeGenerator38
 Implementation to generate PMT transition times based on measurements. More...
 
struct  JTransitionTimeGenerator41
 Implementation to generate PMT transition times based on measurements. More...
 
struct  JTransitionTimeGeneratorXX
 Implementation to generate PMT transition times based on measurements. More...
 
struct  JTransitionTimeProbability_t
 Auxiliary base class for probability distibution of the PMT transition times based on measurements. More...
 
struct  JTransitionTimeProbability
 Implementation of probability distibution of the PMT transition times based on measurements by Oleg Kalekin et al. More...
 
struct  JTransitionTimeProbability38
 Implementation of probability distibution of the PMT transition times based on measurements. More...
 
struct  JTransitionTimeProbability41
 Implementation of probability distibution of the PMT transition times based on measurements. More...
 
struct  JTransitionTimeProbabilityXX
 Implementation of probability distibution of the PMT transition times based on measurements. More...
 
class  JTransitionTimeProbability2D
 Auxiliary class to generate twofold PMT transition times. More...
 
struct  JStatus
 Auxiliary class for controlling PMT status. More...
 
struct  JGetPMTStatusBit
 Auxiliary class to map key to PMT status bit. More...
 
struct  JPutPMTStatusBit
 Auxiliary class to map PMT status bit to key. More...
 
struct  JStringCounter
 Auxiliary class for counting unique strings. More...
 
struct  JStringRouter
 Router for mapping of string identifier to index. More...
 
class  JTripod
 Data structure for tripod. More...
 
struct  JVersion
 Auxiliary class for version identifier. More...
 

Typedefs

typedef JPMTData< JPMTPulseJPMTOutput
 Type definition of PMT base output. More...
 
typedef JTYPELIST< JPPM_DU_t,
JKM3NeT_t, JMonteCarlo_t >
::typelist 
JDetectorTypes_t
 Type list of detector types. More...
 
typedef std::vector
< JHVCalibration_t
JHVCalibration
 PMT high voltage calibration. More...
 
typedef std::vector
< JTHCalibration_t
JTHCalibration
 PMT threshold calibration. More...
 
typedef std::vector
< JPMTCalibration_t
JPMTCalibration
 PMT time calibration. More...
 
typedef std::vector
< JModulePosition_t
JModulePosition
 Module position. More...
 
typedef std::vector
< JModuleRotation_t
JModuleRotation
 Module rotation. More...
 
typedef JLANG::JComparator
< double(JVector3D::*)() const > 
JModuleComparator
 Type definition of a module comparator using 3D position information. More...
 
typedef JLANG::JObjectID JModuleIdentifier
 
typedef std::map
< JPMTIdentifier,
JPMTParameters
JPMTParametersMap_t
 Type definition of map PMT identifier to PMT parameters. More...
 

Functions

bool operator< (const JAnchor &first, const JAnchor &second)
 Sort anchors in ascending distance from (0,0). More...
 
template<class T >
double getTime (const T &t1, const JCalibration &cal)
 Get calibrated time. More...
 
template<class T >
double putTime (const T &t1, const JCalibration &cal)
 Get de-calibrated time. More...
 
template<class T >
double getToT (const T &tot, const JCalibration &cal)
 Get calibrated time-over-threshold of hit. More...
 
template<class T >
double putToT (const T &tot, const JCalibration &cal)
 Get de-calibrated time-over-threshold of hit. More...
 
bool hasDetector (JType< JPPM_DU_t > type, const int id)
 Check validity of detector identifier. More...
 
bool hasDetector (JType< JKM3NeT_t > type, const int id)
 
bool hasDetector (JType< JMonteCarlo_t > type, const int id)
 
template<class JDetector_t >
JDetectorAddressMapgetDetectorAddressMap ()
 Get detector address map. More...
 
template<class JDetector_t >
JModuleAddressMapgetModuleAddressMap (int id)
 Get module address map. More...
 
template<class JDetector_t >
const JPMTAddressTranslatorgetPMTAddressTranslator (int id, int tdc)
 Get PMT address translator for given module identifier and TDC channel. More...
 
template<class JDetector_t >
int getPMTLogicalIndex (int id, int tdc)
 Get PMT logical index for given module identifier and TDC channel. More...
 
JDetectorAddressMapgetDetectorAddressMap (const int id)
 Get detector address map. More...
 
bool hasDetectorAddressMap (const int id)
 Check if detector address map is available. More...
 
bool is_valid (const json &js)
 Check validity of JSon data. More...
 
template<class T >
std::vector< std::string > get_string_array (T value)
 Cast single value to array of strings, conform the DB-format. More...
 
double retrieve_value (std::vector< std::string > string_value_array)
 Retrieve value from json array of strings. More...
 
void to_json (json &js, const JPMTCalibration_t &object)
 Convert PMT time calibration to JSon. More...
 
void from_json (const json &js, JPMTCalibration_t &object)
 Convert JSon to PMT time calibration. More...
 
void to_json (json &js, const JHVCalibration_t &object)
 Convert PMT high-voltage calibration to JSon. More...
 
void from_json (const json &js, JHVCalibration_t &object)
 Convert JSon to PMT high-voltage calibration. More...
 
void to_json (json &js, const JTHCalibration_t &object)
 Convert PMT threshold calibration to JSon. More...
 
void from_json (const json &js, JTHCalibration_t &object)
 Convert JSon to PMT threshold calibration. More...
 
void to_json (json &js, const JModulePosition_t &object)
 Convert module position to JSon. More...
 
void from_json (const json &js, JModulePosition_t &object)
 Convert JSon to module position. More...
 
void to_json (json &js, const JModuleRotation_t &object)
 Convert module rotation to JSon. More...
 
void from_json (const json &js, JModuleRotation_t &object)
 Convert JSon to module rotation. More...
 
JDetectorHeader getARCADetectorHeader ()
 Get detector header for ARCA. More...
 
JDetectorHeader getORCADetectorHeader ()
 Get detector header for ORCA. More...
 
bool isARCADetector (const JDetectorHeader &header)
 Check if given detector header is compatible with tat of ARCA. More...
 
bool isORCADetector (const JDetectorHeader &header)
 Check if given detector header is compatible with that of ORCA. More...
 
JPosition3D getPiezoPosition ()
 Get relative position of piezo in optical module. More...
 
double getMaximalDistance (const JDetector &detector)
 Get maximal distance between modules in detector. More...
 
double GetXrotationG4 (const JVersor3D dir)
 Get rotation over X axis in Geant4 coordinate system. More...
 
double GetYrotationG4 (const JVersor3D dir)
 Get rotation over Y axis in Geant4 coordinate system. More...
 
void read_gdml (std::istream &, JDetector &)
 
void write_gdml (std::ostream &out, const JDetector &detector)
 Writes KM3Sim GDML input file from detector. More...
 
double getMaximalTime (const JDetector &detector)
 Get maximal time between modules in detector following causality. More...
 
double getMaximalTime (const JDetector &detector, const double roadWidth_m)
 Get maximal time between modules in detector following causality. More...
 
JTimeRange getTimeRange (const JTimeRange &timeRange, const JModule &module)
 Get de-calibrated time range. More...
 
int getNumberOfPMTs (const JModule &module)
 Get number of PMTs. More...
 
int getNumberOfPMTs (const JDetector &detector)
 Get number of PMTs. More...
 
std::set< int > getStringIDs (const JDetector &detector)
 Get list of strings IDs. More...
 
int getNumberOfFloors (const JDetector &detector)
 Get number of floors. More...
 
int getNumberOfModules (const JDetector &detector)
 Get number of modules. More...
 
void load (const std::string &file_name, JDetector &detector)
 Load detector from input file. More...
 
void store (const std::string &file_name, const JDetector &detector)
 Store detector to output file. More...
 
const JModulegetModule (const JModuleAddressMap &memo, const int id=-1, const JLocation &location=JLocation())
 Get module according module address map. More...
 
const JModulegetModule (const int id, const JLocation &location=JLocation())
 Get module corresponding to Antares storey. More...
 
JPosition3D getPosition (const JModule &first, const JModule &second)
 Get position to go from first to second module. More...
 
JCalibration getCalibration (const JCalibration &first, const JCalibration &second)
 Get calibration to go from first to second calibration. More...
 
std::vector< std::string > getDetectorVersions (const JType< std::string > &type)
 Get detector versions. More...
 
std::vector
< JDetectorVersion::JVersion_t
getDetectorVersions (const JType< JDetectorVersion::JVersion_t > &type)
 Get detector versions. More...
 
template<class T >
std::vector< TgetDetectorVersions ()
 Get detector versions. More...
 
std::string getLatestDetectorVersion (const JType< std::string > &type)
 Get latest detector version. More...
 
JDetectorVersion::JVersion_t getLatestDetectorVersion (const JType< JDetectorVersion::JVersion_t > &type)
 Get latest detector version. More...
 
template<class T >
T getLatestDetectorVersion ()
 Get latest detector version. More...
 
std::string getLabel (const JLocation &location)
 Get module label for monitoring and other applications. More...
 
template<class JAttributes_t >
void setAttributes (const JModule &first, const JModule &second, JAttributes_t &attributes)
 Template method to set module attributes. More...
 
template<>
void setAttributes< JNullType > (const JModule &first, const JModule &second, JNullType &attributes)
 Template specialisation to set no attributes for the default empty object. More...
 
double getTimeOverThresholdProbability (const JPMTAnalogueSignalProcessor &pmt, const double tot_ns, const double NPE, const double precision=1.0e-4)
 Get time-over-threshold probability. More...
 
bool operator< (const JPMTIdentifier &first, const JPMTIdentifier &second)
 Less than operator for PMT identifiers. More...
 
bool operator== (const JPMTIdentifier &first, const JPMTIdentifier &second)
 Equal operator for PMT identifiers. More...
 
std::string getLabel (const JPMTIdentifier &id)
 Get PMT label for monitoring and other applications. More...
 
double getSurvivalProbability (const JPMTParameters &parameters)
 Get model dependent probability that a one photo-electron hit survives the simulation of the PMT assuming QE = 1. More...
 
double getHitProbability (const double QE, const double mu)
 Get ratio of hit probabilities for given QE and expectation value of the number of photo-electrons. More...
 
double getMaximalHitProbability (const double mu)
 Get maximal ratio of hit probabilities for given QE and expectation value of the number of photo-electrons. More...
 
double getQE (const double R, const double mu)
 Get QE for given ratio of hit probabilities and expectation value of the number of photo-electrons. More...
 
double getChargeProbability (const JPMTSignalProcessorInterface &pmt, const double npe, const double NPE, const double precision=1.0e-4)
 Get charge probability. More...
 
bool operator< (const JPhotoElectron &first, const JPhotoElectron &second)
 Less than operator for photo-elecrons. More...
 
bool operator< (const JPMTSignal &first, const JPMTSignal &second)
 Less than operator for PMT signals. More...
 
bool operator< (const JPMTPulse &first, const JPMTPulse &second)
 Less than operator for PMT pulses. More...
 
JTimeRange getTimeRange (const JPMTData< JPMTSignal > &input)
 Get time range (i.e. earlist and latest hit time) of PMT data. More...
 
JTimeRange getTimeRange (const JModuleData &input)
 Get time range (i.e. earlist and latest hit time) of module data. More...
 
std::vector< std::string > getPMTStatusBits (const JType< std::string > &type)
 Get PMT status bits. More...
 
std::vector< int > getPMTStatusBits (const JType< int > &type)
 Get PMT status bits. More...
 
template<class T >
std::vector< TgetPMTStatusBits ()
 Get PMT status bits. More...
 
bool operator< (const JVersion &first, const JVersion &second)
 Less-than operator for versions. More...
 

Variables

const double TIME_OVER_THRESHOLD_NS = 25.08
 Specification for time-over-threshold corresponding to a one photo-electron pulse. More...
 
const double NOMINAL_GAIN = 1.0
 Specification for normalized gain corresponding to a one photo-electron pulse. More...
 
static const std::string User_t = "User"
 Detector calibration key words for JSON I/O. More...
 
static const std::string Location_t = "Location"
 
static const std::string StartTime_t = "StartTime"
 
static const std::string EndTime_t = "EndTime"
 
static const std::string Comment_t = "Comment"
 
static const std::string UUID_t = "UUID"
 
static const std::string Type_t = "Type"
 
static const std::string Parameters_t = "Parameters"
 
static const std::string Tests_t = "Tests"
 
static const std::string Data_t = "Data"
 
static const std::string RunNumber_t = "RUN_NUMBER"
 
static const std::string Name_t = "Name"
 
static const std::string Unit_t = "Unit"
 
static const std::string Values_t = "Values"
 
static const std::string PMTT0s_t = "PMTT0s"
 
static const std::string PMTSupplyVoltage_t = "PMT_Supply_Voltage"
 
static const std::string PMTThreshold_t = "PMT_Threshold"
 
static const std::string PMTGain_t = "PMT_Gain"
 
static const std::string DOMPositions_t = "DOMPositions"
 
static const std::string DOMRotations_t = "DOMRotations"
 
static const std::string Test_t = "Test"
 
static const std::string Target_t = "Target"
 
static const std::string Outcome_t = "Outcome"
 
static const std::string UPI_t = "UPI"
 
static const std::string PBS_t = "PBS"
 
static const std::string Variant_t = "Variant"
 
static const std::string PMTSerial_t = "PMTSerial"
 
static const std::string DOMSerial_t = "DOMSerial"
 
static const std::string DOMId_t = "DOMId"
 
static const std::string T0_t = "T0"
 
static const std::string PX_t = "PX"
 
static const std::string PY_t = "PY"
 
static const std::string PZ_t = "PZ"
 
static const std::string Q0_t = "Q0"
 
static const std::string QX_t = "QX"
 
static const std::string QY_t = "QY"
 
static const std::string QZ_t = "QZ"
 
static const std::string Unitless_t = "-"
 
static const std::string Volt_t = "V"
 
static const std::string Result_t = "Result"
 
static const std::string OK_t = "OK"
 
static const std::string Failed_t = "FAILED"
 
static const double PIEZO_DELAYTIME_US = 170.0
 Piezo delay time [us]. More...
 
static const double HYDROPHONE_DELAYTIME_US = 50.0
 Hydrophone delay time [us]. More...
 
static const double TBARZ_M = 1.0
 T-bar position relative to seabed [m]. More...
 
static const char *const GENDET_DETECTOR_FILE_FORMAT = "det"
 File name extensions. More...
 
static const char *const BINARY_DETECTOR_FILE_FORMAT = "dat"
 JIO binary file format. More...
 
static const char *const KM3NET_DETECTOR_FILE_FORMAT = "detx"
 KM3NeT standard ASCII format More...
 
static const char *const ZIPPED_DETECTOR_FILE_FORMAT = "gz"
 zipped KM3NeT standard ASCII format More...
 
static const char *const GDML_DETECTOR_FILE_FORMAT = "gdml"
 KM3Sim input format. More...
 
static const char *const GDML_SCHEMA = getenv("GDML_SCHEMA_DIR")
 directory necessary for correct GDML header output More...
 
static const char *const CAN_MARGIN_M = getenv("CAN_MARGIN_M")
 extension of the detector size to comply with the can definition More...
 
static const char *const G4GDML_DEFAULT_SCHEMALOCATION = "http://service-spi.web.cern.ch/service-spi/app/releases/GDML/schema/gdml.xsd"
 
static JRotation getRotation
 Function object to get rotation matrix to go from first to second module. More...
 
static const JGetDetectorVersion getDetectorVersion
 Function object to map detector variant to detector version. More...
 
static const JPutDetectorVersion putDetectorVersion (getDetectorVersion)
 Function object to map detector version to detector variant. More...
 
static const int LED_BEACON_PMT_TYPE = 2
 PMT type of LED beacon. More...
 
const JTransitionTimeGenerator38 p38
 
const JTransitionTimeGenerator41 p41
 
 getTransitionTime
 Function object to generate transition time. More...
 
 getTransitionTimeProbability
 Function object of transition time prabability. More...
 
static const
JTransitionTimeProbability2D 
getTransitionTimeProbability2D
 Function object of twofold transition time prabability. More...
 
static const JGetPMTStatusBit getPMTStatusBit
 Function object to map key to PMT status bit. More...
 
static const JPutPMTStatusBit putPMTStatusBit (getPMTStatusBit)
 Function object to map PMT status bit to key. More...
 
static const JStringCounter getNumberOfStrings
 Function object to count unique strings. More...
 

Detailed Description

Auxiliary classes and methods for detector calibration.

Auxiliary classes and methods for detector calibration and simulation.

Author
mdejong

Typedef Documentation

Type definition of PMT base output.

Definition at line 27 of file JCLBSimulator.hh.

Type list of detector types.

Definition at line 42 of file JDetectorAddressMapToolkit.hh.

PMT high voltage calibration.

Definition at line 459 of file JDetectorCalibration.hh.

PMT threshold calibration.

Definition at line 460 of file JDetectorCalibration.hh.

PMT time calibration.

Definition at line 461 of file JDetectorCalibration.hh.

Module position.

Definition at line 462 of file JDetectorCalibration.hh.

Module rotation.

Definition at line 463 of file JDetectorCalibration.hh.

typedef JLANG::JComparator<double (JVector3D::*)() const> JDETECTOR::JModuleComparator

Type definition of a module comparator using 3D position information.

Definition at line 22 of file JModuleComparator.hh.

Definition at line 16 of file JModuleIdentifier.hh.

Type definition of map PMT identifier to PMT parameters.

Definition at line 47 of file JPMTParametersMap.hh.

Function Documentation

bool JDETECTOR::operator< ( const JAnchor first,
const JAnchor second 
)
inline

Sort anchors in ascending distance from (0,0).

Parameters
firstfirst anchor
secondsecond anchor
Returns
true if first anchor closer to (0,0); else false

Definition at line 99 of file JAnchor.hh.

100  {
101  return first.getLengthSquared() < second.getLengthSquared();
102  }
double getLengthSquared() const
Get length squared.
Definition: JVector2D.hh:188
template<class T >
double JDETECTOR::getTime ( const T t1,
const JCalibration cal 
)
inline

Get calibrated time.

Parameters
t1time [ns]
calcalibration
Returns
time [ns]

Definition at line 211 of file JDetector/JCalibration.hh.

212  {
213  return JCalibrator<T>::getTime(t1, cal);
214  }
double getTime(const Hit &hit)
Get true time of hit.
template<class T >
double JDETECTOR::putTime ( const T t1,
const JCalibration cal 
)
inline

Get de-calibrated time.

Parameters
t1time [ns]
calcalibration
Returns
time [ns]

Definition at line 225 of file JDetector/JCalibration.hh.

226  {
227  return JCalibrator<T>::putTime(t1, cal);
228  }
double putTime(const T &t1, const JCalibration &cal)
Get de-calibrated time.
template<class T >
double JDETECTOR::getToT ( const T tot,
const JCalibration cal 
)
inline

Get calibrated time-over-threshold of hit.

Parameters
tottime-over-threshold [ns]
calcalibration
Returns
time-over-threshold [ns]

Definition at line 239 of file JDetector/JCalibration.hh.

240  {
241  return JCalibrator<T>::getToT(tot, cal);
242  }
double getToT(const T &tot, const JCalibration &cal)
Get calibrated time-over-threshold of hit.
template<class T >
double JDETECTOR::putToT ( const T tot,
const JCalibration cal 
)
inline

Get de-calibrated time-over-threshold of hit.

Parameters
tottime-over-threshold [ns]
calcalibration
Returns
time-over-threshold [ns]

Definition at line 253 of file JDetector/JCalibration.hh.

254  {
255  return JCalibrator<T>::putToT(tot, cal);
256  }
double putToT(const T &tot, const JCalibration &cal)
Get de-calibrated time-over-threshold of hit.
bool JDETECTOR::hasDetector ( JType< JPPM_DU_t type,
const int  id 
)
inline

Check validity of detector identifier.

Parameters
typedetector type
iddetector identifier
Returns
true if valid match; else false

Definition at line 52 of file JDetectorAddressMapToolkit.hh.

52 { return id == 1; }
bool JDETECTOR::hasDetector ( JType< JKM3NeT_t type,
const int  id 
)
inline

Definition at line 53 of file JDetectorAddressMapToolkit.hh.

53 { return id >= 2 && id <= 100000; }
bool JDETECTOR::hasDetector ( JType< JMonteCarlo_t type,
const int  id 
)
inline

Definition at line 54 of file JDetectorAddressMapToolkit.hh.

54 { return id >= -100000 && id <= -2; }
template<class JDetector_t >
JDetectorAddressMap& JDETECTOR::getDetectorAddressMap ( )
inline

Get detector address map.

Returns
detector address map

Definition at line 363 of file JDetectorAddressMapToolkit.hh.

364  {
366 
367  return demo;
368  }
Template lookup table for PMT addresses in detector.
template<class JDetector_t >
JModuleAddressMap& JDETECTOR::getModuleAddressMap ( int  id)
inline

Get module address map.

Parameters
idmodule identifier
Returns
module address map

Definition at line 378 of file JDetectorAddressMapToolkit.hh.

379  {
380  return getDetectorAddressMap<JDetector_t>().get(id);
381  }
template<class JDetector_t >
const JPMTAddressTranslator& JDETECTOR::getPMTAddressTranslator ( int  id,
int  tdc 
)
inline

Get PMT address translator for given module identifier and TDC channel.

Parameters
idmodule identifier
tdcTDC
Returns
PMT address translator

Definition at line 392 of file JDetectorAddressMapToolkit.hh.

393  {
394  return getModuleAddressMap<JDetector_t>(id).getAddressTranslator(tdc);
395  }
template<class JDetector_t >
int JDETECTOR::getPMTLogicalIndex ( int  id,
int  tdc 
)
inline

Get PMT logical index for given module identifier and TDC channel.

Parameters
idmodule identifier
tdcTDC
Returns
PMT logical index

Definition at line 406 of file JDetectorAddressMapToolkit.hh.

407  {
408  return getModuleAddressMap<JDetector_t>(id).getIndex(tdc);
409  }
int getIndex()
Get index for user I/O manipulation.
Definition: JManip.hh:26
JDetectorAddressMap& JDETECTOR::getDetectorAddressMap ( const int  id)
inline

Get detector address map.

Parameters
iddetector identifier
Returns
detector address map

Definition at line 487 of file JDetectorAddressMapToolkit.hh.

488  {
490  }
T get(const JHead &header)
Get object from header.
bool JDETECTOR::hasDetectorAddressMap ( const int  id)
inline

Check if detector address map is available.

Parameters
iddetector identifier
Returns
true if detector address map available; else false

Definition at line 499 of file JDetectorAddressMapToolkit.hh.

500  {
502  }
Auxiliary class to extract detector address map from detector identifier.
bool JDETECTOR::is_valid ( const json js)
inline

Check validity of JSon data.

Parameters
jsJSon data
Returns
true if valid; else false

Definition at line 103 of file JDetectorCalibration.hh.

104  {
105  return js.contains(Result_t) && js[Result_t] == OK_t;
106  }
static const std::string OK_t
static const std::string Result_t
template<class T >
std::vector<std::string> JDETECTOR::get_string_array ( T  value)
inline

Cast single value to array of strings, conform the DB-format.

Parameters
valuevalue
Returns
std::vector containing value casted to string

Definition at line 116 of file JDetectorCalibration.hh.

117  {
118  using namespace std;
119 
120  return vector<string>{ to_string(value) };
121  }
std::string to_string(const T &value)
Convert value to string.
double JDETECTOR::retrieve_value ( std::vector< std::string >  string_value_array)
inline

Retrieve value from json array of strings.

Parameters
string_value_arrayarray of string-casted values
Returns
double-casted value

Definition at line 130 of file JDetectorCalibration.hh.

131  {
132  return std::stod(string_value_array[0]);
133  }
void JDETECTOR::to_json ( json js,
const JPMTCalibration_t object 
)
inline

Convert PMT time calibration to JSon.

Parameters
jsjson
objectPMT time calibration

Definition at line 170 of file JDetectorCalibration.hh.

171  {
172  js = json{ { PMTSerial_t, object.getID() },
173  { T0_t, object.getT0() } };
174  }
static const std::string T0_t
static const std::string PMTSerial_t
nlohmann::json json
void JDETECTOR::from_json ( const json js,
JPMTCalibration_t object 
)
inline

Convert JSon to PMT time calibration.

Parameters
jsjson
objectPMT time calibration

Definition at line 183 of file JDetectorCalibration.hh.

184  {
185  object.setID(js.at(PMTSerial_t).get<int>());
186 
187  object.setT0(js.at(T0_t).get<double>());
188  }
static const std::string T0_t
static const std::string PMTSerial_t
void JDETECTOR::to_json ( json js,
const JHVCalibration_t object 
)
inline

Convert PMT high-voltage calibration to JSon.

Parameters
jsjson
objectPMT high-voltage calibration

Definition at line 230 of file JDetectorCalibration.hh.

231  {
232  std::ostringstream os;
233 
234  os << object.getUPI();
235 
236  js[UPI_t] = os.str();
237  js[Test_t + Result_t] = object.result;
239  { Unit_t, Volt_t },
240  { Values_t, get_string_array(object.supplyVoltage) } };
241  }
static const std::string Name_t
static const std::string PMTSupplyVoltage_t
static const std::string Unit_t
static const std::string UPI_t
static const std::string Result_t
static const std::string Volt_t
static const std::string Test_t
static const std::string Values_t
nlohmann::json json
static const std::string Parameters_t
std::vector< std::string > get_string_array(T value)
Cast single value to array of strings, conform the DB-format.
void JDETECTOR::from_json ( const json js,
JHVCalibration_t object 
)
inline

Convert JSon to PMT high-voltage calibration.

Parameters
jsjson
objectPMT high-voltage calibration

Definition at line 250 of file JDetectorCalibration.hh.

251  {
252  using namespace std;
253 
254  stringstream is(js.at(UPI_t).get<string>());
255 
256  is >> static_cast<JUPI_t&>(object);
257 
258  object.result = js.at(Test_t + Result_t).get<string>();
259  object.supplyVoltage = retrieve_value(js.at(Test_t + Parameters_t)[0].at(Values_t).get<vector<string>>());
260  }
static const std::string UPI_t
double retrieve_value(std::vector< std::string > string_value_array)
Retrieve value from json array of strings.
is
Definition: JDAQCHSM.chsm:167
static const std::string Result_t
static const std::string Test_t
static const std::string Values_t
static const std::string Parameters_t
void JDETECTOR::to_json ( json js,
const JTHCalibration_t object 
)
inline

Convert PMT threshold calibration to JSon.

Parameters
jsjson
objectPMT threshold calibration

Definition at line 304 of file JDetectorCalibration.hh.

305  {
306  std::ostringstream os;
307 
308  os << object.getUPI();
309 
310  js[UPI_t] = os.str();
311  js[Test_t + Result_t] = object.result;
312  js[Test_t + Parameters_t][0] = json{ { Name_t, PMTThreshold_t },
313  { Unit_t, Unitless_t },
314  { Values_t, get_string_array(object.threshold) } };
315  js[Test_t + Parameters_t][2] = json{ { Name_t, RunNumber_t },
316  { Unit_t, Unitless_t },
317  { Values_t, object.runNumberList } };
318  }
static const std::string Name_t
static const std::string Unit_t
static const std::string UPI_t
static const std::string Result_t
static const std::string PMTThreshold_t
static const std::string Test_t
static const std::string RunNumber_t
static const std::string Values_t
nlohmann::json json
static const std::string Parameters_t
static const std::string Unitless_t
std::vector< std::string > get_string_array(T value)
Cast single value to array of strings, conform the DB-format.
void JDETECTOR::from_json ( const json js,
JTHCalibration_t object 
)
inline

Convert JSon to PMT threshold calibration.

Parameters
jsjson
objectPMT threshold calibration

Definition at line 327 of file JDetectorCalibration.hh.

328  {
329  using namespace std;
330 
331  stringstream is(js.at(UPI_t).get<string>());
332 
333  is >> static_cast<JUPI_t&>(object);
334 
335  object.result = js.at(Test_t + Result_t).get<string>();
336  object.threshold = retrieve_value(js.at(Test_t + Parameters_t)[0].at(Values_t).get<vector<string>>());
337  object.runNumberList = js.at(Test_t + Parameters_t)[2].at(Values_t).get<vector<string>>();
338  }
static const std::string UPI_t
double retrieve_value(std::vector< std::string > string_value_array)
Retrieve value from json array of strings.
is
Definition: JDAQCHSM.chsm:167
static const std::string Result_t
static const std::string Test_t
static const std::string Values_t
static const std::string Parameters_t
void JDETECTOR::to_json ( json js,
const JModulePosition_t object 
)
inline

Convert module position to JSon.

Parameters
jsjson
objectmodule position

Definition at line 375 of file JDetectorCalibration.hh.

376  {
377  js = json{ { DOMId_t, object.getID() },
378  { PX_t, object.getX() },
379  { PY_t, object.getY() },
380  { PZ_t, object.getZ() } };
381  }
static const std::string PZ_t
static const std::string DOMId_t
static const std::string PX_t
static const std::string PY_t
nlohmann::json json
void JDETECTOR::from_json ( const json js,
JModulePosition_t object 
)
inline

Convert JSon to module position.

Parameters
jsjson
objectmodule position

Definition at line 390 of file JDetectorCalibration.hh.

391  {
392  object.setID(js.at(DOMId_t).get<int>());
393 
394  object.setPosition(JPosition3D(js.at(PX_t).get<double>(),
395  js.at(PY_t).get<double>(),
396  js.at(PZ_t).get<double>()));
397  }
static const std::string PZ_t
static const std::string DOMId_t
static const std::string PX_t
static const std::string PY_t
void JDETECTOR::to_json ( json js,
const JModuleRotation_t object 
)
inline

Convert module rotation to JSon.

Parameters
jsjson
objectmodule rotation

Definition at line 433 of file JDetectorCalibration.hh.

434  {
435  js = json{ { DOMId_t, object.getID() },
436  { Q0_t, object.getA() },
437  { QX_t, object.getB() },
438  { QY_t, object.getC() },
439  { QZ_t, object.getD() } };
440  }
static const std::string Q0_t
static const std::string DOMId_t
static const std::string QZ_t
nlohmann::json json
static const std::string QY_t
static const std::string QX_t
void JDETECTOR::from_json ( const json js,
JModuleRotation_t object 
)
inline

Convert JSon to module rotation.

Parameters
jsjson
objectmodule rotation

Definition at line 449 of file JDetectorCalibration.hh.

450  {
451  object.setID(js.at(DOMId_t).get<int>());
452 
453  object.setQuaternion(JQuaternion3D(js.at(Q0_t).get<double>(),
454  js.at(QX_t).get<double>(),
455  js.at(QY_t).get<double>(),
456  js.at(QZ_t).get<double>()));
457  }
static const std::string Q0_t
static const std::string DOMId_t
static const std::string QZ_t
static const std::string QY_t
static const std::string QX_t
JDetectorHeader JDETECTOR::getARCADetectorHeader ( )
inline

Get detector header for ARCA.

Returns
detector header

Definition at line 241 of file JDetectorHeader.hh.

242  {
243  return JDetectorHeader(JUTCTimeRange(0.0, 999999999999.9),
244  JUTMGrid ("UTM", "WGS84", "33N"),
245  JUTMPosition (587600, 4016800, -3450));
246  }
Data structure for detector header.
JDetectorHeader JDETECTOR::getORCADetectorHeader ( )
inline

Get detector header for ORCA.

Returns
detector header

Definition at line 253 of file JDetectorHeader.hh.

254  {
255  return JDetectorHeader(JUTCTimeRange(0.0, 999999999999.9),
256  JUTMGrid ("UTM", "WGS84", "32N"),
257  JUTMPosition (256500, 4743000, -2440));
258  }
Data structure for detector header.
bool JDETECTOR::isARCADetector ( const JDetectorHeader header)
inline

Check if given detector header is compatible with tat of ARCA.

Parameters
headerheader
Returns
true if ARCA; else false

Definition at line 267 of file JDetectorHeader.hh.

268  {
269  return header.equals(getARCADetectorHeader(), 1.0);
270  }
bool equals(const JDetectorHeader &header, const double precision=std::numeric_limits< double >::min()) const
Check equality.
JDetectorHeader getARCADetectorHeader()
Get detector header for ARCA.
bool JDETECTOR::isORCADetector ( const JDetectorHeader header)
inline

Check if given detector header is compatible with that of ORCA.

Parameters
headerheader
Returns
true if ORCA; else false

Definition at line 279 of file JDetectorHeader.hh.

280  {
281  return header.equals(getORCADetectorHeader(), 1.0);
282  }
JDetectorHeader getORCADetectorHeader()
Get detector header for ORCA.
bool equals(const JDetectorHeader &header, const double precision=std::numeric_limits< double >::min()) const
Check equality.
JPosition3D JDETECTOR::getPiezoPosition ( )
inline

Get relative position of piezo in optical module.

Returns
position [m]

Definition at line 30 of file JDetectorSupportkit.hh.

31  {
32  return JPosition3D(0.0, 0.0, -0.20);
33  }
double JDETECTOR::getMaximalDistance ( const JDetector detector)
inline

Get maximal distance between modules in detector.

Parameters
detectordetector
Returns
maximal distance [m]

Definition at line 74 of file JDetectorToolkit.hh.

75  {
76  using namespace JPP;
77 
78  double dmax = 0.0;
79 
80  for (JDetector::const_iterator i = detector.begin(); i != detector.end(); ++i) {
81  for (JDetector::const_iterator j = detector.begin(); j != i; ++j) {
82  if (getDistance(i->getPosition(), j->getPosition()) > dmax) {
83  dmax = getDistance(i->getPosition(), j->getPosition());
84  }
85  }
86  }
87 
88  return dmax;
89  }
double getDistance(const JFirst_t &first, const JSecond_t &second)
Get distance between objects.
int j
Definition: JPolint.hh:666
double JDETECTOR::GetXrotationG4 ( const JVersor3D  dir)
inline

Get rotation over X axis in Geant4 coordinate system.

Parameters
dirdirection
Returns
X-rotation [deg]

Definition at line 98 of file JDetectorToolkit.hh.

99  {
100  using namespace JPP;
101 
102  const double phi = atan2(dir.getDY(), dir.getDZ())*(180.0/PI);
103 
104  if (phi < 0.0){
105  return phi + 360.0;
106  }
107  else{
108  return phi;
109  }
110  }
double getDY() const
Get y direction.
Definition: JVersor3D.hh:106
static const double PI
Mathematical constants.
double getDZ() const
Get z direction.
Definition: JVersor3D.hh:117
double JDETECTOR::GetYrotationG4 ( const JVersor3D  dir)
inline

Get rotation over Y axis in Geant4 coordinate system.

Parameters
dirdirection
Returns
Y-rotation [deg]

Definition at line 119 of file JDetectorToolkit.hh.

120  {
121  using namespace JPP;
122 
123  return asin(-dir.getDX())*(180.0/PI);
124  }
double getDX() const
Get x direction.
Definition: JVersor3D.hh:95
static const double PI
Mathematical constants.
void JDETECTOR::read_gdml ( std::istream &  ,
JDetector  
)
inline

Definition at line 127 of file JDetectorToolkit.hh.

128  {}
void JDETECTOR::write_gdml ( std::ostream &  out,
const JDetector detector 
)
inline

Writes KM3Sim GDML input file from detector.

Parameters
outoutput stream
detectordetector

Definition at line 137 of file JDetectorToolkit.hh.

138  {
139  using namespace std;
140  using namespace JPP;
141 
142  const double DEFAULT_CAN_MARGIN_M = 350.0; // default can margin [m]
143  const double DEFAULT_WORLD_MARGIN_M = 50.0; // default world margin [m]
144 
145  const JCylinder3D cylinder(detector.begin(), detector.end());
146 
147  double can_margin;
148 
149  if (CAN_MARGIN_M) {
150  can_margin = atof(CAN_MARGIN_M);
151  } else {
152  cerr << "CAN_MARGIN_M not defined! Setting standard CAN_MARGIN_M " << DEFAULT_CAN_MARGIN_M << " m." << endl;
153  can_margin = DEFAULT_CAN_MARGIN_M; //this is given in meters like all the dimensions in the GDML file (look at the unit field of every position and solid definition)
154  }
155 
156  const double WorldCylinderHeight = 2*(cylinder.getZmax() - cylinder.getZmin() + can_margin + DEFAULT_WORLD_MARGIN_M);
157  const double WorldRadius = cylinder.getLength() + cylinder.getRadius() + can_margin + DEFAULT_WORLD_MARGIN_M;
158 
159  const double Crust_Z_size = WorldCylinderHeight/2;
160  const double Crust_Z_position = -WorldCylinderHeight/4;
161 
162  out << "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>\n<gdml xmlns:gdml=\"http://cern.ch/2001/Schemas/GDML\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:noNamespaceSchemaLocation=\"";
163  if (!GDML_SCHEMA) {
164  cerr << "GDML_SCHEMA_DIR NOT DEFINED! Setting default path." << endl;
165  out << G4GDML_DEFAULT_SCHEMALOCATION << "\">\n\n\n";
166  } else {
167  out << GDML_SCHEMA << "gdml.xsd\">\n\n\n";
168  }
169  out << "<!-- Jpp version: "<< getGITVersion() << " -->\n";
170  out << "<define>\n";
171  out << "<rotation name=\"identity\"/>\n<position name=\"zero\"/>\n";
172 
173  int PMTs_NO = 0;
174 
175  for (JDetector::const_iterator module = detector.begin(); module != detector.end(); ++module) {
176 
177  if (module->getFloor() != 0) {
178 
179  const JVector3D center = module->getCenter();
180 
181  out << "<position name=\"PosString" << module->getString() << "_Dom" << module->getID() << "\" unit=\"m\" x=\"" << module->getX() << "\" y=\"" << module->getY() << "\" z=\"" << module->getZ() << "\"/>\n";
182 
183  for (JModule::const_iterator pmt = module->begin(); pmt != module->end(); ++pmt) {
184 
185  const JVector3D vec = static_cast<JVector3D>(*pmt).sub(center);
186  out << "<position name=\"CathodPosition" << pmt->getID() << "_" << module->getID() << "\" unit=\"m\" x=\"" << vec.getX() << "\" y=\"" << vec.getY() << "\" z=\"" << vec.getZ() << "\"/>\n";
187  out << "<rotation name=\"CathodRotation" << pmt->getID() << "_" << module->getID() << "\" unit=\"deg\" x=\"" << GetXrotationG4(*pmt) << "\" y=\"" << GetYrotationG4(*pmt) << "\" z=\"0.000000\"/>\n";
188  out << "<constant name=\"CathodID_" << PMTs_NO << "\" value=\"" << pmt->getID() << "\"/>\n";
189  PMTs_NO++;
190  }
191  }
192  }
193 
194  out << "<position name=\"OMShift\" unit=\"m\" x=\"0\" y=\"0\" z=\"0.0392\"/>\n";
195  out << "\n\n\n";
196  out << "<!-- end of DU position definitions -->\n<position name=\"CrustPosition\" unit=\"m\" x=\"0\" y=\"0\" z=\"" << Crust_Z_position << "\"/>\n";
197 
198  out << "</define>\n";
199  out << "<materials>\n";
200  out << "</materials>\n";
201  out << "<solids>\n";
202  out << " <box name=\"CrustBox\" lunit=\"m\" x=\"2200\" y=\"2200\" z=\"" << Crust_Z_size << "\"/>\n";
203  out << " <box name=\"StoreyBox\" lunit=\"m\" x=\"0.6\" y=\"0.6\" z=\"0.6\"/>\n";
204  out << " <sphere name=\"OMSphere\" lunit=\"cm\" aunit=\"deg\" rmin=\"0.0\" rmax=\"21.6\" startphi=\"0.0\" deltaphi=\"360.0\" starttheta=\"0.0\" deltatheta=\"180.0\"/>\n";
205  out << " <tube name=\"CathodTube\" lunit=\"cm\" aunit=\"deg\" rmin=\"0.0\" rmax=\"4.7462\" z=\"0.5\" startphi=\"0.0\" deltaphi=\"360.0\"/>\n";
206  out << " <tube name=\"WorldTube\" lunit=\"m\" aunit=\"deg\" rmin=\"0.0\" rmax=\"" << WorldRadius << "\" z=\"" << WorldCylinderHeight << "\" startphi=\"0.0\" deltaphi=\"360.0\"/>\n";
207  out << "</solids>\n\n\n";
208 
209  out << "<structure>\n";
210  out << " <volume name=\"CathodVolume\">\n";
211  out << " <materialref ref=\"Cathod\"/>\n";
212  out << " <solidref ref=\"CathodTube\"/>\n";
213  out << " </volume>\n";
214 
215  out << "<!-- OMVolume(s) construction -->\n";
216 
217  for (JDetector::const_iterator module = detector.begin(); module != detector.end(); ++module) {
218 
219  out << " <volume name=\"OMVolume" << module->getID() << "\">\n";
220  out << " <materialref ref=\"Water\"/>\n";
221  out << " <solidref ref=\"OMSphere\"/>\n";
222 
223  for (JModule::const_iterator pmt = module->begin(); pmt != module->end(); ++pmt) {
224  out << " <physvol>\n";
225  out << " <volumeref ref=\"CathodVolume\"/>\n";
226  out << " <positionref ref=\"CathodPosition" << pmt->getID() << "_" << module->getID() << "\"/>\n";
227  out << " <rotationref ref=\"CathodRotation" << pmt->getID() << "_" << module->getID() << "\"/>\n";
228  out << " </physvol>\n";
229  }
230 
231  out << " </volume>\n";
232  }
233 
234  out << "<!-- StoreyVolume(s) construction -->\n";
235 
236  for (JDetector::const_iterator module = detector.begin(); module != detector.end(); ++module) {
237  out << " <volume name=\"StoreyVolume" << module->getID() << "\">\n";
238  out << " <materialref ref=\"Water\"/>\n";
239  out << " <solidref ref=\"StoreyBox\"/>\n";
240  out << " <physvol>\n";
241  out << " <volumeref ref=\"OMVolume" << module->getID() << "\"/>\n";
242  out << " <positionref ref=\"OMShift\"/>\n";
243  out << " <rotationref ref=\"identity\"/>\n";
244  out << " </physvol>\n";
245  out << " </volume>\n";
246  }
247 
248  out << "<!-- Crust Volume construction-->\n";
249  out << "<volume name=\"CrustVolume\">\n";
250  out << " <materialref ref=\"Crust\"/>\n";
251  out << " <solidref ref=\"CrustBox\"/>\n";
252  out << "</volume>\n";
253 
254  out << "<!-- World Volume construction-->\n";
255  out << "<volume name=\"WorldVolume\">\n";
256  out << " <materialref ref=\"Water\"/>\n";
257  out << " <solidref ref=\"WorldTube\"/>\n";
258 
259  out << " <physvol>\n";
260  out << " <volumeref ref=\"CrustVolume\"/>\n";
261  out << " <positionref ref=\"CrustPosition\"/>\n";
262  out << " <rotationref ref=\"identity\"/>\n";
263  out << " </physvol>\n";
264 
265  for (JDetector::const_iterator module = detector.begin(); module != detector.end(); ++module) {
266  out << " <physvol>\n";
267  out << " <volumeref ref=\"StoreyVolume" << module->getID() << "\"/>\n";
268  out << " <positionref ref=\"PosString" << module->getString() << "_Dom" << module->getID() << "\"/>\n";
269  out << " <rotationref ref=\"identity\"/>\n";
270  out << " </physvol>\n";
271  }
272 
273  out << "</volume>\n";
274 
275  out << "</structure>\n";
276  out << "<setup name=\"Default\" version=\"1.0\">\n";
277  out << "<world ref=\"WorldVolume\"/>\n";
278  out << "</setup>\n";
279  out << "</gdml>\n";
280  }
double GetYrotationG4(const JVersor3D dir)
Get rotation over Y axis in Geant4 coordinate system.
static const char *const GDML_SCHEMA
directory necessary for correct GDML header output
static const char *const CAN_MARGIN_M
extension of the detector size to comply with the can definition
JVector3D & sub(const JVector3D &vector)
Subtract vector.
Definition: JVector3D.hh:158
Cylinder object.
Definition: JCylinder3D.hh:39
std::string getGITVersion(const std::string &tag)
Get GIT version for given GIT tag.
Data structure for vector in three dimensions.
Definition: JVector3D.hh:34
double getY() const
Get y position.
Definition: JVector3D.hh:104
double getX() const
Get x position.
Definition: JVector3D.hh:94
static const char *const G4GDML_DEFAULT_SCHEMALOCATION
double GetXrotationG4(const JVersor3D dir)
Get rotation over X axis in Geant4 coordinate system.
double getZ() const
Get z position.
Definition: JVector3D.hh:115
double JDETECTOR::getMaximalTime ( const JDetector detector)
inline

Get maximal time between modules in detector following causality.

Parameters
detectordetector
Returns
maximal time [ns]

Definition at line 289 of file JDetectorToolkit.hh.

290  {
291  using namespace JPP;
292 
294  }
double getIndexOfRefraction()
Get average index of refraction of water corresponding to group velocity.
double getMaximalDistance(const JDetector &detector)
Get maximal distance between modules in detector.
const double getInverseSpeedOfLight()
Get inverse speed of light.
double JDETECTOR::getMaximalTime ( const JDetector detector,
const double  roadWidth_m 
)
inline

Get maximal time between modules in detector following causality.

The road width corresponds to the maximal distance traveled by the light.

Parameters
detectordetector
roadWidth_mroad width [m]
Returns
maximal time [ns]

Definition at line 305 of file JDetectorToolkit.hh.

306  {
307  using namespace JPP;
308 
309  const double Dmax_m = getMaximalDistance(detector);
310 
311  return (sqrt((Dmax_m + roadWidth_m*getSinThetaC()) *
312  (Dmax_m - roadWidth_m*getSinThetaC())) +
313  roadWidth_m * getSinThetaC() * getTanThetaC()) * getInverseSpeedOfLight();
314  }
double getMaximalDistance(const JDetector &detector)
Get maximal distance between modules in detector.
const double getInverseSpeedOfLight()
Get inverse speed of light.
double getTanThetaC()
Get average tangent of Cherenkov angle of water corresponding to group velocity.
double getSinThetaC()
Get average sine of Cherenkov angle of water corresponding to group velocity.
JTimeRange JDETECTOR::getTimeRange ( const JTimeRange timeRange,
const JModule module 
)
inline

Get de-calibrated time range.

The de-calibrated time range is corrected for minimal and maximal time offset of PMTs in given module.

Parameters
timeRangetime range [ns]
modulemodule
Returns
time range [ns]

Definition at line 326 of file JDetectorToolkit.hh.

327  {
328  if (!module.empty()) {
329 
330  JTimeRange time_range(JTimeRange::DEFAULT_RANGE);
331 
332  for (JModule::const_iterator pmt = module.begin(); pmt != module.end(); ++pmt) {
333 
334  const JCalibration& calibration = pmt->getCalibration();
335 
336  time_range.include(putTime(timeRange.getLowerLimit(), calibration));
337  time_range.include(putTime(timeRange.getUpperLimit(), calibration));
338  }
339 
340  return time_range;
341 
342  } else {
343 
344  return timeRange;
345  }
346  }
T getLowerLimit() const
Get lower limit.
Definition: JRange.hh:202
const JCalibration & getCalibration() const
Get calibration.
Data structure for time calibration.
double putTime(const T &t1, const JCalibration &cal)
Get de-calibrated time.
T getUpperLimit() const
Get upper limit.
Definition: JRange.hh:213
int JDETECTOR::getNumberOfPMTs ( const JModule module)
inline

Get number of PMTs.

Parameters
modulemodule
Returns
number of PMTs

Definition at line 355 of file JDetectorToolkit.hh.

356  {
357  return module.size();
358  }
int JDETECTOR::getNumberOfPMTs ( const JDetector detector)
inline

Get number of PMTs.

Parameters
detectordetector
Returns
number of PMTs

Definition at line 367 of file JDetectorToolkit.hh.

368  {
369  int number_of_pmts = 0;
370 
371  for (JDetector::const_iterator module = detector.begin(); module != detector.end(); ++module) {
372  number_of_pmts += getNumberOfPMTs(*module);
373  }
374 
375  return number_of_pmts;
376  }
int getNumberOfPMTs(const JModule &module)
Get number of PMTs.
std::set<int> JDETECTOR::getStringIDs ( const JDetector detector)
inline

Get list of strings IDs.

Parameters
detectordetector
Returns
list of string IDs

Definition at line 385 of file JDetectorToolkit.hh.

386  {
387  std::set<int> buffer;
388 
389  for (JDetector::const_iterator module = detector.begin(); module != detector.end(); ++module) {
390  buffer.insert(module->getString());
391  }
392 
393  return buffer;
394  }
int JDETECTOR::getNumberOfFloors ( const JDetector detector)
inline

Get number of floors.

Parameters
detectordetector
Returns
number of floors

Definition at line 403 of file JDetectorToolkit.hh.

404  {
405  std::set<int> buffer;
406 
407  for (JDetector::const_iterator module = detector.begin(); module != detector.end(); ++module) {
408  buffer.insert(module->getFloor());
409  }
410 
411  return buffer.size();
412  }
int JDETECTOR::getNumberOfModules ( const JDetector detector)
inline

Get number of modules.

Parameters
detectordetector
Returns
number of modules

Definition at line 421 of file JDetectorToolkit.hh.

422  {
423  std::set<int> buffer;
424 
425  for (JDetector::const_iterator module = detector.begin(); module != detector.end(); ++module) {
426  buffer.insert(module->getID());
427  }
428 
429  return buffer.size();
430  }
void JDETECTOR::load ( const std::string &  file_name,
JDetector detector 
)
inline

Load detector from input file.

Supported file formats:

Parameters
file_namefile name
detectordetector

Definition at line 445 of file JDetectorToolkit.hh.

446  {
447  using namespace std;
448  using namespace JPP;
449 
451 
452  JMonteCarloDetector buffer(true);
453 
454  ifstream in(file_name.c_str());
455 
456  if (!in) {
457  THROW(JFileOpenException, "File not opened: " << file_name);
458  }
459 
460  in >> buffer;
461 
462  in.close();
463 
464  detector.swap(buffer);
465 
466  } else if (getFilenameExtension(file_name) == BINARY_DETECTOR_FILE_FORMAT) {
467 
468  JFileStreamReader in(file_name.c_str());
469 
470  if (!in) {
471  THROW(JFileOpenException, "File not opened: " << file_name);
472  }
473 
474  detector.read(in);
475 
476  in.close();
477 
478  } else if (getFilenameExtension(file_name) == KM3NET_DETECTOR_FILE_FORMAT) {
479 
480  ifstream in(file_name.c_str());
481 
482  if (!in) {
483  THROW(JFileOpenException, "File not opened: " << file_name);
484  }
485 
486  in >> detector;
487 
488  in.close();
489 
490  } else if (getFilenameExtension(file_name) == ZIPPED_DETECTOR_FILE_FORMAT) {
491 
492  igzstream in(file_name.c_str());
493 
494  if (!in) {
495  THROW(JFileOpenException, "File not opened: " << file_name);
496  }
497 
498  in >> detector;
499 
500  in.close();
501 
502  } else {
503 
504  THROW(JProtocolException, "Protocol not defined: " << file_name);
505  }
506  }
Exception for opening of file.
Definition: JException.hh:342
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
Definition: JException.hh:670
Monte Carlo detector (i.e. so-called .det file).
virtual JReader & read(JReader &in) override
Read from input.
Definition: JDetector.hh:387
Protocol exception.
Definition: JException.hh:630
static const char *const KM3NET_DETECTOR_FILE_FORMAT
KM3NeT standard ASCII format
static const char *const ZIPPED_DETECTOR_FILE_FORMAT
zipped KM3NeT standard ASCII format
static const char *const GENDET_DETECTOR_FILE_FORMAT
File name extensions.
static const char *const BINARY_DETECTOR_FILE_FORMAT
JIO binary file format.
std::string getFilenameExtension(const std::string &file_name)
Get file name extension, i.e. part after last JEEP::FILENAME_SEPARATOR if any.
Definition: JeepToolkit.hh:69
do set_variable DETECTOR_TXT $WORKDIR detector
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2] eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY source JAcoustics sh $DETECTOR_ID CHECK_EXIT_CODE typeset A TRIPODS get_tripods $WORKDIR tripod txt TRIPODS for EMITTER in
Definition: JCanberra.sh:38
Binary buffered file input.
void JDETECTOR::store ( const std::string &  file_name,
const JDetector detector 
)
inline

Store detector to output file.

Supported file formats:

Parameters
file_namefile name
detectordetector

Definition at line 521 of file JDetectorToolkit.hh.

522  {
523  using namespace std;
524  using namespace JPP;
525 
527 
528  JFileStreamWriter out(file_name.c_str());
529 
530  detector.write(out);
531 
532  out.close();
533 
534  } else if (getFilenameExtension(file_name) == KM3NET_DETECTOR_FILE_FORMAT) {
535 
536  std::ofstream out(file_name.c_str());
537 
538  out << detector;
539 
540  out.close();
541 
542  } else if (getFilenameExtension(file_name) == ZIPPED_DETECTOR_FILE_FORMAT) {
543 
544  ogzstream out(file_name.c_str());
545 
546  out << detector;
547 
548  out.close();
549 
550  } else if (getFilenameExtension(file_name) == GDML_DETECTOR_FILE_FORMAT) {
551 
552  std::ofstream out(file_name.c_str());
553 
554  write_gdml(out, detector);
555 
556  out.close();
557 
558  } else {
559 
560  THROW(JProtocolException, "Protocol not defined: " << file_name);
561  }
562  }
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
Definition: JException.hh:670
virtual JWriter & write(JWriter &out) const override
Write to output.
Definition: JDetector.hh:438
Protocol exception.
Definition: JException.hh:630
static const char *const KM3NET_DETECTOR_FILE_FORMAT
KM3NeT standard ASCII format
static const char *const ZIPPED_DETECTOR_FILE_FORMAT
zipped KM3NeT standard ASCII format
static const char *const BINARY_DETECTOR_FILE_FORMAT
JIO binary file format.
std::string getFilenameExtension(const std::string &file_name)
Get file name extension, i.e. part after last JEEP::FILENAME_SEPARATOR if any.
Definition: JeepToolkit.hh:69
do set_variable DETECTOR_TXT $WORKDIR detector
Binary buffered file output.
static const char *const GDML_DETECTOR_FILE_FORMAT
KM3Sim input format.
void write_gdml(std::ostream &out, const JDetector &detector)
Writes KM3Sim GDML input file from detector.
const JModule& JDETECTOR::getModule ( const JModuleAddressMap memo,
const int  id = -1,
const JLocation location = JLocation() 
)
inline

Get module according module address map.

Parameters
memomodule address map
idmodule identifier
locationmodule location
Returns
module

Definition at line 573 of file JDetectorToolkit.hh.

576  {
577  static JModule module;
578 
579 
580  module.setID(id);
581 
582  module.setLocation(location);
583 
584  module.resize(memo.size());
585 
586  if (memo.has( 0)) { module[memo[ 0].tdc] = JPMT( 1, JAxis3D(JVector3D(+0.000, +0.000, -0.200), JVersor3D(+0.000, +0.000, -1.000))); }
587 
588  if (memo.has( 1)) { module[memo[ 1].tdc] = JPMT( 2, JAxis3D(JVector3D(+0.000, +0.105, -0.170), JVersor3D(+0.000, +0.527, -0.850))); }
589  if (memo.has( 2)) { module[memo[ 2].tdc] = JPMT( 3, JAxis3D(JVector3D(+0.091, +0.053, -0.170), JVersor3D(+0.456, +0.263, -0.850))); }
590  if (memo.has( 3)) { module[memo[ 3].tdc] = JPMT( 4, JAxis3D(JVector3D(+0.091, -0.053, -0.170), JVersor3D(+0.456, -0.263, -0.850))); }
591  if (memo.has( 4)) { module[memo[ 4].tdc] = JPMT( 5, JAxis3D(JVector3D(+0.000, -0.105, -0.170), JVersor3D(+0.000, -0.527, -0.850))); }
592  if (memo.has( 5)) { module[memo[ 5].tdc] = JPMT( 6, JAxis3D(JVector3D(-0.091, -0.053, -0.170), JVersor3D(-0.456, -0.263, -0.850))); }
593  if (memo.has( 6)) { module[memo[ 6].tdc] = JPMT( 7, JAxis3D(JVector3D(-0.091, +0.053, -0.170), JVersor3D(-0.456, +0.263, -0.850))); }
594 
595  if (memo.has( 7)) { module[memo[ 7].tdc] = JPMT( 8, JAxis3D(JVector3D(+0.083, +0.144, -0.111), JVersor3D(+0.416, +0.720, -0.555))); }
596  if (memo.has( 8)) { module[memo[ 8].tdc] = JPMT( 9, JAxis3D(JVector3D(+0.166, +0.000, -0.111), JVersor3D(+0.832, +0.000, -0.555))); }
597  if (memo.has( 9)) { module[memo[ 9].tdc] = JPMT(10, JAxis3D(JVector3D(+0.083, -0.144, -0.111), JVersor3D(+0.416, -0.720, -0.555))); }
598  if (memo.has(10)) { module[memo[10].tdc] = JPMT(11, JAxis3D(JVector3D(-0.083, -0.144, -0.111), JVersor3D(-0.416, -0.720, -0.555))); }
599  if (memo.has(11)) { module[memo[11].tdc] = JPMT(12, JAxis3D(JVector3D(-0.166, +0.000, -0.111), JVersor3D(-0.832, +0.000, -0.555))); }
600  if (memo.has(12)) { module[memo[12].tdc] = JPMT(13, JAxis3D(JVector3D(-0.083, +0.144, -0.111), JVersor3D(-0.416, +0.720, -0.555))); }
601 
602  if (memo.has(13)) { module[memo[13].tdc] = JPMT(14, JAxis3D(JVector3D(+0.000, +0.191, -0.059), JVersor3D(+0.000, +0.955, -0.295))); }
603  if (memo.has(14)) { module[memo[14].tdc] = JPMT(15, JAxis3D(JVector3D(+0.165, +0.096, -0.059), JVersor3D(+0.827, +0.478, -0.295))); }
604  if (memo.has(15)) { module[memo[15].tdc] = JPMT(16, JAxis3D(JVector3D(+0.165, -0.096, -0.059), JVersor3D(+0.827, -0.478, -0.295))); }
605  if (memo.has(16)) { module[memo[16].tdc] = JPMT(17, JAxis3D(JVector3D(+0.000, -0.191, -0.059), JVersor3D(+0.000, -0.955, -0.295))); }
606  if (memo.has(17)) { module[memo[17].tdc] = JPMT(18, JAxis3D(JVector3D(-0.165, -0.096, -0.059), JVersor3D(-0.827, -0.478, -0.295))); }
607  if (memo.has(18)) { module[memo[18].tdc] = JPMT(19, JAxis3D(JVector3D(-0.165, +0.096, -0.059), JVersor3D(-0.827, +0.478, -0.295))); }
608 
609  if (memo.has(19)) { module[memo[19].tdc] = JPMT(20, JAxis3D(JVector3D(+0.096, +0.165, +0.059), JVersor3D(+0.478, +0.827, +0.295))); }
610  if (memo.has(20)) { module[memo[20].tdc] = JPMT(21, JAxis3D(JVector3D(+0.191, +0.000, +0.059), JVersor3D(+0.955, +0.000, +0.295))); }
611  if (memo.has(21)) { module[memo[21].tdc] = JPMT(22, JAxis3D(JVector3D(+0.096, -0.165, +0.059), JVersor3D(+0.478, -0.827, +0.295))); }
612  if (memo.has(22)) { module[memo[22].tdc] = JPMT(23, JAxis3D(JVector3D(-0.096, -0.165, +0.059), JVersor3D(-0.478, -0.827, +0.295))); }
613  if (memo.has(23)) { module[memo[23].tdc] = JPMT(24, JAxis3D(JVector3D(-0.191, +0.000, +0.059), JVersor3D(-0.955, +0.000, +0.295))); }
614  if (memo.has(24)) { module[memo[24].tdc] = JPMT(25, JAxis3D(JVector3D(-0.096, +0.165, +0.059), JVersor3D(-0.478, +0.827, +0.295))); }
615 
616  if (memo.has(25)) { module[memo[25].tdc] = JPMT(26, JAxis3D(JVector3D(+0.000, +0.166, +0.111), JVersor3D(+0.000, +0.832, +0.555))); }
617  if (memo.has(26)) { module[memo[26].tdc] = JPMT(27, JAxis3D(JVector3D(+0.144, +0.083, +0.111), JVersor3D(+0.720, +0.416, +0.555))); }
618  if (memo.has(27)) { module[memo[27].tdc] = JPMT(28, JAxis3D(JVector3D(+0.144, -0.083, +0.111), JVersor3D(+0.720, -0.416, +0.555))); }
619  if (memo.has(28)) { module[memo[28].tdc] = JPMT(29, JAxis3D(JVector3D(+0.000, -0.166, +0.111), JVersor3D(+0.000, -0.832, +0.555))); }
620  if (memo.has(29)) { module[memo[29].tdc] = JPMT(30, JAxis3D(JVector3D(-0.144, -0.083, +0.111), JVersor3D(-0.720, -0.416, +0.555))); }
621  if (memo.has(30)) { module[memo[30].tdc] = JPMT(31, JAxis3D(JVector3D(-0.144, +0.083, +0.111), JVersor3D(-0.720, +0.416, +0.555))); }
622 
623  module.compile();
624 
625  return module;
626  }
Data structure for a composite optical module.
Definition: JModule.hh:57
void setLocation(const JLocation &location)
Set location.
Definition: JLocation.hh:91
Axis object.
Definition: JAxis3D.hh:38
Data structure for vector in three dimensions.
Definition: JVector3D.hh:34
Data structure for PMT geometry and calibration.
Definition: JPMT.hh:47
void compile()
Compile module data.
Definition: JModule.hh:313
void setID(const int id)
Set identifier.
Definition: JObjectID.hh:72
Data structure for normalised vector in three dimensions.
Definition: JVersor3D.hh:26
bool has(const int index) const
Test whether index is available.
const JModule& JDETECTOR::getModule ( const int  id,
const JLocation location = JLocation() 
)
inline

Get module corresponding to Antares storey.

Parameters
idmodule identifier
locationmodule location
Returns
module

Definition at line 636 of file JDetectorToolkit.hh.

638  {
639  static JModule module;
640 
641  module.setID(id);
642 
643  module.setLocation(location);
644 
645  if (module.empty()) {
646 
647  module.resize(3);
648 
649  const double R = 0.5; // [m]
650 
651  const double st = sin(0.75*PI);
652  const double ct = cos(0.75*PI);
653 
654  for (int i = 0; i != 3; ++i) {
655 
656  const double phi = (2.0*PI*i) / 3.0;
657  const double cp = cos(phi);
658  const double sp = sin(phi);
659 
660  module[i] = JPMT(i, JAxis3D(JVector3D(R*st*cp, R*st*sp, R*ct), JVersor3D(st*cp, st*sp, ct)));
661  }
662  }
663 
664  return module;
665  }
Data structure for a composite optical module.
Definition: JModule.hh:57
void setLocation(const JLocation &location)
Set location.
Definition: JLocation.hh:91
Axis object.
Definition: JAxis3D.hh:38
Data structure for vector in three dimensions.
Definition: JVector3D.hh:34
Data structure for PMT geometry and calibration.
Definition: JPMT.hh:47
static const double PI
Mathematical constants.
then usage $script[distance] fi case set_variable R
Definition: JDrawLED.sh:40
void setID(const int id)
Set identifier.
Definition: JObjectID.hh:72
then cp
Data structure for normalised vector in three dimensions.
Definition: JVersor3D.hh:26
JPosition3D JDETECTOR::getPosition ( const JModule first,
const JModule second 
)
inline

Get position to go from first to second module.

Parameters
firstfirst module
secondsecond module
Returns
position

Definition at line 802 of file JDetectorToolkit.hh.

803  {
804  return second.getPosition() - first.getPosition();
805  }
const JPosition3D & getPosition() const
Get position.
Definition: JPosition3D.hh:130
JCalibration JDETECTOR::getCalibration ( const JCalibration first,
const JCalibration second 
)
inline

Get calibration to go from first to second calibration.

Parameters
firstfirst calibration
secondsecond calibration
Returns
calibration

Definition at line 815 of file JDetectorToolkit.hh.

816  {
817  return JCalibration(second.getT0() - first.getT0());
818  }
Data structure for time calibration.
double getT0() const
Get time offset.
std::vector<std::string> JDETECTOR::getDetectorVersions ( const JType< std::string > &  type)
inline

Get detector versions.

Note that the order of the versions is descending.

Parameters
typetype
Returns
versions

Definition at line 255 of file JDetectorVersion.hh.

256  {
257  return JLANG::make_array(putDetectorVersion.rbegin(), putDetectorVersion.rend(), &JPutDetectorVersion::value_type::second);
258  }
const array_type< JValue_t > & make_array(const JValue_t(&array)[N])
Method to create array of values.
Definition: JVectorize.hh:37
static const JPutDetectorVersion putDetectorVersion(getDetectorVersion)
Function object to map detector version to detector variant.
std::vector<JDetectorVersion::JVersion_t> JDETECTOR::getDetectorVersions ( const JType< JDetectorVersion::JVersion_t > &  type)
inline

Get detector versions.

Note that the order of the versions is descending.

Parameters
typetype
Returns
versions

Definition at line 269 of file JDetectorVersion.hh.

270  {
272  }
then echo The file $DIR KM3NeT_00000001_00000000 root already please rename or remove it first
const array_type< JValue_t > & make_array(const JValue_t(&array)[N])
Method to create array of values.
Definition: JVectorize.hh:37
static const JPutDetectorVersion putDetectorVersion(getDetectorVersion)
Function object to map detector version to detector variant.
template<class T >
std::vector<T> JDETECTOR::getDetectorVersions ( )
inline

Get detector versions.

Returns
versions

Definition at line 281 of file JDetectorVersion.hh.

282  {
283  return getDetectorVersions(JType<T>());
284  }
std::vector< std::string > getDetectorVersions(const JType< std::string > &type)
Get detector versions.
std::string JDETECTOR::getLatestDetectorVersion ( const JType< std::string > &  type)
inline

Get latest detector version.

Parameters
typetype
Returns
version

Definition at line 293 of file JDetectorVersion.hh.

294  {
295  return putDetectorVersion.rbegin()->second;
296  }
static const JPutDetectorVersion putDetectorVersion(getDetectorVersion)
Function object to map detector version to detector variant.
JDetectorVersion::JVersion_t JDETECTOR::getLatestDetectorVersion ( const JType< JDetectorVersion::JVersion_t > &  type)
inline

Get latest detector version.

Parameters
typetype
Returns
version

Definition at line 305 of file JDetectorVersion.hh.

306  {
307  return putDetectorVersion.rbegin()->first;
308  }
static const JPutDetectorVersion putDetectorVersion(getDetectorVersion)
Function object to map detector version to detector variant.
template<class T >
T JDETECTOR::getLatestDetectorVersion ( )
inline

Get latest detector version.

Returns
version

Definition at line 317 of file JDetectorVersion.hh.

318  {
319  return getLatestDetectorVersion(JType<T>());
320  }
std::string getLatestDetectorVersion(const JType< std::string > &type)
Get latest detector version.
std::string JDETECTOR::getLabel ( const JLocation location)
inline

Get module label for monitoring and other applications.


The format is "(XXXX,YY)", where XXXX is the string number and YY the floor.

Parameters
locationmodule location
Returns
label

Definition at line 246 of file JLocation.hh.

247  {
248  using namespace std;
249  using namespace JPP;
250 
251  return MAKE_STRING("(" << FILL(4,'0') << location.getString() << "." << FILL(2,'0') << location.getFloor() << ")");
252  }
int getFloor() const
Get floor number.
Definition: JLocation.hh:145
#define MAKE_STRING(A)
Make string.
Definition: JPrint.hh:142
Auxiliary data structure for sequence of same character.
Definition: JManip.hh:328
int getString() const
Get string number.
Definition: JLocation.hh:134
template<class JAttributes_t >
void JDETECTOR::setAttributes ( const JModule first,
const JModule second,
JAttributes_t &  attributes 
)

Template method to set module attributes.

This method should be overloaded for each type of module attributes.

Parameters
firstfirst module
secondsecond module
attributesmodule attributes
template<>
void JDETECTOR::setAttributes< JNullType > ( const JModule first,
const JModule second,
JNullType &  attributes 
)

Template specialisation to set no attributes for the default empty object.

Parameters
firstfirst module
secondsecond module
attributesmodule attributes

Definition at line 49 of file JModuleMapper.hh.

52  {}
double JDETECTOR::getTimeOverThresholdProbability ( const JPMTAnalogueSignalProcessor &  pmt,
const double  tot_ns,
const double  NPE,
const double  precision = 1.0e-4 
)
inline

Get time-over-threshold probability.

Parameters
pmtPMT signal processor
tot_nstime-over-threshold [ns]
NPEexpected number of photo-electrons
precisionprecision
Returns
probability

Definition at line 853 of file JPMTAnalogueSignalProcessor.hh.

857  {
858  int i = (int) (NPE - 5.0 * sqrt(NPE) - 0.5);
859  int M = (int) (NPE + 5.0 * sqrt(NPE) + 0.5);
860 
861  if (i < 1) { i = 1; }
862  if (M < i) { M = i; }
863 
864  double p = NPE * exp(-NPE) / (double) 1;
865 
866  for (int __i = 1; __i != i; ++__i) {
867  p *= NPE / __i;
868  }
869 
870  double P = 0.0;
871 
872  for (double p0 = 0.0; (p >= p0 || p > precision) && i != M; ++i, p0 = p, p *= NPE / (double) i) {
873  P += pmt.getTimeOverThresholdProbability(tot_ns, i) * p;
874  }
875 
876  return P;
877  }
do $JPP JMEstimator M
Definition: JMEstimator.sh:37
then set_variable FORMULA *[0] exp(-0.5 *(x-[1])*(x-[1])/([2]*[2]))*exp(-0.5 *(y-[1])*(y-[1])/([2]*[2]))" JF2 -o $WORKDIR/f2.root -F "$FORMULA" -@ "p0
then $DIR JPlotNPE PDG P
Definition: JPlotNPE-PDG.sh:60
bool JDETECTOR::operator< ( const JPMTIdentifier first,
const JPMTIdentifier second 
)
inline

Less than operator for PMT identifiers.

Parameters
firstPMT identifier
secondPMT identifier
Returns
true if first PMT lower than second PMT; else false

Definition at line 165 of file JPMTIdentifier.hh.

166  {
167  if (first.getModuleID() == second.getModuleID())
168  return first.getPMTAddress() < second.getPMTAddress();
169  else
170  return first.getModuleID() < second.getModuleID();
171  }
int getModuleID() const
Get module identifier.
int getPMTAddress() const
Get PMT identifier (= TDC).
bool JDETECTOR::operator== ( const JPMTIdentifier first,
const JPMTIdentifier second 
)
inline

Equal operator for PMT identifiers.

Parameters
firstPMT identifier
secondPMT identifier
Returns
true if first PMT equal second PMT; else false

Definition at line 181 of file JPMTIdentifier.hh.

182  {
183  return (first.getModuleID() == second.getModuleID() &&
184  first.getPMTAddress() == second.getPMTAddress());
185  }
int getModuleID() const
Get module identifier.
int getPMTAddress() const
Get PMT identifier (= TDC).
std::string JDETECTOR::getLabel ( const JPMTIdentifier id)
inline

Get PMT label for monitoring and other applications.


The format is "(XXXXXXXXXX,YY)", where XXXXXXXXXX is the module idetifier and YY the PMT readout channel.

Parameters
idPMT identifier
Returns
label

Definition at line 195 of file JPMTIdentifier.hh.

196  {
197  using namespace std;
198  using namespace JPP;
199 
200  return MAKE_STRING("(" << FILL(10,'0') << id.getID() << "," << FILL(2,'0') << id.getPMTAddress() << ")");
201  }
#define MAKE_STRING(A)
Make string.
Definition: JPrint.hh:142
Auxiliary data structure for sequence of same character.
Definition: JManip.hh:328
double JDETECTOR::getSurvivalProbability ( const JPMTParameters parameters)
inline

Get model dependent probability that a one photo-electron hit survives the simulation of the PMT assuming QE = 1.

Parameters
parametersPMT parameters
Returns
probability

Definition at line 32 of file JPMTParametersToolkit.hh.

33  {
35  const int NPE = 1;
36 
37  data.QE = 1.0;
38 
40  }
*fatal Wrong number of arguments esac JCookie sh typeset Z DETECTOR typeset Z SOURCE_RUN typeset Z TARGET_RUN set_variable PARAMETERS_FILE $WORKDIR parameters
Definition: diff-Tuna.sh:38
Data structure for PMT parameters.
double QE
relative quantum efficiency
virtual double getSurvivalProbability(const int NPE) const override
Probability that a hit survives the simulation of the PMT.
double JDETECTOR::getHitProbability ( const double  QE,
const double  mu 
)
inline

Get ratio of hit probabilities for given QE and expectation value of the number of photo-electrons.


The ratio corresponds to the hit probability with given QE divided by that with QE = 1.
The expectation value is defined for a two-fold (or higher) coincidence.

Parameters
QEQE
muexpectation value
Returns
ratio

Definition at line 52 of file JPMTParametersToolkit.hh.

53  {
54  if (mu > 0.0)
55  return (1.0 - exp(-QE*mu)) / (1.0 - exp(-mu));
56  else
57  return QE;
58  }
then set_variable FORMULA *[0] exp(-0.5 *(x-[1])*(x-[1])/([2]*[2]))*exp(-0.5 *(y-[1])*(y-[1])/([2]*[2]))" JF2 -o $WORKDIR/f2.root -F "$FORMULA" -@ "p0
double JDETECTOR::getMaximalHitProbability ( const double  mu)
inline

Get maximal ratio of hit probabilities for given QE and expectation value of the number of photo-electrons.


The ratio corresponds to the hit probability with infinite QE divided by that with QE = 1.
The expectation value is defined for a two-fold (or higher) coincidence.

Parameters
muexpectation value
Returns
ratio

Definition at line 69 of file JPMTParametersToolkit.hh.

70  {
71  using namespace std;
72 
73  if (mu > 0.0)
74  return 1.0 / (1.0 - exp(-mu));
75  else
76  return numeric_limits<double>::max();
77  }
then set_variable FORMULA *[0] exp(-0.5 *(x-[1])*(x-[1])/([2]*[2]))*exp(-0.5 *(y-[1])*(y-[1])/([2]*[2]))" JF2 -o $WORKDIR/f2.root -F "$FORMULA" -@ "p0
double JDETECTOR::getQE ( const double  R,
const double  mu 
)
inline

Get QE for given ratio of hit probabilities and expectation value of the number of photo-electrons.


The ratio corresponds to the hit probability with given QE divided by that with QE = 1.
The expectation value is defined for a two-fold (or higher) coincidence.

Parameters
Rratio
muexpectation value
Returns
QE

Definition at line 89 of file JPMTParametersToolkit.hh.

90  {
91  if (R < getMaximalHitProbability(mu)) {
92 
93  if (mu > 0.0)
94  return -log(1.0 - R*(1.0 - exp(-mu))) / mu;
95  else
96  return R;
97 
98  } else {
99 
100  THROW(JValueOutOfRange, "Inconsistent arguments at method getQE(" << R << "," << mu <<")");
101  }
102  }
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
Definition: JException.hh:670
then set_variable FORMULA *[0] exp(-0.5 *(x-[1])*(x-[1])/([2]*[2]))*exp(-0.5 *(y-[1])*(y-[1])/([2]*[2]))" JF2 -o $WORKDIR/f2.root -F "$FORMULA" -@ "p0
then usage $script[distance] fi case set_variable R
Definition: JDrawLED.sh:40
double getMaximalHitProbability(const double mu)
Get maximal ratio of hit probabilities for given QE and expectation value of the number of photo-elec...
double JDETECTOR::getChargeProbability ( const JPMTSignalProcessorInterface pmt,
const double  npe,
const double  NPE,
const double  precision = 1.0e-4 
)
inline

Get charge probability.

Parameters
pmtPMT signal processor
npemeasured number of photo-electrons
NPEexpected number of photo-electrons
precisionprecision
Returns
probability

Definition at line 415 of file JPMTSignalProcessorInterface.hh.

419  {
420  int i = (int) (NPE - 5.0 * sqrt(NPE));
421 
422  if (i < 1) {
423  i = 1;
424  }
425 
426  double p = NPE * exp(-NPE) / (double) 1;
427 
428  for (int __i = 1; __i != i; ++__i) {
429  p *= NPE / __i;
430  }
431 
432  double P = 0.0;
433 
434  for (double p0 = 0.0; (p >= p0 || p > precision); ++i, p0 = p, p *= NPE / (double) i) {
435  P += pmt.getChargeProbability(npe, i) * p;
436  }
437 
438  return P;
439  }
then set_variable FORMULA *[0] exp(-0.5 *(x-[1])*(x-[1])/([2]*[2]))*exp(-0.5 *(y-[1])*(y-[1])/([2]*[2]))" JF2 -o $WORKDIR/f2.root -F "$FORMULA" -@ "p0
virtual double getChargeProbability(const double npe, const int NPE) const
Get probability for given charge.
then $DIR JPlotNPE PDG P
Definition: JPlotNPE-PDG.sh:60
bool JDETECTOR::operator< ( const JPhotoElectron first,
const JPhotoElectron second 
)
inline

Less than operator for photo-elecrons.

Parameters
firstfirst photo-electron
secondsecond photo-electron
Returns
true if first photo-electron earlier than second; else false

Definition at line 68 of file JPMTSimulator.hh.

69  {
70  return first.t_ns < second.t_ns;
71  }
bool JDETECTOR::operator< ( const JPMTSignal first,
const JPMTSignal second 
)
inline

Less than operator for PMT signals.

Parameters
firstfirst PMT signal
secondsecond PMT signal
Returns
true if first PMT signal earlier than second; else false

Definition at line 112 of file JPMTSimulator.hh.

113  {
114  return first.t_ns < second.t_ns;
115  }
double t_ns
time [ns]
bool JDETECTOR::operator< ( const JPMTPulse first,
const JPMTPulse second 
)
inline

Less than operator for PMT pulses.

Parameters
firstfirst PMT pulse
secondsecond PMT pulse
Returns
true if first PMT pulse earlier than second; else false

Definition at line 156 of file JPMTSimulator.hh.

157  {
158  return first.t_ns < second.t_ns;
159  }
double t_ns
time [ns]
JTimeRange JDETECTOR::getTimeRange ( const JPMTData< JPMTSignal > &  input)
inline

Get time range (i.e. earlist and latest hit time) of PMT data.

Parameters
inputPMT data
Returns
time range

Definition at line 285 of file JPMTSimulator.hh.

286  {
287  JTimeRange range(JTimeRange::DEFAULT_RANGE);
288 
289  for (JPMTData<JPMTSignal>::const_iterator hit = input.begin(); hit != input.end(); ++hit) {
290  range.include(hit->t_ns);
291  }
292 
293  return range;
294  }
JTOOLS::JRange< double > JTimeRange
Type definition for time range (unit [ns]).
z range($ZMAX-$ZMIN)< $MINIMAL_DZ." fi fi mv $WORKDIR/fit.root $MODULE_ROOT typeset -Z 4 STRING typeset -Z 2 FLOOR JPlot1D -f $
Definition: module-Z:fit.sh:84
std::vector< JElement_t >::const_iterator const_iterator
JTimeRange JDETECTOR::getTimeRange ( const JModuleData input)
inline

Get time range (i.e. earlist and latest hit time) of module data.

Parameters
inputmodule data
Returns
time range

Definition at line 303 of file JPMTSimulator.hh.

304  {
305  JTimeRange range(JTimeRange::DEFAULT_RANGE);
306 
307  for (JModuleData::const_iterator frame = input.begin(); frame != input.end(); ++frame) {
308  for (JModuleData::value_type::const_iterator hit = frame->begin(); hit != frame->end(); ++hit) {
309  range.include(hit->t_ns);
310  }
311  }
312 
313  return range;
314  }
JTOOLS::JRange< double > JTimeRange
Type definition for time range (unit [ns]).
z range($ZMAX-$ZMIN)< $MINIMAL_DZ." fi fi mv $WORKDIR/fit.root $MODULE_ROOT typeset -Z 4 STRING typeset -Z 2 FLOOR JPlot1D -f $
Definition: module-Z:fit.sh:84
std::vector<std::string> JDETECTOR::getPMTStatusBits ( const JType< std::string > &  type)
inline

Get PMT status bits.

Parameters
typetype
Returns
status bits

Definition at line 296 of file JStatus.hh.

297  {
299  }
static const JGetPMTStatusBit getPMTStatusBit
Function object to map key to PMT status bit.
Definition: JStatus.hh:281
then echo The file $DIR KM3NeT_00000001_00000000 root already please rename or remove it first
const array_type< JValue_t > & make_array(const JValue_t(&array)[N])
Method to create array of values.
Definition: JVectorize.hh:37
std::vector<int> JDETECTOR::getPMTStatusBits ( const JType< int > &  type)
inline

Get PMT status bits.

Parameters
typetype
Returns
status bits

Definition at line 308 of file JStatus.hh.

309  {
310  return JPP::make_array(getPMTStatusBit.begin(), getPMTStatusBit.end(), &JGetPMTStatusBit::value_type::second);
311  }
static const JGetPMTStatusBit getPMTStatusBit
Function object to map key to PMT status bit.
Definition: JStatus.hh:281
const array_type< JValue_t > & make_array(const JValue_t(&array)[N])
Method to create array of values.
Definition: JVectorize.hh:37
template<class T >
std::vector<T> JDETECTOR::getPMTStatusBits ( )
inline

Get PMT status bits.

Returns
status bits

Definition at line 320 of file JStatus.hh.

321  {
322  return getPMTStatusBits(JType<T>());
323  }
std::vector< std::string > getPMTStatusBits(const JType< std::string > &type)
Get PMT status bits.
Definition: JStatus.hh:296
bool JDETECTOR::operator< ( const JVersion first,
const JVersion second 
)
inline

Less-than operator for versions.

Parameters
firstfirst version
secondsecond version
Returns
true if first version before second; else false

Definition at line 181 of file JVersion.hh.

182  {
183  return first.getVariant() < second.getVariant();
184  }
const std::string & getVariant() const
Get variant.
Definition: JVersion.hh:89

Variable Documentation

const double JDETECTOR::TIME_OVER_THRESHOLD_NS = 25.08

Specification for time-over-threshold corresponding to a one photo-electron pulse.

Definition at line 30 of file JDetector/JCalibration.hh.

const double JDETECTOR::NOMINAL_GAIN = 1.0

Specification for normalized gain corresponding to a one photo-electron pulse.

Definition at line 35 of file JDetector/JCalibration.hh.

const std::string JDETECTOR::User_t = "User"
static

Detector calibration key words for JSON I/O.

Definition at line 39 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Location_t = "Location"
static

Definition at line 40 of file JDetectorCalibration.hh.

const std::string JDETECTOR::StartTime_t = "StartTime"
static

Definition at line 41 of file JDetectorCalibration.hh.

const std::string JDETECTOR::EndTime_t = "EndTime"
static

Definition at line 42 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Comment_t = "Comment"
static

Definition at line 43 of file JDetectorCalibration.hh.

const std::string JDETECTOR::UUID_t = "UUID"
static

Definition at line 44 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Type_t = "Type"
static

Definition at line 47 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Parameters_t = "Parameters"
static

Definition at line 48 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Tests_t = "Tests"
static

Definition at line 49 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Data_t = "Data"
static

Definition at line 50 of file JDetectorCalibration.hh.

const std::string JDETECTOR::RunNumber_t = "RUN_NUMBER"
static

Definition at line 51 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Name_t = "Name"
static

Definition at line 52 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Unit_t = "Unit"
static

Definition at line 53 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Values_t = "Values"
static

Definition at line 54 of file JDetectorCalibration.hh.

const std::string JDETECTOR::PMTT0s_t = "PMTT0s"
static

Definition at line 57 of file JDetectorCalibration.hh.

const std::string JDETECTOR::PMTSupplyVoltage_t = "PMT_Supply_Voltage"
static

Definition at line 58 of file JDetectorCalibration.hh.

const std::string JDETECTOR::PMTThreshold_t = "PMT_Threshold"
static

Definition at line 59 of file JDetectorCalibration.hh.

const std::string JDETECTOR::PMTGain_t = "PMT_Gain"
static

Definition at line 60 of file JDetectorCalibration.hh.

const std::string JDETECTOR::DOMPositions_t = "DOMPositions"
static

Definition at line 61 of file JDetectorCalibration.hh.

const std::string JDETECTOR::DOMRotations_t = "DOMRotations"
static

Definition at line 62 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Test_t = "Test"
static

Definition at line 65 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Target_t = "Target"
static

Definition at line 66 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Outcome_t = "Outcome"
static

Definition at line 67 of file JDetectorCalibration.hh.

const std::string JDETECTOR::UPI_t = "UPI"
static

Definition at line 70 of file JDetectorCalibration.hh.

const std::string JDETECTOR::PBS_t = "PBS"
static

Definition at line 71 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Variant_t = "Variant"
static

Definition at line 72 of file JDetectorCalibration.hh.

const std::string JDETECTOR::PMTSerial_t = "PMTSerial"
static

Definition at line 73 of file JDetectorCalibration.hh.

const std::string JDETECTOR::DOMSerial_t = "DOMSerial"
static

Definition at line 74 of file JDetectorCalibration.hh.

const std::string JDETECTOR::DOMId_t = "DOMId"
static

Definition at line 75 of file JDetectorCalibration.hh.

const std::string JDETECTOR::T0_t = "T0"
static

Definition at line 78 of file JDetectorCalibration.hh.

const std::string JDETECTOR::PX_t = "PX"
static

Definition at line 79 of file JDetectorCalibration.hh.

const std::string JDETECTOR::PY_t = "PY"
static

Definition at line 80 of file JDetectorCalibration.hh.

const std::string JDETECTOR::PZ_t = "PZ"
static

Definition at line 81 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Q0_t = "Q0"
static

Definition at line 82 of file JDetectorCalibration.hh.

const std::string JDETECTOR::QX_t = "QX"
static

Definition at line 83 of file JDetectorCalibration.hh.

const std::string JDETECTOR::QY_t = "QY"
static

Definition at line 84 of file JDetectorCalibration.hh.

const std::string JDETECTOR::QZ_t = "QZ"
static

Definition at line 85 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Unitless_t = "-"
static

Definition at line 88 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Volt_t = "V"
static

Definition at line 89 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Result_t = "Result"
static

Definition at line 92 of file JDetectorCalibration.hh.

const std::string JDETECTOR::OK_t = "OK"
static

Definition at line 93 of file JDetectorCalibration.hh.

const std::string JDETECTOR::Failed_t = "FAILED"
static

Definition at line 94 of file JDetectorCalibration.hh.

const double JDETECTOR::PIEZO_DELAYTIME_US = 170.0
static

Piezo delay time [us].

Definition at line 19 of file JDetectorSupportkit.hh.

const double JDETECTOR::HYDROPHONE_DELAYTIME_US = 50.0
static

Hydrophone delay time [us].

Definition at line 20 of file JDetectorSupportkit.hh.

const double JDETECTOR::TBARZ_M = 1.0
static

T-bar position relative to seabed [m].

Definition at line 22 of file JDetectorSupportkit.hh.

const char* const JDETECTOR::GENDET_DETECTOR_FILE_FORMAT = "det"
static

File name extensions.

file format used by gendet

Definition at line 57 of file JDetectorToolkit.hh.

const char* const JDETECTOR::BINARY_DETECTOR_FILE_FORMAT = "dat"
static

JIO binary file format.

Definition at line 58 of file JDetectorToolkit.hh.

const char* const JDETECTOR::KM3NET_DETECTOR_FILE_FORMAT = "detx"
static

KM3NeT standard ASCII format

Definition at line 59 of file JDetectorToolkit.hh.

const char* const JDETECTOR::ZIPPED_DETECTOR_FILE_FORMAT = "gz"
static

zipped KM3NeT standard ASCII format

Definition at line 60 of file JDetectorToolkit.hh.

const char* const JDETECTOR::GDML_DETECTOR_FILE_FORMAT = "gdml"
static

KM3Sim input format.

Definition at line 61 of file JDetectorToolkit.hh.

const char* const JDETECTOR::GDML_SCHEMA = getenv("GDML_SCHEMA_DIR")
static

directory necessary for correct GDML header output

Definition at line 63 of file JDetectorToolkit.hh.

const char* const JDETECTOR::CAN_MARGIN_M = getenv("CAN_MARGIN_M")
static

extension of the detector size to comply with the can definition

Definition at line 64 of file JDetectorToolkit.hh.

const char* const JDETECTOR::G4GDML_DEFAULT_SCHEMALOCATION = "http://service-spi.web.cern.ch/service-spi/app/releases/GDML/schema/gdml.xsd"
static

Definition at line 65 of file JDetectorToolkit.hh.

JRotation JDETECTOR::getRotation
static

Function object to get rotation matrix to go from first to second module.

Definition at line 792 of file JDetectorToolkit.hh.

const JGetDetectorVersion JDETECTOR::getDetectorVersion
static

Function object to map detector variant to detector version.

Definition at line 238 of file JDetectorVersion.hh.

const JPutDetectorVersion JDETECTOR::putDetectorVersion(getDetectorVersion)
static

Function object to map detector version to detector variant.

const int JDETECTOR::LED_BEACON_PMT_TYPE = 2
static

PMT type of LED beacon.

Definition at line 37 of file JMonteCarloDetector.hh.

const JTransitionTimeProbability38 JDETECTOR::p38

Definition at line 3156 of file JPMTTransitTimeGenerator.hh.

const JTransitionTimeProbability41 JDETECTOR::p41

Definition at line 3157 of file JPMTTransitTimeGenerator.hh.

JDETECTOR::getTransitionTime
static

Function object to generate transition time.

JDETECTOR::getTransitionTimeProbability
static

Function object of transition time prabability.

const JTransitionTimeProbability2D JDETECTOR::getTransitionTimeProbability2D
static

Function object of twofold transition time prabability.

Definition at line 2153 of file JPMTTransitTimeProbability.hh.

const JGetPMTStatusBit JDETECTOR::getPMTStatusBit
static

Function object to map key to PMT status bit.

Definition at line 281 of file JStatus.hh.

const JPutPMTStatusBit JDETECTOR::putPMTStatusBit(getPMTStatusBit)
static

Function object to map PMT status bit to key.

const JStringCounter JDETECTOR::getNumberOfStrings
static

Function object to count unique strings.

Definition at line 95 of file JStringCounter.hh.