List of all members | Public Types | Public Member Functions | Static Public Member Functions | Protected Types | Protected Attributes | Private Member Functions | Private Attributes
MdMuonIntegratorAG::MdMuonIntegrator Class Reference

Obtain the estimated number of muons with the ADC channel. More...

#include <MdMuonIntegratorAG/MdMuonIntegrator.h>

Inheritance diagram for MdMuonIntegratorAG::MdMuonIntegrator:
Inheritance graph
[legend]

Public Types

enum  ResultFlag { eSuccess, eFailure, eBreakLoop, eContinueLoop }
 Flag returned by module methods to the RunController. More...
 
enum  VersionInfoType {
  eFilename = 1, eRevisionNumber = 2, eDate = 3, eTime = 4,
  eLastEditor = 5
}
 Different types of version info that can be retrieved from GetVersionInfo. More...
 

Public Member Functions

VModule::ResultFlag Finish ()
 Finish: invoked at end of the run (NOT end of the event) More...
 
utl::StopwatchGetStopwatch ()
 
const utl::StopwatchGetStopwatch () const
 
std::string GetVersionInfo (const VersionInfoType v) const
 Retrieve different sorts of module version info. More...
 
VModule::ResultFlag Init ()
 Initialize: invoked at beginning of run (NOT beginning of event) More...
 
void InitTiming ()
 
 MdMuonIntegrator ()
 
VModule::ResultFlag Run (evt::Event &e)
 Run: invoked once per event. More...
 
ResultFlag RunWithTiming (evt::Event &event)
 
 ~MdMuonIntegrator ()
 

Static Public Member Functions

static std::string GetResultFlagByName (const ResultFlag flag)
 

Protected Types

enum  InfoLevel { eInfoNone = 0, eInfoFinal = 1, eInfoIntermediate = 2, eInfoDebug = 3 }
 

Protected Attributes

int fInfoLevel = 0
 

Private Member Functions

void GetModuleFirstMuon (int &leadingMuonBin, int &lastMuonBin, mevt::Module &module)
 Get module first muon. More...
 
void GetMuonsWithADC (const evt::Event &event, mevt::Module &module)
 Obtain muon number estimation with ADC channel. More...
 
void GetSignalCharge (double &charge, const double leadingMuonBin, const double lastMuonBin, const unsigned int windowSize, const utl::TraceUSI &adcTrace)
 Calculate signal charge. More...
 
void GetUncertainties (double &errorLow, double &errorHigh, const double nMu, const double resolution)
 Obtain uncertainties. More...
 
 REGISTER_MODULE ("MdMuonIntegratorAG", MdMuonIntegrator)
 

Private Attributes

int fBaseLineHighLimit
 Flag to indicate the high limit for the baseline calculation (number of bins). More...
 
int fBaseLineLowLimit
 Flag to indicate the low limit for the baseline calculation (number of bins). More...
 
int fDelayBinaryADC
 Flag to indicate the delay between the binary and ADC channel (number of bins). More...
 
double fHighThreshold
 Flag to indicate the low threshold to define the charge integration window. In terms of baseline RMS. More...
 
double fLowThreshold
 Flag to indicate the low threshold to define the charge integration window. In terms of baseline RMS. More...
 
int fShowerMaxWidth
 Flag to indicate the integration window if the signal does not reach the threshold (number of bins). More...
 

Detailed Description

Obtain the estimated number of muons with the ADC channel.

Date
18 Jan 2020

Definition at line 24 of file MdMuonIntegrator.h.

Member Enumeration Documentation

enum fwk::VModule::InfoLevel
protectedinherited
Enumerator
eInfoNone 
eInfoFinal 
eInfoIntermediate 
eInfoDebug 

Definition at line 125 of file VModule.h.

enum fwk::VModule::ResultFlag
inherited

Flag returned by module methods to the RunController.

Enumerator
eSuccess 

Report success to RunController.

eFailure 

Report failure to RunController, causing RunController to terminate execution.

eBreakLoop 

Break current loop. It works for nested loops too!

eContinueLoop 

Skip remaining modules in the current loop and continue with next iteration of the loop.

Definition at line 60 of file VModule.h.

Different types of version info that can be retrieved from GetVersionInfo.

Enumerator
eFilename 
eRevisionNumber 
eDate 
eTime 
eLastEditor 

Definition at line 110 of file VModule.h.

Constructor & Destructor Documentation

MdMuonIntegratorAG::MdMuonIntegrator::MdMuonIntegrator ( )
inline

Definition at line 27 of file MdMuonIntegrator.h.

MdMuonIntegratorAG::MdMuonIntegrator::~MdMuonIntegrator ( )
inline

Definition at line 28 of file MdMuonIntegrator.h.

Member Function Documentation

VModule::ResultFlag MdMuonIntegratorAG::MdMuonIntegrator::Finish ( )
inlinevirtual

Finish: invoked at end of the run (NOT end of the event)

This method is for things that should be done at the end of the run (for example, closing files or writing out histograms) {You must override this method in your concrete module}

Implements fwk::VModule.

Definition at line 32 of file MdMuonIntegrator.h.

References fwk::VModule::eSuccess.

void MdMuonIntegratorAG::MdMuonIntegrator::GetModuleFirstMuon ( int &  leadingMuonBin,
int &  lastMuonBin,
mevt::Module module 
)
private
void MdMuonIntegratorAG::MdMuonIntegrator::GetMuonsWithADC ( const evt::Event event,
mevt::Module module 
)
private
std::string fwk::VModule::GetResultFlagByName ( const ResultFlag  flag)
staticinherited
void MdMuonIntegratorAG::MdMuonIntegrator::GetSignalCharge ( double &  charge,
const double  leadingMuonBin,
const double  lastMuonBin,
const unsigned int  windowSize,
const utl::TraceUSI adcTrace 
)
private

Calculate signal charge.

Definition at line 205 of file MdMuonIntegrator.cc.

References utl::Trace< T >::At(), utl::Trace< T >::GetSize(), std::pow(), and sqrt().

utl::Stopwatch& fwk::VModule::GetStopwatch ( )
inlineinherited

Definition at line 106 of file VModule.h.

References fwk::VModule::fStopwatch.

const utl::Stopwatch& fwk::VModule::GetStopwatch ( ) const
inlineinherited

Definition at line 107 of file VModule.h.

References fwk::VModule::fStopwatch.

void MdMuonIntegratorAG::MdMuonIntegrator::GetUncertainties ( double &  errorLow,
double &  errorHigh,
const double  nMu,
const double  resolution 
)
private

Obtain uncertainties.

Definition at line 301 of file MdMuonIntegrator.cc.

References std::pow(), utl::s, and sqrt().

std::string fwk::VModule::GetVersionInfo ( const VersionInfoType  v) const
inherited
VModule::ResultFlag MdMuonIntegratorAG::MdMuonIntegrator::Init ( )
virtual

Initialize: invoked at beginning of run (NOT beginning of event)

This method is for things that should be done once at the beginning of a run (for example, booking histograms, performing calculations that need to be done only once, initializing parameters) {You must override this method in your concrete module}

Implements fwk::VModule.

Definition at line 27 of file MdMuonIntegrator.cc.

References io::eSuccess, fwk::CentralConfig::GetInstance(), fwk::CentralConfig::GetTopBranch(), and utl::LoadConfig().

void fwk::VModule::InitTiming ( )
inlineinherited

Definition at line 95 of file VModule.h.

References fwk::VModule::fStopwatch, and utl::Stopwatch::Reset().

MdMuonIntegratorAG::MdMuonIntegrator::REGISTER_MODULE ( "MdMuonIntegratorAG"  ,
MdMuonIntegrator   
)
private
VModule::ResultFlag MdMuonIntegratorAG::MdMuonIntegrator::Run ( evt::Event event)
virtual

Run: invoked once per event.

This method is for things that should be done once per event {You must override this method in your concrete module}

Implements fwk::VModule.

Definition at line 45 of file MdMuonIntegrator.cc.

References mevt::MEvent::CountersBegin(), mevt::MEvent::CountersEnd(), DEBUGLOG, io::eSuccess, mevt::Counter::GetId(), mevt::Module::GetId(), mevt::Module::GetRejectionReason(), evt::Event::HasMEvent(), INFO, mevt::Counter::IsRejected(), mevt::Module::IsRejected(), mevt::Counter::ModulesBegin(), mevt::Counter::ModulesEnd(), and WARNING.

ResultFlag fwk::VModule::RunWithTiming ( evt::Event event)
inlineinherited

Member Data Documentation

int MdMuonIntegratorAG::MdMuonIntegrator::fBaseLineHighLimit
private

Flag to indicate the high limit for the baseline calculation (number of bins).

Definition at line 53 of file MdMuonIntegrator.h.

int MdMuonIntegratorAG::MdMuonIntegrator::fBaseLineLowLimit
private

Flag to indicate the low limit for the baseline calculation (number of bins).

Definition at line 50 of file MdMuonIntegrator.h.

int MdMuonIntegratorAG::MdMuonIntegrator::fDelayBinaryADC
private

Flag to indicate the delay between the binary and ADC channel (number of bins).

Definition at line 65 of file MdMuonIntegrator.h.

double MdMuonIntegratorAG::MdMuonIntegrator::fHighThreshold
private

Flag to indicate the low threshold to define the charge integration window. In terms of baseline RMS.

Definition at line 59 of file MdMuonIntegrator.h.

int fwk::VModule::fInfoLevel = 0
protectedinherited
double MdMuonIntegratorAG::MdMuonIntegrator::fLowThreshold
private

Flag to indicate the low threshold to define the charge integration window. In terms of baseline RMS.

Definition at line 56 of file MdMuonIntegrator.h.

int MdMuonIntegratorAG::MdMuonIntegrator::fShowerMaxWidth
private

Flag to indicate the integration window if the signal does not reach the threshold (number of bins).

Definition at line 62 of file MdMuonIntegrator.h.


The documentation for this class was generated from the following files:

, generated on Tue Sep 26 2023.