All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
Compute_dEdxProcessor2021 Class Reference

Compute dE/dx Processor2021
This processor calculates the dE/dx for every track. More...

#include <Compute_dEdxProcessor2021.hh>

Inheritance diagram for Compute_dEdxProcessor2021:
[legend]

Public Member Functions

virtual ProcessornewProcessor ()
 
 Compute_dEdxProcessor2021 ()
 
virtual void init ()
 
virtual void processRunHeader (LCRunHeader *run)
 
virtual void processEvent (LCEvent *evt)
 
virtual void check (LCEvent *evt)
 
virtual void end ()
 

Private Member Functions

 Compute_dEdxProcessor2021 (const Compute_dEdxProcessor2021 &)=delete
 
Compute_dEdxProcessor2021operator= (const Compute_dEdxProcessor2021 &)=delete
 
std::pair< double, double > CalculateEnergyLoss (TrackerHitVec &hitVec, Track *trk)
 
double getSmearing (double dEdx)
 
double get_Corrected_dEdx (float dedx, float trklambda)
 

Private Attributes

std::string _description = ""
 
std::string _LDCTrackCollection = ""
 
LCCollection * _LDCCol = NULL
 
bool _writedEdx = true
 
float _energyLossErrorTPC = 0
 
float _lowerTrunFrac = 0
 
float _upperTrunFrac = 0
 
std::vector< float > _errexp = {}
 
int _dxStrategy = 0
 
bool _StratCompHist = false
 
bool _StratCompHistWeight = false
 
std::string _StratCompHistFiles = ""
 
std::random_device seed_gen {}
 
std::default_random_engine * engine = NULL
 
std::uniform_real_distribution dist {}
 
bool _isSmearing = 0
 
float _smearingFactor = 0
 
float _TPC_inner = 0
 
float _TPC_outer = 0
 
float _TPC_padHeight = 0
 
float _bField = 0
 
TH2 * _BBHist_Strategy1 {}
 
TH2 * _BBHist_Strategy2 {}
 
TH2 * _BBHist_Strategy3 {}
 
bool _angularcorrdEdx = false
 
std::vector< float > _par {}
 

Detailed Description

Compute dE/dx Processor2021
This processor calculates the dE/dx for every track.


Input collections and prerequisites

The processor requires a collection of tracks that contains the corresponding track hits.
Every track hit that lies within the boundaries of the TPC is used.
dE is the deposited energy of the hit.
dx is the distance between the hits and can be calculated in 3 different ways.
A truncation of the hits with the lowest and highest dE7Dx values is performed.
Then the mean is calculated (truncation-mean method).
The dEdx is smeared according to test beam results .
Finally, the dEdx is corrected for angular effects (in the previous versions of this processor, before 2021, this was performed before smearing..

Output

The calculated dE/dx is attached to the track.
This is only possible if the the track collection allows write access.
Bethe-Bloch histograms (root TH2D) can be generated for every dx strategy.
Both outputs are optional.

Parameters
_LDCTrackCollection- name of the input track collection
default: MarlinTrkTracks
_writedEdx- flag indicating if calculated dE/dx should be attached to track
If fully reconstructed tracks are used as input collection this can be switched off to only generate histograms.
default: true
_energyLossErrorTPC- the dE/dx resolution
default: 0.054 (5.4%)
_lowerTrunFrac- lower truncation fraction for truncated-mean method
The hits with the lowest <_lowerTrunFrac> dE/dx values are rejected.
default: 0.08 (8%; ALEPH: 8%)
_upperTrunFrac- upper truncation fraction for truncated-mean method
The hits with the highest <_upperTrunFrac> dE/dx values are rejected.
default: 0.3 (30%; ALEPH: 40%)
_isSmearing- flag indicating if additional smearing should be applied
This compensates for a 'too good' processor outcome, compared to test beam results.
default: false
_smearingFactor- width of the Gaussian function used for the additional smearing
default: 0.035 (3.5%)
_errexp- scaling exponents of the dE/dx error for path length and number of hits, respectively
default: {-0.34, -0.45}
_dxStrategy- ID specifying which strategy for calculating dx should be used
Strategy 1: hit-to-hit distance
Strategy 2: hit-to-hit path length of projected hits (do not use at the moment)
Strategy 3: path over hit row
default: 1
If none of the above is chosen, the processor defaults to 1.
_StratCompHist- flag indicating if Bethe-Bloch histograms for each dx strategy should created.
default: false
_StratCompHistWeight- flag indicating if Bethe-Bloch histograms (if chosen) should be filled with a sqrt(number-of-track-hits) weighting.
default: false (-> weight for each track = 1)
_StratCompHistFiles- file names of the generated dx strategy comparison histograms (if chosen).
The respective strategy number and '.png' is added.
default: dEdx_Histo_Strategy (-> "dEdx_Histo_Strategy1.png", etc.)
_angularcorrdEdx- flag indicating if the dEdx will be corrected for angular correction default=true
_par{}- floats indication the parametrization of the correction: f3 = 1 / (_par[0] + _par[1] * lambda + _par[2] * pow(lambda,2) + _par[3] * pow(lambda,3) )
Author
M. Kurata, KEK adapted by U. Einhaus, DESY readapted by A. Irles, IFIC
Version
$Id$

Definition at line 73 of file Compute_dEdxProcessor2021.hh.

Constructor & Destructor Documentation

Compute_dEdxProcessor2021::Compute_dEdxProcessor2021 ( )

Definition at line 41 of file Compute_dEdxProcessor2021.cc.

Compute_dEdxProcessor2021::Compute_dEdxProcessor2021 ( const Compute_dEdxProcessor2021 )
privatedelete

Member Function Documentation

std::pair< double, double > Compute_dEdxProcessor2021::CalculateEnergyLoss ( TrackerHitVec &  hitVec,
Track *  trk 
)
private

Definition at line 257 of file Compute_dEdxProcessor2021.cc.

void Compute_dEdxProcessor2021::check ( LCEvent *  evt)
virtual

Definition at line 216 of file Compute_dEdxProcessor2021.cc.

void Compute_dEdxProcessor2021::end ( )
virtual

Definition at line 219 of file Compute_dEdxProcessor2021.cc.

double Compute_dEdxProcessor2021::get_Corrected_dEdx ( float  dedx,
float  trklambda 
)
private

Definition at line 474 of file Compute_dEdxProcessor2021.cc.

double Compute_dEdxProcessor2021::getSmearing ( double  dEdx)
private

Definition at line 466 of file Compute_dEdxProcessor2021.cc.

void Compute_dEdxProcessor2021::init ( )
virtual

Definition at line 127 of file Compute_dEdxProcessor2021.cc.

virtual Processor* Compute_dEdxProcessor2021::newProcessor ( )
inlinevirtual

Definition at line 75 of file Compute_dEdxProcessor2021.hh.

Compute_dEdxProcessor2021& Compute_dEdxProcessor2021::operator= ( const Compute_dEdxProcessor2021 )
privatedelete
void Compute_dEdxProcessor2021::processEvent ( LCEvent *  evt)
virtual

Definition at line 171 of file Compute_dEdxProcessor2021.cc.

void Compute_dEdxProcessor2021::processRunHeader ( LCRunHeader *  run)
virtual

Definition at line 168 of file Compute_dEdxProcessor2021.cc.

Member Data Documentation

bool Compute_dEdxProcessor2021::_angularcorrdEdx = false
private

Definition at line 125 of file Compute_dEdxProcessor2021.hh.

TH2* Compute_dEdxProcessor2021::_BBHist_Strategy1 {}
private

Definition at line 120 of file Compute_dEdxProcessor2021.hh.

TH2* Compute_dEdxProcessor2021::_BBHist_Strategy2 {}
private

Definition at line 121 of file Compute_dEdxProcessor2021.hh.

TH2* Compute_dEdxProcessor2021::_BBHist_Strategy3 {}
private

Definition at line 122 of file Compute_dEdxProcessor2021.hh.

float Compute_dEdxProcessor2021::_bField = 0
private

Definition at line 117 of file Compute_dEdxProcessor2021.hh.

std::string Compute_dEdxProcessor2021::_description = ""
private

Definition at line 92 of file Compute_dEdxProcessor2021.hh.

int Compute_dEdxProcessor2021::_dxStrategy = 0
private

Definition at line 101 of file Compute_dEdxProcessor2021.hh.

float Compute_dEdxProcessor2021::_energyLossErrorTPC = 0
private

Definition at line 97 of file Compute_dEdxProcessor2021.hh.

std::vector<float> Compute_dEdxProcessor2021::_errexp = {}
private

Definition at line 100 of file Compute_dEdxProcessor2021.hh.

bool Compute_dEdxProcessor2021::_isSmearing = 0
private

Definition at line 110 of file Compute_dEdxProcessor2021.hh.

LCCollection* Compute_dEdxProcessor2021::_LDCCol = NULL
private

Definition at line 94 of file Compute_dEdxProcessor2021.hh.

std::string Compute_dEdxProcessor2021::_LDCTrackCollection = ""
private

Definition at line 93 of file Compute_dEdxProcessor2021.hh.

float Compute_dEdxProcessor2021::_lowerTrunFrac = 0
private

Definition at line 98 of file Compute_dEdxProcessor2021.hh.

std::vector<float> Compute_dEdxProcessor2021::_par {}
private

Definition at line 126 of file Compute_dEdxProcessor2021.hh.

float Compute_dEdxProcessor2021::_smearingFactor = 0
private

Definition at line 111 of file Compute_dEdxProcessor2021.hh.

bool Compute_dEdxProcessor2021::_StratCompHist = false
private

Definition at line 102 of file Compute_dEdxProcessor2021.hh.

std::string Compute_dEdxProcessor2021::_StratCompHistFiles = ""
private

Definition at line 104 of file Compute_dEdxProcessor2021.hh.

bool Compute_dEdxProcessor2021::_StratCompHistWeight = false
private

Definition at line 103 of file Compute_dEdxProcessor2021.hh.

float Compute_dEdxProcessor2021::_TPC_inner = 0
private

Definition at line 114 of file Compute_dEdxProcessor2021.hh.

float Compute_dEdxProcessor2021::_TPC_outer = 0
private

Definition at line 115 of file Compute_dEdxProcessor2021.hh.

float Compute_dEdxProcessor2021::_TPC_padHeight = 0
private

Definition at line 116 of file Compute_dEdxProcessor2021.hh.

float Compute_dEdxProcessor2021::_upperTrunFrac = 0
private

Definition at line 99 of file Compute_dEdxProcessor2021.hh.

bool Compute_dEdxProcessor2021::_writedEdx = true
private

Definition at line 95 of file Compute_dEdxProcessor2021.hh.

std::uniform_real_distribution Compute_dEdxProcessor2021::dist {}
private

Definition at line 109 of file Compute_dEdxProcessor2021.hh.

std::default_random_engine* Compute_dEdxProcessor2021::engine = NULL
private

Definition at line 108 of file Compute_dEdxProcessor2021.hh.

std::random_device Compute_dEdxProcessor2021::seed_gen {}
private

Definition at line 107 of file Compute_dEdxProcessor2021.hh.


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