Go to the documentation of this file. 1 #ifndef __JDETECTOR__JK40DEFAULTSIMULATORINTERFACE__
2 #define __JDETECTOR__JK40DEFAULTSIMULATORINTERFACE__
62 for (iterator i = begin(); i != end(); ++i) {
119 const int N = module.size();
130 for (
int pmt = 0; pmt != N; ++pmt) {
134 if (rateL0_Hz > 0.0) {
136 const double t_ns = 1.0e9 / rateL0_Hz;
138 for (
double t1 = period.getLowerLimit() + gRandom->Exp(t_ns); t1 < period.getUpperLimit(); t1 += gRandom->Exp(t_ns)) {
147 double totalRateL1_Hz = 0.0;
149 for (
int i = 0; i != N; ++i) {
153 if (totalRateL1_Hz > 0.0) {
155 const double t_ns = 1.0e9 / totalRateL1_Hz;
157 double t1 = period.getLowerLimit() + gRandom->Exp(t_ns);
159 if (t1 < period.getUpperLimit()) {
164 for (
int i = 0; i != N; ++i) {
168 for (
int j = i + 1;
j != N; ++
j) {
181 for (
int i = 0; i != N; ++i) {
185 for (
int j = 0;
j != N; ++
j) {
191 for ( ; t1 < period.getUpperLimit(); t1 += gRandom->Exp(t_ns)) {
213 for (
unsigned int pmtN = pmt2; M != 0; --M) {
215 for (
int i = 0; i != N; ++i) {
248 for (JBuffer1D_t::const_iterator i = buffer.begin(); i != buffer.end(); ++i) {
256 unsigned int index = 0;
258 for (JBuffer1D_t::const_iterator i = buffer.begin(); i != buffer.end() && (x -= *i) > 0.0; ++i, ++index) {}
260 if (index == buffer.size()) {
static double getSigma()
Get intrinsic time smearing of K40 coincidences.
Data structure for PMT data corresponding to a detector module.
JBuffer2D_t probability2D
This correlation matrix is a two-dimensional array in which element [i][j] corresponds to the probabi...
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
virtual double getMultiplesRate(const JModuleIdentifier &module, const int M) const =0
Get multiples rate as a function of optical module.
void resize(size_t size)
Resize.
static unsigned int getRandomIndex(const JBuffer1D_t &buffer, const double random)
Get index based on random value.
int getID() const
Get identifier.
JBuffer1D_t rateL1_Hz
Multiples rate as a function of the multiplicity.
#define THROW(JException_t, A)
Marco for throwing exception with std::ostream compatible message.
virtual double getSinglesRate(const JPMTIdentifier &pmt) const =0
Get singles rate as a function of PMT.
Data structure for a composite optical module.
virtual void generateHits(const JModule &module, const JTimeRange &period, JModuleData &output) const
Generate hits.
Auxiliary class for object identification.
JBuffer1D_t probabilityND
This probability vector is a one-dimensional array in which element [i] corresponds to the probabilit...
JBuffer1D_t probability1D
This probability vector is a one-dimensional array in which element [i] corresponds to the probabilit...
JK40DefaultSimulatorInterface()
Default constructor.
Interface for simulation of K40 background.
Data structure for PMT analogue signal.
virtual double getProbability(const double ct) const =0
Get probability of coincidence.
double getDot(const JFirst_t &first, const JSecond_t &second)
Get dot product of objects.
Default K40 simulator interface.
Auxiliary classes and methods for detector calibration.
Exception for numerical precision error.