1 #ifndef IC_CRTDETSIMALG_H
2 #define IC_CRTDETSIMALG_H
5 #include "art/Framework/Principal/Handle.h"
6 #include "fhiclcpp/ParameterSet.h"
7 #include "nurandom/RandomUtils/NuRandomService.h"
19 #include "CLHEP/Random/RandomEngine.h"
20 #include "CLHEP/Random/RandFlat.h"
21 #include "CLHEP/Random/RandGauss.h"
22 #include "CLHEP/Random/RandPoisson.h"
33 #include "TGeoManager.h"
65 vector<pair<ChanData,AuxDetIDE>>
data;
79 const uint32_t adid,
const uint32_t adsid,
const vector<AuxDetIDE>& ides);
80 vector<pair<CRTData, vector<AuxDetIDE>>>
CreateData();
155 double t0,
float npeMean,
float r);
159 void FillAdcArr(
const vector<ChanData>& data, uint16_t arr[32]);
map< int, int > chanlayer
double fTDelayRMSGausSigma
Time delay RMS fit: Gaussian width.
Functions to help with numbers.
double fTDelayNorm
Time delay fit: Gaussian normalization.
double fLayerCoincidenceWindowM
Time window for two layer coincidence between MINOS modules [ns].
pair< double, double > GetTransAtten(const double pos)
double fLayerCoincidenceWindowC
Time window for two layer coincidence in a CERN module [ns].
bool fApplyCoincidenceM
Whether or not to apply coincidence between hits in adjacent layers.
double fDeadTime
Dead Time inherent in the front-end electronics.
void FillAdcArr(const vector< ChanData > &data, uint16_t arr[32])
vector< pair< ChanData, AuxDetIDE > > data
uint16_t fQThresholdC
ADC charge threshold for CERN system [ADC].
double fStripCoincidenceWindow
Time window for two-fiber coincidence [ns].
uint16_t fQThresholdD
ADC charge threshold for DC system [ADC].
double fQPed
ADC offset for the single-peak peak mean [ADC].
uint16_t fQThresholdM
ADC charge threshold for MINOS system [ADC].
double fQ0
Average energy deposited for mips in 1cm for charge scaling [GeV].
double fPropDelayError
Delay in pulse arrival time, uncertainty [ns/m].
ChanData FillChanData(int channel, uint16_t adc, uint64_t ts)
double fTDelayOffset
Time delay fit: Gaussian baseline offset.
double fTResInterpolator
Interpolator time resolution [ns].
double fTDelayRMSExpScale
Time delay RMS fit: Exponential scale.
double fTDelaySigma
Time delay fit: Gaussian width.
auto vector(Vector const &v)
Returns a manipulator which will print the specified array.
uint16_t fQMax
ADC saturation value [ADC].
double fBiasTime
Hard cut off for follow-up hits after primary trigger to bias ADC level.
object containing MC truth information necessary for making RawDigits and doing back tracking ...
bool fApplyCoincidenceC
Whether or not to apply coincidence between hits in adjacent layers.
map< uint8_t, Tagger > fTaggers
bool fUseBirks
Whether or not to apply Birks' quenching to light output.
double fQSlope
Slope in mean ADC / Npe [ADC].
vector< pair< CRTData, vector< AuxDetIDE > > > CreateData()
double fKbirks
Birks' constant [cm/MeV].
CRTDetSimAlg(fhicl::ParameterSet const &p, CLHEP::HepRandomEngine &fRandEngine)
art framework interface to geometry description for auxiliary detectors
double fQRMS
ADC single-pe spectrum width [ADC].
double fGlobalT0Offset
Time delay fit: Gaussian normalization.
Single hit (self trigger) of a CRT board.
CRTData FillCRTData(uint8_t mac, uint32_t entry, uint64_t t0, uint64_t ts1, uint16_t adc[32])
double fPropDelay
Delay in pulse arrival time [ns/m].
bool fApplyStripCoinC
Whether or not to apply coincence between fibers in a strip (c modules only)
double fTDelayRMSGausShift
Time delay RMS fit: Gaussian x shift.
double fTDelayShift
Time delay fit: Gaussian x shift.
double fTDelayRMSGausNorm
Time delay RMS fit: Gaussian normalization.
map< int, int > fRegCounts
Encapsulate the geometry of an auxiliary detector.
double fTDelayRMSExpShift
Time delay RMS fit: Exponential x shift.
double fTDelayRMSExpNorm
Time delay RMS fit: Exponential normalization.
void FillTaggers(detinfo::DetectorClocksData const &clockData, const uint32_t adid, const uint32_t adsid, const vector< AuxDetIDE > &ides)
CLHEP::HepRandomEngine & fRandEngine
Contains all timing reference information for the detector.
constexpr double dist(const TReal *x, const TReal *y, const unsigned int dimension)
void reconfigure(fhicl::ParameterSet const &p)
MC truth information to make RawDigits and do back tracking.
CRTCommonUtils * fCrtutils
Class def header for a class ElecClock.
double GetLongAtten(const double dist)
bool fUseEdep
Use the true G4 energy deposited, assume mip if false.
Class representing the time measured by an electronics clock.
double fLayerCoincidenceWindowD
Time window for two layer coincidence in a DC module [ns].
uint64_t GetChannelTriggerTicks(detinfo::ElecClock &clock, double t0, float npeMean, float r)
art framework interface to geometry description
bool fApplyCoincidenceD
Whether or not to apply coincidence between hits in adjacent layers.