LArSoft  v06_74_01
Liquid Argon Software toolkit - http://larsoft.org/
sim::MCHit Class Reference

#include "MCHit.h"

Public Member Functions

 MCHit ()
 Default ctor. More...
 
void Reset ()
 Method to reset. More...
 
void SetCharge (float qsum, float amp)
 Setter function for charge/amplitude. More...
 
void SetTime (const float peak, const float width)
 Setter function for time. More...
 
void SetParticleInfo (const float vtx[], const float energy, const int trackId)
 Setter function for partile info. More...
 
float PeakTime () const
 Getter for start time. More...
 
float PeakWidth () const
 Getter for start time. More...
 
float Charge (bool max=false) const
 Getter for "charge". More...
 
const float * PartVertex () const
 Getter for particle vertex. More...
 
float PartEnergy () const
 Getter for particle energy. More...
 
int PartTrackId () const
 Getter for track ID. More...
 
bool operator< (const MCHit &rhs) const
 For sorting with MCHit itself. More...
 
bool operator< (const float &rhs) const
 For sorting with generic time. More...
 

Private Attributes

float fSignalTime
 where peak resides in waveform ticks More...
 
float fSignalWidth
 width (1sigma) in waveform ticks More...
 
float fPeakAmp
 Peak amplitude (ADC) More...
 
float fCharge
 Charge sum (ADC integral over MCWire) More...
 
float fPartVertex [3]
 particle vertex (x,y,z) information More...
 
float fPartEnergy
 particle energy deposition (dE) in MeV More...
 
int fPartTrackId
 particle G4 Track ID More...
 

Detailed Description

Definition at line 14 of file MCHit.h.

Constructor & Destructor Documentation

sim::MCHit::MCHit ( )
inline

Default ctor.

Definition at line 19 of file MCHit.h.

References Reset().

20  {
21  Reset();
22  }
void Reset()
Method to reset.
Definition: MCHit.h:25

Member Function Documentation

float sim::MCHit::Charge ( bool  max = false) const
inline

Getter for "charge".

Definition at line 85 of file MCHit.h.

References max.

85 { return ( max ? fPeakAmp : fCharge ); }
float fCharge
Charge sum (ADC integral over MCWire)
Definition: MCHit.h:44
float fPeakAmp
Peak amplitude (ADC)
Definition: MCHit.h:43
Int_t max
Definition: plot.C:27
bool sim::MCHit::operator< ( const MCHit rhs) const
inline

For sorting with MCHit itself.

Definition at line 97 of file MCHit.h.

References fSignalTime.

97 { return fSignalTime < rhs.fSignalTime; }
float fSignalTime
where peak resides in waveform ticks
Definition: MCHit.h:40
bool sim::MCHit::operator< ( const float &  rhs) const
inline

For sorting with generic time.

Definition at line 100 of file MCHit.h.

100 { return fSignalTime < rhs; }
float fSignalTime
where peak resides in waveform ticks
Definition: MCHit.h:40
float sim::MCHit::PartEnergy ( ) const
inline

Getter for particle energy.

Definition at line 91 of file MCHit.h.

References fPartEnergy.

91 { return fPartEnergy; }
float fPartEnergy
particle energy deposition (dE) in MeV
Definition: MCHit.h:51
int sim::MCHit::PartTrackId ( ) const
inline

Getter for track ID.

Definition at line 94 of file MCHit.h.

References fPartTrackId.

94 { return fPartTrackId; }
int fPartTrackId
particle G4 Track ID
Definition: MCHit.h:52
const float* sim::MCHit::PartVertex ( ) const
inline

Getter for particle vertex.

Definition at line 88 of file MCHit.h.

References fPartVertex.

88 { return fPartVertex; }
float fPartVertex[3]
particle vertex (x,y,z) information
Definition: MCHit.h:50
float sim::MCHit::PeakTime ( ) const
inline

Getter for start time.

Definition at line 79 of file MCHit.h.

References fSignalTime.

Referenced by hit::MCHitAnaExample::analyze().

79 { return fSignalTime; }
float fSignalTime
where peak resides in waveform ticks
Definition: MCHit.h:40
float sim::MCHit::PeakWidth ( ) const
inline

Getter for start time.

Definition at line 82 of file MCHit.h.

References fSignalWidth.

82 { return fSignalWidth; }
float fSignalWidth
width (1sigma) in waveform ticks
Definition: MCHit.h:41
void sim::MCHit::Reset ( )
inline

Method to reset.

Definition at line 25 of file MCHit.h.

References fCharge, fPartEnergy, fPartTrackId, fPartVertex, fPeakAmp, fSignalTime, fSignalWidth, sim::kINVALID_FLOAT, kINVALID_FLOAT, and sim::kINVALID_INT.

Referenced by MCHit().

26  {
29  for(int i=0; i<3; ++i)
33  }
const int kINVALID_INT
Definition: MCLimits.h:16
float fCharge
Charge sum (ADC integral over MCWire)
Definition: MCHit.h:44
static const float kINVALID_FLOAT
Definition: TruncMean.h:35
int fPartTrackId
particle G4 Track ID
Definition: MCHit.h:52
float fPartEnergy
particle energy deposition (dE) in MeV
Definition: MCHit.h:51
float fPeakAmp
Peak amplitude (ADC)
Definition: MCHit.h:43
float fPartVertex[3]
particle vertex (x,y,z) information
Definition: MCHit.h:50
float fSignalWidth
width (1sigma) in waveform ticks
Definition: MCHit.h:41
float fSignalTime
where peak resides in waveform ticks
Definition: MCHit.h:40
const float kINVALID_FLOAT
Definition: MCLimits.h:12
void sim::MCHit::SetCharge ( float  qsum,
float  amp 
)
inline

Setter function for charge/amplitude.

Definition at line 58 of file MCHit.h.

Referenced by hit::MCHitFinder::produce().

58 { fCharge=qsum; fPeakAmp=amp; }
float fCharge
Charge sum (ADC integral over MCWire)
Definition: MCHit.h:44
float fPeakAmp
Peak amplitude (ADC)
Definition: MCHit.h:43
void sim::MCHit::SetParticleInfo ( const float  vtx[],
const float  energy,
const int  trackId 
)
inline

Setter function for partile info.

Definition at line 68 of file MCHit.h.

References energy.

Referenced by hit::MCHitFinder::produce().

71  {
72  for(size_t i=0; i<3; ++i)
73  fPartVertex[i] = vtx[i];
75  fPartTrackId = trackId;
76  }
int fPartTrackId
particle G4 Track ID
Definition: MCHit.h:52
float fPartEnergy
particle energy deposition (dE) in MeV
Definition: MCHit.h:51
double energy
Definition: plottest35.C:25
float fPartVertex[3]
particle vertex (x,y,z) information
Definition: MCHit.h:50
void sim::MCHit::SetTime ( const float  peak,
const float  width 
)
inline

Setter function for time.

Definition at line 61 of file MCHit.h.

Referenced by hit::MCHitAnaExample::analyze(), and hit::MCHitFinder::produce().

62  {
63  fSignalTime = peak;
64  fSignalWidth = width;
65  }
float fSignalWidth
width (1sigma) in waveform ticks
Definition: MCHit.h:41
float fSignalTime
where peak resides in waveform ticks
Definition: MCHit.h:40

Member Data Documentation

float sim::MCHit::fCharge
private

Charge sum (ADC integral over MCWire)

Definition at line 44 of file MCHit.h.

Referenced by Reset().

float sim::MCHit::fPartEnergy
private

particle energy deposition (dE) in MeV

Definition at line 51 of file MCHit.h.

Referenced by PartEnergy(), and Reset().

int sim::MCHit::fPartTrackId
private

particle G4 Track ID

Definition at line 52 of file MCHit.h.

Referenced by PartTrackId(), and Reset().

float sim::MCHit::fPartVertex[3]
private

particle vertex (x,y,z) information

Definition at line 50 of file MCHit.h.

Referenced by PartVertex(), and Reset().

float sim::MCHit::fPeakAmp
private

Peak amplitude (ADC)

Definition at line 43 of file MCHit.h.

Referenced by Reset().

float sim::MCHit::fSignalTime
private

where peak resides in waveform ticks

Definition at line 40 of file MCHit.h.

Referenced by operator<(), PeakTime(), and Reset().

float sim::MCHit::fSignalWidth
private

width (1sigma) in waveform ticks

Definition at line 41 of file MCHit.h.

Referenced by PeakWidth(), and Reset().


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