ATLAS Offline Software
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
Trk::MaterialEffectsUpdator Class Referencefinal

#include <MaterialEffectsUpdator.h>

Inheritance diagram for Trk::MaterialEffectsUpdator:
Collaboration diagram for Trk::MaterialEffectsUpdator:

Public Types

typedef IMaterialEffectsUpdator::ICache ICache
 

Public Member Functions

 MaterialEffectsUpdator (const std::string &, const std::string &, const IInterface *)
 AlgTool like constructor. More...
 
virtual ~MaterialEffectsUpdator ()
 Virtual destructor. More...
 
virtual StatusCode initialize () override
 AlgTool initailize method. More...
 
virtual std::unique_ptr< TrackParametersupdate (ICache &cache, const TrackParameters *parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const override
 Updator interface (full update for a layer) —> ALWAYS pointer to new TrackParameters is returned. More...
 
virtual std::unique_ptr< TrackParametersupdate (ICache &cache, const TrackParameters *parm, const MaterialEffectsOnTrack &meff, Trk::ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const override
 Updator interface (full update for a layer) according to user input through MaterialEffectsOnTrack —> ALWAYS pointer to new TrackParameters is returned. More...
 
virtual std::unique_ptr< TrackParameterspreUpdate (ICache &cache, const TrackParameters *parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const override
 Updator interface (pre-update for a layer): —> ALWAYS pointer to new TrackParameters is returned. More...
 
virtual std::unique_ptr< TrackParameterspostUpdate (ICache &cache, const TrackParameters &parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const override final
 Updator interface (post-update for a layer): —> ALWAYS pointer to new TrackParameters is returned if no postUpdate is to be done : return nullptr. More...
 
virtual std::unique_ptr< TrackParametersupdate (ICache &cache, const TrackParameters &parm, const MaterialProperties &mprop, double pathcorrection, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const override final
 Dedicated Updator interface:-> create new track parameters. More...
 
virtual void validationAction (ICache &cache) const override final
 Validation Action - calls the writing and resetting of the TTree variables. More...
 
virtual void modelAction (ICache &cache, const TrackParameters *parm=nullptr) const override final
 Only has an effect if m_landauMode == true. More...
 
virtual std::unique_ptr< TrackParametersupdate (const TrackParameters *parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const override final
 Updator interface (full update for a layer): More...
 
virtual std::unique_ptr< TrackParametersupdate (const TrackParameters *parm, const MaterialEffectsOnTrack &meff, Trk::ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const override final
 User updator interface (full update for a layer): More...
 
virtual std::unique_ptr< TrackParameterspreUpdate (const TrackParameters *parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const override final
 Updator interface (pre-update for a layer): More...
 
virtual std::unique_ptr< TrackParameterspostUpdate (const TrackParameters &parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const override final
 Updator interface (pre-update for a layer): More...
 
virtual std::unique_ptr< TrackParametersupdate (const TrackParameters &parm, const MaterialProperties &mprop, double pathcorrection, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const override final
 Updator interface: MaterialProperties based material update. More...
 
virtual void validationAction () const override final
 Validation Action: outside access to internal validation steps Optional. More...
 
virtual void modelAction (const TrackParameters *parm=nullptr) const override final
 Model Action: Provides the possibility of doing non-local MaterialEffectsUpdates for different models Optional. More...
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 
virtual ICache getCache () const
 Creates an instance of the cache to be used. More...
 

Static Public Member Functions

static const InterfaceID & interfaceID ()
 AlgTool and IAlgTool interface methods. More...
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

std::unique_ptr< TrackParametersupdateImpl (ICache &cache, const TrackParameters *parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const
 
std::unique_ptr< TrackParametersupdateImpl (ICache &cache, const TrackParameters *parm, const MaterialEffectsOnTrack &meff, Trk::ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const
 
std::unique_ptr< TrackParameterspreUpdateImpl (ICache &cache, const TrackParameters *parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const
 
std::unique_ptr< TrackParameterspostUpdateImpl (ICache &cache, const TrackParameters &parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const
 
std::unique_ptr< TrackParametersupdateImpl (ICache &cache, const TrackParameters *parm, const MaterialProperties &mprop, double pathcorrection, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const
 
std::unique_ptr< TrackParametersupdateImpl (ICache &cache, const TrackParameters &parm, const MaterialProperties &mprop, double pathcorrection, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const
 
bool checkCovariance (AmgSymMatrix(5) &updated) const
 A simple check method for the 'removeNoise' update model. More...
 
TrackParametersfinalLandauCovarianceUpdate (const TrackParameters *parm) const
 
ICachegetTLSCache () const
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Static Private Member Functions

static void validationActionImpl (ICache &cache)
 
static void modelActionImpl (ICache &cache, const TrackParameters *parm=nullptr)
 

Private Attributes

bool m_doCompoundLayerCheck
 turn on/off the necessary checks when we may have compound layers More...
 
bool m_doEloss
 steer energy loss On/Off from outside More...
 
bool m_doMs
 steer multiple scattering On/Off from outside More...
 
bool m_forceMomentum
 Force the momentum to be a specific value. More...
 
bool m_xKalmanStraggling
 the momentum Error as calculated in xKalman More...
 
bool m_useMostProbableEloss
 use the most probable energy loss More...
 
bool m_msgOutputValidationDirection
 validation direction used for screen output More...
 
bool m_msgOutputCorrections
 screen output of actual corrections More...
 
bool m_validationMode
 Switch for validation mode. More...
 
bool m_validationIgnoreUnmeasured
 Ignore unmeasured TrackParameters (Navigation!) More...
 
bool m_landauMode
 If in Landau mode, error propagation is done as for landaus. More...
 
int m_validationDirection
 validation direction More...
 
double m_momentumCut
 Minimal momentum cut for update. More...
 
double m_momentumMax
 Maximal momentum cut for update. More...
 
double m_forcedMomentum
 Forced momentum value. More...
 
ToolHandle< IEnergyLossUpdatorm_eLossUpdator
 AlgoTool for EnergyLoss updates. More...
 
ToolHandle< IMultipleScatteringUpdatorm_msUpdator
 AlgoTool for MultipleScatterin effects. More...
 
ToolHandle< IMaterialMapperm_materialMapper
 the material mapper for recording the layer material More...
 
boost::thread_specific_ptr< ICachem_cache_tls
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

Point-like (also called surface-based) update of TrackParameters and the associated covariance

Pre/Post/update notation.

Given a sensitive detector element, it can be (e.g silicon sensors) that most of the material corresponds to the sensor itself or is located behind it.

In this case the material effects would be post-update with respect to the measurement update on the given surface, e.g in a Kalman filter procedure. The same material would have to be taken into account before, pre-update, the measurement update in the smoothing/ backward filtering kalman filtering process.

Pre/Post update make sense in these specific contexts. For a uniform detector or non-sensitive material a full update is applied.

Author
Andre.nosp@m.as.S.nosp@m.alzbu.nosp@m.rger.nosp@m.@cern.nosp@m..ch
AthenaMT modifications Christos Anastopoulos

Definition at line 69 of file MaterialEffectsUpdator.h.

Member Typedef Documentation

◆ ICache

Definition at line 89 of file MaterialEffectsUpdator.h.

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ MaterialEffectsUpdator()

Trk::MaterialEffectsUpdator::MaterialEffectsUpdator ( const std::string &  t,
const std::string &  n,
const IInterface *  p 
)

AlgTool like constructor.

Definition at line 39 of file MaterialEffectsUpdator.cxx.

40  : AthAlgTool(t, n, p)
41  ,
42  // TrkParametersManipulator(),
44  , m_doEloss(true)
45  , m_doMs(true)
46  , m_forceMomentum(false)
47  , m_xKalmanStraggling(false)
48  , m_useMostProbableEloss(false)
50  , m_msgOutputCorrections(false)
51  , m_validationMode(false)
53  , m_landauMode(false)
58  , m_eLossUpdator("Trk::EnergyLossUpdator/AtlasEnergyLossUpdator")
59  , m_msUpdator("Trk::MultipleScatteringUpdator/AtlasMultipleScatteringUpdator")
60  , m_materialMapper("Trk::MaterialMapper/AtlasMaterialMapper")
61 {
62  declareInterface<IMaterialEffectsUpdator>(this);
63  // configuration (to be changed to new genconf style)
64  declareProperty("CheckForCompoundLayers", m_doCompoundLayerCheck);
65  declareProperty("EnergyLoss", m_doEloss);
66  declareProperty("EnergyLossUpdator", m_eLossUpdator);
67  declareProperty("MultipleScattering", m_doMs);
68  declareProperty("MultipleScatteringUpdator", m_msUpdator);
69  // the momentum cut for particle interactions
70  declareProperty("MinimalMomentum", m_momentumCut);
71  declareProperty("MaximalMomentum", m_momentumMax);
72  declareProperty("ForceMomentum", m_forceMomentum);
73  declareProperty("ForcedMomentumValue", m_forcedMomentum);
74  declareProperty("MostProbableEnergyLoss", m_useMostProbableEloss);
75  declareProperty("ScreenOutputValidationDirection", m_msgOutputValidationDirection);
76  declareProperty("ScreenOutputCorrections", m_msgOutputCorrections);
77  // run vaidation mode true/false
78  declareProperty("ValidationMode", m_validationMode);
79  declareProperty("ValidationIgnoreUnmeasured", m_validationIgnoreUnmeasured);
80  declareProperty("ValidationDirection", m_validationDirection);
81  declareProperty("ValidationMaterialMapper", m_materialMapper);
82  declareProperty("LandauMode", m_landauMode);
83 }

◆ ~MaterialEffectsUpdator()

Trk::MaterialEffectsUpdator::~MaterialEffectsUpdator ( )
virtualdefault

Virtual destructor.

Member Function Documentation

◆ checkCovariance()

bool Trk::MaterialEffectsUpdator::checkCovariance ( AmgSymMatrix(5) &  updated) const
private

A simple check method for the 'removeNoise' update model.

Definition at line 819 of file MaterialEffectsUpdator.cxx.

820 {
821  if (updated(Trk::phi, Trk::phi) > 0. && updated(Trk::theta, Trk::theta) > 0. &&
822  updated(Trk::qOverP, Trk::qOverP) > 0.) {
823  return true;
824  }
825 
826  // given an update
827  ATH_MSG_DEBUG(" [-] update material with 'removeNoise' results in negative covariance entries. Skipping update.");
828  return false;
829 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ finalLandauCovarianceUpdate()

TrackParameters* Trk::MaterialEffectsUpdator::finalLandauCovarianceUpdate ( const TrackParameters parm) const
private

◆ getCache()

virtual ICache Trk::IMaterialEffectsUpdator::getCache ( ) const
inlinevirtualinherited

Creates an instance of the cache to be used.

by the client.

Definition at line 87 of file IMaterialEffectsUpdator.h.

87 { return {}; }

◆ getTLSCache()

ICache& Trk::MaterialEffectsUpdator::getTLSCache ( ) const
inlineprivate

Definition at line 347 of file MaterialEffectsUpdator.h.

348  {
349  ICache* cache = m_cache_tls.get();
350  if (!cache) {
351  cache = new ICache();
352  m_cache_tls.reset(cache);
353  }
354  return *cache;
355  }

◆ initialize()

StatusCode Trk::MaterialEffectsUpdator::initialize ( )
overridevirtual

AlgTool initailize method.

Definition at line 91 of file MaterialEffectsUpdator.cxx.

92 {
93 
94  ATH_MSG_DEBUG("Minimal momentum cut for material update : " << m_momentumCut << " MeV");
95 
96  // retrieve the EnergyLoss Updator and Material Effects updator
97  if (m_doEloss) {
98  if (m_eLossUpdator.retrieve().isFailure()) {
99  ATH_MSG_FATAL("Failed to retrieve tool " << m_eLossUpdator
100  << ". No multiple scattering effects will be taken into account.");
101  m_doEloss = false;
102  return StatusCode::FAILURE;
103  }
104  ATH_MSG_DEBUG("Retrieved tool " << m_eLossUpdator);
105 
106  } else {
107  m_eLossUpdator.disable();
108  }
109 
110  if (m_doMs) {
111  if (m_msUpdator.retrieve().isFailure()) {
112  ATH_MSG_FATAL("Failed to retrieve tool " << m_msUpdator
113  << ". No energy loss effects will be taken into account.");
114  m_doMs = false;
115  return StatusCode::FAILURE;
116  }
117  ATH_MSG_DEBUG("Retrieved tool " << m_msUpdator);
118 
119  } else {
120  m_msUpdator.disable();
121  }
122 
123  // retrieve the material mapper for the validation mode
124  if (m_validationMode) {
125  if (m_materialMapper.retrieve().isFailure()) {
126  ATH_MSG_FATAL("Failed to retrieve tool " << m_materialMapper << ". No material recording.");
127  return StatusCode::FAILURE;
128  }
129  ATH_MSG_DEBUG("Retrieved tool " << m_materialMapper);
130 
131  } else {
132  m_materialMapper.disable();
133  }
134 
135  return StatusCode::SUCCESS;
136 }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ interfaceID()

static const InterfaceID& Trk::IMaterialEffectsUpdator::interfaceID ( )
inlinestaticinherited

AlgTool and IAlgTool interface methods.

Definition at line 52 of file IMaterialEffectsUpdator.h.

53  {
54  return IID_IMaterialEffectsUpdator;
55  }

◆ modelAction() [1/2]

virtual void Trk::MaterialEffectsUpdator::modelAction ( const TrackParameters param = nullptr) const
inlinefinaloverridevirtual

Model Action: Provides the possibility of doing non-local MaterialEffectsUpdates for different models Optional.

Implements Trk::IMaterialEffectsUpdator.

Definition at line 243 of file MaterialEffectsUpdator.h.

245  {
246  ICache& cache = getTLSCache();
247  modelActionImpl(cache, parm);
248  }

◆ modelAction() [2/2]

virtual void Trk::MaterialEffectsUpdator::modelAction ( ICache cache,
const TrackParameters parm = nullptr 
) const
inlinefinaloverridevirtual

Only has an effect if m_landauMode == true.

Resets mutable variables used for non-local calculation of energy loss if parm == 0. Otherwise, modifies parm with the final update of the covariance matrix

Implements Trk::IMaterialEffectsUpdator.

Definition at line 170 of file MaterialEffectsUpdator.h.

172  {
173  modelActionImpl(cache, parm);
174  }

◆ modelActionImpl()

void Trk::MaterialEffectsUpdator::modelActionImpl ( ICache cache,
const TrackParameters parm = nullptr 
)
staticprivate

Definition at line 814 of file MaterialEffectsUpdator.cxx.

815 {
816  cache.accumulatedElossSigma = 0;
817 }

◆ msg() [1/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ postUpdate() [1/2]

virtual std::unique_ptr<TrackParameters> Trk::MaterialEffectsUpdator::postUpdate ( const TrackParameters param,
const Layer sf,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
inlinefinaloverridevirtual

Updator interface (pre-update for a layer):

Implements Trk::IMaterialEffectsUpdator.

Definition at line 213 of file MaterialEffectsUpdator.h.

219  {
220  ICache& cache = getTLSCache();
221  return postUpdateImpl(cache, parm, sf, dir, particle, matupmode);
222  }

◆ postUpdate() [2/2]

virtual std::unique_ptr<TrackParameters> Trk::MaterialEffectsUpdator::postUpdate ( ICache cache,
const TrackParameters parm,
const Layer sf,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
inlinefinaloverridevirtual

Updator interface (post-update for a layer): —> ALWAYS pointer to new TrackParameters is returned if no postUpdate is to be done : return nullptr.

Implements Trk::IMaterialEffectsUpdator.

Definition at line 135 of file MaterialEffectsUpdator.h.

142  {
143  return postUpdateImpl(cache, parm, sf, dir, particle, matupmode);
144  }

◆ postUpdateImpl()

std::unique_ptr< Trk::TrackParameters > Trk::MaterialEffectsUpdator::postUpdateImpl ( ICache cache,
const TrackParameters parm,
const Layer sf,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
private

Definition at line 408 of file MaterialEffectsUpdator.cxx.

415  {
416  // no material properties - pass the parameters back
418  !lay.isOnLayer(parm.position())) {
419  return parm.uniqueClone();
420  }
421 
422  // get the quantities
423  const Trk::MaterialProperties* mprop = nullptr;
424  double postFactor = lay.postUpdateMaterialFactor(parm, dir);
425 
426  // no material properties - pass them back
427  if (postFactor < 0.01) {
428  return parm.uniqueClone();
429  }
430 
431  // set the output if restricted to the validation direction
432  bool outputFlag = m_msgOutputValidationDirection ? dir == int(m_validationDirection) : true;
433 
434  mprop = lay.fullUpdateMaterialProperties(parm);
435  double pathCorrection = std::abs(lay.surfaceRepresentation().pathCorrection(parm.position(), parm.momentum()));
436  pathCorrection *= postFactor;
437 
438  // exit if no material properties
439  if (!mprop) {
440  return parm.uniqueClone();
441  }
442 
443  // --------------------------------------------------------------------------------------------------
444  if (outputFlag) {
445  double layerR = lay.surfaceRepresentation().bounds().r();
446  double layerZ = lay.surfaceRepresentation().center().z();
447  double eta = parm.momentum().eta();
448  double sX0 = mprop->thicknessInX0();
449  double tX0 = pathCorrection * mprop->thicknessInX0();
450  ATH_MSG_VERBOSE(" [M] post material update, layer with [r,z] = [ " << layerR << ", " << layerZ << " ] - Index "
451  << lay.layerIndex());
452  ATH_MSG_VERBOSE(" thickness/X0 , path/X0 (eta: g.factor) = " << sX0 << " , " << tX0 << " (" << eta << ": "
453  << pathCorrection << ")");
454  }
455  // --------------------------------------------------------------------------------------------------
456  if (m_validationMode) {
457  cache.validationLayer = &lay;
458  }
459  return updateImpl(cache, parm, *mprop, pathCorrection, dir, particle, matupmode);
460 }

◆ preUpdate() [1/2]

virtual std::unique_ptr<TrackParameters> Trk::MaterialEffectsUpdator::preUpdate ( const TrackParameters param,
const Layer sf,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
inlinefinaloverridevirtual

Updator interface (pre-update for a layer):

Implements Trk::IMaterialEffectsUpdator.

Definition at line 202 of file MaterialEffectsUpdator.h.

208  {
209  ICache& cache = getTLSCache();
210  return preUpdateImpl(cache, parm, sf, dir, particle, matupmode);
211  }

◆ preUpdate() [2/2]

virtual std::unique_ptr<TrackParameters> Trk::MaterialEffectsUpdator::preUpdate ( ICache cache,
const TrackParameters parm,
const Layer sf,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
inlineoverridevirtual

Updator interface (pre-update for a layer): —> ALWAYS pointer to new TrackParameters is returned.

Implements Trk::IMaterialEffectsUpdator.

Definition at line 120 of file MaterialEffectsUpdator.h.

127  {
128  return preUpdateImpl(cache, parm, sf, dir, particle, matupmode);
129  }

◆ preUpdateImpl()

std::unique_ptr< Trk::TrackParameters > Trk::MaterialEffectsUpdator::preUpdateImpl ( ICache cache,
const TrackParameters parm,
const Layer sf,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
private

Definition at line 354 of file MaterialEffectsUpdator.cxx.

361  {
362  // no material properties - pass the parameters back
364  return parm->uniqueClone();
365  }
366 
367  // get the split factor
368  double preFactor = lay.preUpdateMaterialFactor(*parm, dir);
369  // return if the preFactor is less than one
370  if (preFactor < 0.01) {
371  return parm->uniqueClone();
372  }
373 
374  // get the material properties
375  const Trk::MaterialProperties* mprop = nullptr;
376 
377  // set the output if restricted to the validation direction
378  bool outputFlag = m_msgOutputValidationDirection ? dir == int(m_validationDirection) : true;
379 
380  mprop = lay.fullUpdateMaterialProperties(*parm);
381  double pathCorrection = std::abs(lay.surfaceRepresentation().pathCorrection(parm->position(), parm->momentum()));
382  pathCorrection *= preFactor;
383 
384  // exit if no mprop could be assigned
385  if (!mprop) {
386  return parm->uniqueClone();
387  }
388  // --------------------------------------------------------------------------------------------------
389  if (outputFlag) {
390  double layerR = lay.surfaceRepresentation().bounds().r();
391  double layerZ = lay.surfaceRepresentation().center().z();
392  double eta = parm->momentum().eta();
393  double sX0 = mprop->thicknessInX0();
394  double tX0 = pathCorrection * mprop->thicknessInX0();
395  ATH_MSG_VERBOSE(" [M] pre material update at layer with [r,z] = [ " << layerR << ", " << layerZ << " ] - Index "
396  << lay.layerIndex());
397  ATH_MSG_VERBOSE(" thickness/X0 , path/X0 (eta: g.factor) = " << sX0 << " , " << tX0 << " (" << eta << ": "
398  << pathCorrection << ")");
399  }
400  // --------------------------------------------------------------------------------------------------
401  if (m_validationMode) {
402  cache.validationLayer = &lay;
403  }
404  return updateImpl(cache, parm, *mprop, pathCorrection, dir, particle, matupmode);
405 }

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ update() [1/6]

virtual std::unique_ptr<TrackParameters> Trk::MaterialEffectsUpdator::update ( const TrackParameters param,
const MaterialProperties mprop,
double  pathcorrection,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
inlinefinaloverridevirtual

Updator interface: MaterialProperties based material update.

  • used by all Layer-based methods

Implements Trk::IMaterialEffectsUpdator.

Definition at line 224 of file MaterialEffectsUpdator.h.

231  {
232  ICache& cache = getTLSCache();
233  return updateImpl(
234  cache, parm, mprop, pathcorrection, dir, particle, matupmode);
235  }

◆ update() [2/6]

virtual std::unique_ptr<TrackParameters> Trk::MaterialEffectsUpdator::update ( const TrackParameters param,
const Layer sf,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
inlinefinaloverridevirtual

Updator interface (full update for a layer):

Implements Trk::IMaterialEffectsUpdator.

Definition at line 180 of file MaterialEffectsUpdator.h.

186  {
187 
188  ICache& cache = getTLSCache();
189  return updateImpl(cache, parm, sf, dir, particle, matupmode);
190  }

◆ update() [3/6]

virtual std::unique_ptr<TrackParameters> Trk::MaterialEffectsUpdator::update ( const TrackParameters param,
const MaterialEffectsOnTrack meff,
Trk::ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
inlinefinaloverridevirtual

User updator interface (full update for a layer):

Implements Trk::IMaterialEffectsUpdator.

Definition at line 192 of file MaterialEffectsUpdator.h.

197  {
198  ICache& cache = getTLSCache();
199  return updateImpl(cache, parm, meff, particle, matupmode);
200  }

◆ update() [4/6]

virtual std::unique_ptr<TrackParameters> Trk::MaterialEffectsUpdator::update ( ICache cache,
const TrackParameters parm,
const MaterialProperties mprop,
double  pathcorrection,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
inlinefinaloverridevirtual

Dedicated Updator interface:-> create new track parameters.

Implements Trk::IMaterialEffectsUpdator.

Definition at line 146 of file MaterialEffectsUpdator.h.

154  {
155  return updateImpl(
156  cache, parm, mprop, pathcorrection, dir, particle, matupmode);
157  }

◆ update() [5/6]

virtual std::unique_ptr<TrackParameters> Trk::MaterialEffectsUpdator::update ( ICache cache,
const TrackParameters parm,
const Layer sf,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
inlineoverridevirtual

Updator interface (full update for a layer) —> ALWAYS pointer to new TrackParameters is returned.

Implements Trk::IMaterialEffectsUpdator.

Definition at line 93 of file MaterialEffectsUpdator.h.

100  {
101  return updateImpl(cache, parm, sf, dir, particle, matupmode);
102  }

◆ update() [6/6]

virtual std::unique_ptr<TrackParameters> Trk::MaterialEffectsUpdator::update ( ICache cache,
const TrackParameters parm,
const MaterialEffectsOnTrack meff,
Trk::ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
inlineoverridevirtual

Updator interface (full update for a layer) according to user input through MaterialEffectsOnTrack —> ALWAYS pointer to new TrackParameters is returned.

Implements Trk::IMaterialEffectsUpdator.

Definition at line 107 of file MaterialEffectsUpdator.h.

113  {
114  return updateImpl(cache, parm, meff, particle, matupmode);
115  }

◆ updateImpl() [1/4]

std::unique_ptr< Trk::TrackParameters > Trk::MaterialEffectsUpdator::updateImpl ( ICache cache,
const TrackParameters parm,
const MaterialProperties mprop,
double  pathcorrection,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
private

Definition at line 641 of file MaterialEffectsUpdator.cxx.

649  {
650  // no material properties - pass them back
651  if (particle == Trk::geantino || (!m_doMs && !m_doEloss)) {
652  return parm.uniqueClone();
653  }
654 
655  // get the kinematics
656  double p = parm.momentum().mag();
657  double updateMomentum = (m_forceMomentum) ? m_forcedMomentum : p;
659  double E = std::sqrt(p * p + m * m);
660  double beta = p / E;
661 
662  // set the output if restricted to the validation direction
663  bool outputFlag = m_msgOutputValidationDirection ? dir == int(m_validationDirection) : true;
664 
665  // no material update below or above a certain cut value
666  if (p > m_momentumCut && p < m_momentumMax) {
667  // the updatedParameters - first a copy
668  AmgVector(5) updatedParameters(parm.parameters());
669 
670  // get the delta of the Energy
671  EnergyLoss energyLoss =
672  (m_doEloss)
673  ? m_eLossUpdator->energyLoss(matprop, updateMomentum, pathcorrection, dir, particle, m_useMostProbableEloss)
674  : EnergyLoss{};
675  // update for mean energy loss
676  double deltaE = energyLoss.deltaE() ;
677  double sigmaDeltaE = energyLoss.sigmaDeltaE();
678  if (m_landauMode && cache.accumulatedElossSigma != 0 && sigmaDeltaE != 0) {
679  if (dir == Trk::oppositeMomentum) {
680  deltaE += sigmaDeltaE * std::log(1 + cache.accumulatedElossSigma / sigmaDeltaE) +
681  cache.accumulatedElossSigma * std::log(1 + sigmaDeltaE / cache.accumulatedElossSigma);
682  } else {
683  deltaE -= sigmaDeltaE * std::log(1 + cache.accumulatedElossSigma / sigmaDeltaE) +
684  cache.accumulatedElossSigma * std::log(1 + sigmaDeltaE / cache.accumulatedElossSigma);
685  }
686 
687  cache.accumulatedElossSigma += sigmaDeltaE;
688  } else if (m_landauMode) {
689  cache.accumulatedElossSigma += sigmaDeltaE;
690  }
691 
692  double newP2 = (E + deltaE) * (E + deltaE) - m * m;
693  if (E + deltaE < -m) {
694  return nullptr; // protect against flip in correction
695  }
696  if (newP2 < m_momentumCut * m_momentumCut) {
697  return nullptr; // protect against FPE
698  }
699  double deltaP = std::sqrt(newP2) - p;
700  double sigmaQoverP = sigmaDeltaE / std::pow(beta * p, 2);
701 
702  updatedParameters[Trk::qOverP] = parm.charge() / (p + deltaP);
703 
704  // check if Parameters are measured parameters
705  std::optional<AmgSymMatrix(5)> updatedCovariance = std::nullopt;
706  if (parm.covariance() || (m_validationMode && !m_validationIgnoreUnmeasured)) {
707  // the new CovarianceMatrix - a copy first
708  updatedCovariance = AmgSymMatrix(5)(*parm.covariance());
709  // only update if msUpdator exists
710  double angularVariation =
711  (m_doMs) ? m_msUpdator->sigmaSquare(matprop, updateMomentum, pathcorrection, particle) : 0.;
712  // update the covariance entries - angular variation in phi has dependency on theta direction
713  // sign of the noise adding ----------------------------------------------------------------
714  int sign = int(matupmode);
715  // checks will only be done in the removeNoise mode
716  double sigmaDeltaPhiSq =
717  angularVariation / (std::sin(parm.parameters()[Trk::theta]) * std::sin(parm.parameters()[Trk::theta]));
718  double sigmaDeltaThetaSq = angularVariation;
719  // checks will only be done in the removeNoise mode
720  COVARIANCEUPDATEWITHCHECK((*updatedCovariance)(Trk::phi, Trk::phi), sign, sigmaDeltaPhiSq);
721  COVARIANCEUPDATEWITHCHECK((*updatedCovariance)(Trk::theta, Trk::theta), sign, sigmaDeltaThetaSq);
723  COVARIANCEUPDATEWITHCHECK((*updatedCovariance)(Trk::qOverP, Trk::qOverP), sign, sigmaQoverP * sigmaQoverP);
724  } else if (m_xKalmanStraggling) { /* to be filled in*/
725  } else if (m_landauMode) {
726  // subtract what we added up till now and add what we should add up till now
727  // Landau's 68% limit is best modeled by 1.6*sigmaParameter
728  (*updatedCovariance)(Trk::qOverP, Trk::qOverP) -=
729  sign * std::pow(1.6 * (cache.accumulatedElossSigma - p * p * sigmaQoverP) / (p * p), 2);
730  (*updatedCovariance)(Trk::qOverP, Trk::qOverP) +=
731  sign * std::pow(1.6 * cache.accumulatedElossSigma / ((p + deltaP) * (p + deltaP)), 2);
732  }
733 
734  // the checks for the remove Noise mode -----------------------------------------------------
735  if (matupmode == Trk::removeNoise && !checkCovariance(*updatedCovariance)) {
736  // the covariance is invalid
737  return nullptr;
738  }
739 
740  // create the ErrorMatrix // -------------------------------------- screen output
741  // --------------------------------------
742  if (outputFlag && m_msgOutputCorrections) {
743  double sigmaAngle = std::sqrt(angularVariation);
744  ATH_MSG_VERBOSE(" sigma(phi) / sigma(theta) = " << sigmaAngle / std::sin(parm.parameters()[Trk::theta]) << " / "
745  << sigmaAngle);
746  ATH_MSG_VERBOSE(" deltaP / sigmaQoverP = " << deltaP << " / " << sigmaQoverP);
747  }
748  // ----------------------------------------- validation section ----------------------------------
749  // validation if configured
751 
752  if (cache.validationLayer) {
753  // all you have from MaterialProperties
754  double pathInX0 = pathcorrection * matprop.thicknessInX0();
755  double A = 0.;
756  double Z = 0.;
757  double rho = 0.;
758  double l0 = 0.;
759  // or better take the extended version for more information
760  const Trk::MaterialProperties* extProperties = dynamic_cast<const Trk::MaterialProperties*>(&matprop);
761 
762  if (extProperties) {
763  A = extProperties->averageA();
764  Z = extProperties->averageZ();
765  rho = extProperties->averageRho();
766  l0 = extProperties->l0();
767  }
768 
769  Trk::AssociatedMaterial assMatHit(parm.position(),
770  pathInX0,
771  matprop.x0(),
772  l0,
773  A,
774  Z,
775  rho,
776  pathcorrection,
777  cache.validationLayer->enclosingTrackingVolume(),
778  cache.validationLayer);
779 
780  // record the Material hit ----------------------------------------------------------------
781  m_materialMapper->recordMaterialHit(assMatHit, parm.position());
782 
783  // the steps
784  cache.validationSteps++;
785  cache.validationPhi += parm.position().phi();
786  cache.validationEta += parm.position().eta();
787  // reset the validation layer
788  cache.validationLayer = nullptr;
789  }
790  }
791  // ------------------------------------------validation section ----------------------------------
792  }
793  return parm.associatedSurface().createUniqueTrackParameters(
794  updatedParameters[Trk::loc1],
795  updatedParameters[Trk::loc2],
796  updatedParameters[Trk::phi],
797  updatedParameters[Trk::theta],
798  updatedParameters[Trk::qOverP],
799  std::move(updatedCovariance)
800  );
801  }
802  return parm.uniqueClone();
803 }

◆ updateImpl() [2/4]

std::unique_ptr< Trk::TrackParameters > Trk::MaterialEffectsUpdator::updateImpl ( ICache cache,
const TrackParameters parm,
const Layer sf,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
private

Definition at line 140 of file MaterialEffectsUpdator.cxx.

147  {
148  // no material properties - pass them back
150  !lay.isOnLayer(parm->position())) {
151  return parm->uniqueClone();
152  }
153 
154  // get the quantities
155  const Trk::MaterialProperties* mprop = lay.fullUpdateMaterialProperties(*parm);
156  if (!mprop) {
157  return parm->uniqueClone();
158  }
159 
160  // get the real pathlength
161  double pathCorrection = std::abs(lay.surfaceRepresentation().pathCorrection(parm->position(), parm->momentum()));
162 
163  // --------------------------------------------------------------------------------------------------
164  if (m_validationMode) {
165  cache.validationLayer = &lay;
166  }
167  return updateImpl(cache, parm, *mprop, pathCorrection, dir, particle, matupmode);
168 }

◆ updateImpl() [3/4]

std::unique_ptr< Trk::TrackParameters > Trk::MaterialEffectsUpdator::updateImpl ( ICache cache,
const TrackParameters parm,
const MaterialEffectsOnTrack meff,
Trk::ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
private

Definition at line 171 of file MaterialEffectsUpdator.cxx.

177  {
178  // no material properties - pass them back
179  // TODO, if the parm doesn't have a surface (i.e. its in
180  // curvilinear) then should we fall through?
182  parm->associatedSurface() != meff.associatedSurface()) {
183  return parm->uniqueClone();
184  }
185 
186  // get the kinematics
187  double p = parm->momentum().mag();
188  double updateMomentum = (m_forceMomentum) ? m_forcedMomentum : p;
190  double E = std::sqrt(p * p + m * m);
191  double beta = p / E;
192 
193  double pathcorrection = 1.; // Trick the MultipleScatteringUpdator interface
194 
195  double energyLoss = 0;
196  double energyLossSigma = 0;
197 
198  if (meff.energyLoss() != nullptr) {
199  energyLoss = meff.energyLoss()->deltaE();
200  energyLossSigma = meff.energyLoss()->sigmaDeltaE();
201  }
202 
203  // update for mean energy loss
204  double newP = p;
205  double sigmaQoverP = 0;
206  double sigmaQoverPSq = 0;
207  // Landaus mpvs don't just add, if in Landau mode we need to do a different update
208  if (m_landauMode && cache.accumulatedElossSigma != 0 && energyLossSigma != 0) {
209  if (energyLoss > 0) {
210  energyLoss += energyLossSigma * std::log(1 + cache.accumulatedElossSigma / (energyLossSigma)) +
211  cache.accumulatedElossSigma * std::log(1 + energyLossSigma / cache.accumulatedElossSigma);
212  } else {
213  energyLoss -= energyLossSigma * std::log(1 + cache.accumulatedElossSigma / energyLossSigma) +
214  cache.accumulatedElossSigma * std::log(1 + energyLossSigma / cache.accumulatedElossSigma);
215  }
216  cache.accumulatedElossSigma += energyLossSigma;
217  } else if (m_landauMode) {
218  cache.accumulatedElossSigma += energyLossSigma;
219  }
220  double qOverPnew = parm->parameters()[Trk::qOverP];
221 
222  if (p > m_momentumCut && p < m_momentumMax && m_doEloss) {
223  double newP2 = (E + energyLoss) * (E + energyLoss) - m * m;
224  if (newP2 < m_momentumCut * m_momentumCut) {
225  return nullptr; // protect FPE
226  }
227  if (E + energyLoss < -m) {
228  return nullptr; // protect against flip in correction
229  }
230  newP = std::sqrt(newP2);
231  sigmaQoverP = energyLossSigma / (beta * p * p);
232  sigmaQoverPSq = sigmaQoverP * sigmaQoverP;
233  qOverPnew = parm->charge() / newP;
234  }
235  Trk::DefinedParameter qOverPmod(qOverPnew, Trk::qOverP);
236 
237  // check if Parameters are measured parameters
238  // the updatedParameters - first a copy
239  const Trk::TrackParameters* mpars = parm;
240  AmgVector(5) updatedParameters(mpars->parameters());
241  std::optional<AmgSymMatrix(5)> updatedCovariance = std::nullopt;
242  // initialize ErrorMatrix pointer
244  // the new CovarianceMatrix - a copy first
245  updatedCovariance = mpars->covariance()
246  ? std::optional<AmgSymMatrix(5)>(*mpars->covariance())
247  : std::nullopt;
248  double angularVariation = 0;
249  double sigmaDeltaPhiSq = 0;
250  double sigmaDeltaThetaSq = 0;
251 
252  if (m_doMs) {
253  // If the meff has scattering angles use those, otherwise use MEffUpdator
254  if (meff.scatteringAngles() == nullptr) {
255  // Trick to keep using existing MultipleScatteringUpdator interface
256  // Here we know the path length to be meff.thicknessX0, so we set pathcorrection = 1
257  // and create a dummy materialProperties with the properties we are interested in
258  MaterialProperties mprop(meff.thicknessInX0(), 1., 1., 0., 0., 0.);
259  angularVariation = m_msUpdator->sigmaSquare(mprop, updateMomentum, pathcorrection, Trk::muon);
260  // sigmaDeltaPhiSq = angularVariation/(parm->sinTheta()*parm->sinTheta());
261  sigmaDeltaPhiSq =
262  angularVariation / (std::sin(parm->parameters()[Trk::theta]) * std::sin(parm->parameters()[Trk::theta]));
263  sigmaDeltaThetaSq = angularVariation;
264  } else {
265  // material update from mefots -> D.L.
266  sigmaDeltaPhiSq = meff.scatteringAngles()->sigmaDeltaPhi();
267  sigmaDeltaPhiSq *= sigmaDeltaPhiSq;
268  sigmaDeltaThetaSq = meff.scatteringAngles()->sigmaDeltaTheta();
269  sigmaDeltaThetaSq *= sigmaDeltaThetaSq;
270  updatedParameters[Trk::phi] = parm->position().phi() + meff.scatteringAngles()->deltaPhi();
271  updatedParameters[Trk::theta] = parm->position().theta() + meff.scatteringAngles()->deltaTheta();
272  }
273  }
274  // update the covariance entries - angular variation in phi has dependency on theta direction
275  if (updatedCovariance) {
276  // sign of the noise adding -----------------------
277  int sign = int(matupmode);
278  // check for non-zero covariance matrix
279  COVARIANCEUPDATEWITHCHECK((*updatedCovariance)(Trk::phi, Trk::phi), sign, sigmaDeltaPhiSq);
280  COVARIANCEUPDATEWITHCHECK((*updatedCovariance)(Trk::theta, Trk::theta), sign, sigmaDeltaThetaSq);
282  COVARIANCEUPDATEWITHCHECK((*updatedCovariance)(Trk::qOverP, Trk::qOverP), sign, sigmaQoverPSq);
283  } else if (m_xKalmanStraggling) { /* to be filled in*/
284  } else if (m_landauMode) {
285  // subtract what we added up till now and add what we should add up till now
286  // Landau's 68% limit is approx 1.6*sigmaParameter
287 
288  /* Get the TLS to a local here once and use it for calculation*/
289  (*updatedCovariance)(Trk::qOverP, Trk::qOverP) -=
290  sign * std::pow(1.6 * (cache.accumulatedElossSigma - p * p * sigmaQoverP) / (p * p), 2);
291  (*updatedCovariance)(Trk::qOverP, Trk::qOverP) +=
292  sign * std::pow(1.6 * cache.accumulatedElossSigma / (newP * newP), 2);
293  }
294  // the checks for the remove Noise mode -----------------------------------------------------
295  if (matupmode == Trk::removeNoise && !checkCovariance(*updatedCovariance)) {
296  // the covariance is invalid
297  return nullptr;
298  }
299 
300  // create the ErrorMatrix
301  // updatedError = new Trk::ErrorMatrix(updatedCovariance);
302  // -------------------------------------- screen output --------------------------------------
304  double sigmaAngle = std::sqrt(angularVariation);
305  ATH_MSG_VERBOSE(" sigma(phi) / sigma(theta) = " << sigmaAngle / std::sin(parm->parameters()[Trk::theta]) << " / "
306  << sigmaAngle);
307  ATH_MSG_VERBOSE(" deltaP / sigmaQoverP = " << energyLoss << " / " << sigmaQoverP);
308  }
309  // -------------------------------------------------------------------------------------------
310  }
311  // ----------------------------------------- validation section ----------------------------------
312  // validation if configured
313  if (m_validationMode) {
314  if (cache.validationLayer) {
315  // all you have from MaterialProperties
316  double pathInX0 = meff.thicknessInX0();
317 
318  Trk::AssociatedMaterial assMatHit(parm->position(),
319  pathInX0,
320  pathInX0,
321  0,
322  0,
323  0,
324  0,
325  pathcorrection,
326  cache.validationLayer->enclosingTrackingVolume(),
327  cache.validationLayer);
328 
329  // record the Material hit ----------------------------------------------------------------
330  m_materialMapper->recordMaterialHit(assMatHit, parm->position());
331 
332  // the steps
333  cache.validationSteps++;
334  cache.validationPhi += parm->position().phi();
335  cache.validationEta += parm->position().eta();
336  // reset the validation layer
337  cache.validationLayer = nullptr;
338  }
339  }
340  // ----------------------------------------- validation section ----------------------------------
341  }
342  updatedParameters[Trk::qOverP] = qOverPnew;
343  return parm->associatedSurface().createUniqueTrackParameters(
344  updatedParameters[Trk::loc1],
345  updatedParameters[Trk::loc2],
346  updatedParameters[Trk::phi],
347  updatedParameters[Trk::theta],
348  updatedParameters[Trk::qOverP],
349  updatedCovariance
350  );
351 }

◆ updateImpl() [4/4]

std::unique_ptr< Trk::TrackParameters > Trk::MaterialEffectsUpdator::updateImpl ( ICache cache,
const TrackParameters parm,
const MaterialProperties mprop,
double  pathcorrection,
PropDirection  dir = alongMomentum,
ParticleHypothesis  particle = pion,
MaterialUpdateMode  matupmode = addNoise 
) const
private

Definition at line 464 of file MaterialEffectsUpdator.cxx.

472  {
473  // no material properties - pass them back
475  return parm->uniqueClone();
476  }
477 
478  // get the kinematics
479  double p = parm->momentum().mag();
480  double updateMomentum = (m_forceMomentum) ? m_forcedMomentum : p;
482  double E = std::sqrt(p * p + m * m);
483  double beta = p / E;
484 
485  // set the output if restricted to the validation direction
486  bool outputFlag = m_msgOutputValidationDirection ? dir == int(m_validationDirection) : true;
487 
488  // no material update below/above a certain cut value
489  if (p > m_momentumCut && p < m_momentumMax) {
490  // get the delta of the Energy
491  EnergyLoss energyLoss =
492  (m_doEloss) ? m_eLossUpdator->energyLoss(matprop, updateMomentum,
493  pathcorrection, dir, particle,
495  : EnergyLoss{};
496  // update for mean energy loss
497  double deltaE = energyLoss.deltaE();
498  double sigmaDeltaE = energyLoss.sigmaDeltaE();
499 
500  if (m_landauMode && cache.accumulatedElossSigma != 0 && sigmaDeltaE != 0) {
501  if (dir == Trk::oppositeMomentum) {
502  deltaE += sigmaDeltaE * std::log(1 + cache.accumulatedElossSigma / sigmaDeltaE) +
503  cache.accumulatedElossSigma * std::log(1 + sigmaDeltaE / cache.accumulatedElossSigma);
504  } else {
505  deltaE -= sigmaDeltaE * std::log(1 + cache.accumulatedElossSigma / sigmaDeltaE) +
506  cache.accumulatedElossSigma * std::log(1 + sigmaDeltaE / cache.accumulatedElossSigma);
507  }
508  cache.accumulatedElossSigma += sigmaDeltaE;
509  } else if (m_landauMode) {
510  cache.accumulatedElossSigma += sigmaDeltaE;
511  }
512 
513  double newP2 = (E + deltaE) * (E + deltaE) - m * m;
514  if (E + deltaE < -m) {
515  return nullptr; // protect against flip in correction
516  }
517  if (newP2 < m_momentumCut * m_momentumCut) {
518  return nullptr; // protect against FPE
519  }
520  double deltaP = std::sqrt(newP2) - p;
521  double sigmaQoverP = sigmaDeltaE / std::pow(beta * p, 2);
522 
523  Trk::DefinedParameter qOverPmod(parm->charge() / (p + deltaP), Trk::qOverP);
524 
525  // check if Parameters are measured parameters
526  const Trk::TrackParameters* mpars = parm;
527  AmgVector(5) updatedParameters(mpars->parameters());
528  // initialize ErrorMatrix pointer
529  std::optional<AmgSymMatrix(5)> updatedCovariance = std::nullopt;
530  {
531  // the new CovarianceMatrix - a copy first
532  updatedCovariance =
533  mpars->covariance()
534  ? std::optional<AmgSymMatrix(5)>(*mpars->covariance())
535  : std::nullopt;
536  // only update if msUpdator exists
537  double angularVariation =
538  (m_doMs) ? m_msUpdator->sigmaSquare(matprop, updateMomentum, pathcorrection, particle) : 0.;
539  // update the covariance entries - angular variation in phi has dependency on theta direction
540  if (updatedCovariance) {
541  // sign of the noise adding ----------------------------------------------------------------
542  int sign = int(matupmode);
543 
544  double sigmaDeltaPhiSq =
545  angularVariation / (std::sin(parm->parameters()[Trk::theta]) * std::sin(parm->parameters()[Trk::theta]));
546  double sigmaDeltaThetaSq = angularVariation;
547  // checks will only be done in the removeNoise mode
548  COVARIANCEUPDATEWITHCHECK((*updatedCovariance)(Trk::phi, Trk::phi), sign, sigmaDeltaPhiSq);
549  COVARIANCEUPDATEWITHCHECK((*updatedCovariance)(Trk::theta, Trk::theta), sign, sigmaDeltaThetaSq);
551  COVARIANCEUPDATEWITHCHECK((*updatedCovariance)(Trk::qOverP, Trk::qOverP), sign, sigmaQoverP * sigmaQoverP);
552  } else if (m_xKalmanStraggling) {
553  double q = parm->charge();
555  (*updatedCovariance)(Trk::qOverP, Trk::qOverP), sign, 0.2 * deltaP * deltaP * q * q * q * q);
556  } else if (m_landauMode) {
557  // subtract what we added up till now and add what we should add up till now
558  // Landau's 68% limit is approx 1.6*sigmaParameter
559  (*updatedCovariance)(Trk::qOverP, Trk::qOverP) -=
560  sign * std::pow(1.6 * (cache.accumulatedElossSigma - p * p * sigmaQoverP) / (p * p), 2);
561  (*updatedCovariance)(Trk::qOverP, Trk::qOverP) +=
562  sign * std::pow(1.6 * cache.accumulatedElossSigma / ((p + deltaP) * (p + deltaP)), 2);
563  }
564  // the checks for the remove Noise mode -----------------------------------------------------
565  if (matupmode == Trk::removeNoise && !checkCovariance(*updatedCovariance)) {
566  // the covariance is invalid
567  return nullptr;
568  }
569 
570  // create the ErrorMatrix
571 
572  // -------------------------------------- screen output --------------------------------------
573  if (outputFlag && m_msgOutputCorrections) {
574  double sigmaAngle = std::sqrt(angularVariation);
575  ATH_MSG_VERBOSE(" sigma(phi) / sigma(theta) = " << sigmaAngle / std::sin(parm->parameters()[Trk::theta])
576  << " / " << sigmaAngle);
577  ATH_MSG_VERBOSE(" deltaP / sigmaQoverP = " << deltaP << " / " << sigmaQoverP);
578  }
579  // -------------------------------------------------------------------------------------------
580  }
581  // ----------------------------------------- validation section ----------------------------------
582  // validation if configured
583  if (m_validationMode && dir == Trk::PropDirection(m_validationDirection) && updatedCovariance) {
584 
585  if (cache.validationLayer) {
586  // all you have from MaterialProperties
587  double pathInX0 = pathcorrection * matprop.thicknessInX0();
588  double A = 0.;
589  double Z = 0.;
590  double rho = 0.;
591  double l0 = 0.;
592  // or better take the extended version for more information
593  const Trk::MaterialProperties* extProperties = dynamic_cast<const Trk::MaterialProperties*>(&matprop);
594 
595  if (extProperties) {
596  A = extProperties->averageA();
597  Z = extProperties->averageZ();
598  rho = extProperties->averageRho();
599  l0 = extProperties->l0();
600  }
601 
602  Trk::AssociatedMaterial assMatHit(parm->position(),
603  pathInX0,
604  matprop.x0(),
605  l0,
606  A,
607  Z,
608  rho,
609  pathcorrection,
610  cache.validationLayer->enclosingTrackingVolume(),
611  cache.validationLayer);
612 
613  // record the Material hit ----------------------------------------------------------------
614  m_materialMapper->recordMaterialHit(assMatHit, parm->position());
615  // the steps
616  cache.validationSteps++;
617  cache.validationPhi += parm->position().phi();
618  cache.validationEta += parm->position().eta();
619  // reset the cache.tion layer
620  cache.validationLayer = nullptr;
621  }
622  }
623  // ----------------------------------------- validation section ----------------------------------
624  }
625  updatedParameters[Trk::qOverP] = parm->charge() / (p + deltaP);
626  return parm->associatedSurface().createUniqueTrackParameters(
627  updatedParameters[Trk::loc1],
628  updatedParameters[Trk::loc2],
629  updatedParameters[Trk::phi],
630  updatedParameters[Trk::theta],
631  updatedParameters[Trk::qOverP],
632  std::move(updatedCovariance)
633  );
634  }
635  //default if we have not returned just above
636  return parm->uniqueClone();
637 }

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

◆ validationAction() [1/2]

virtual void Trk::MaterialEffectsUpdator::validationAction ( ) const
inlinefinaloverridevirtual

Validation Action: outside access to internal validation steps Optional.

Implements Trk::IMaterialEffectsUpdator.

Definition at line 237 of file MaterialEffectsUpdator.h.

238  {
239  ICache& cache = getTLSCache();
240  validationActionImpl(cache);
241  }

◆ validationAction() [2/2]

virtual void Trk::MaterialEffectsUpdator::validationAction ( ICache cache) const
inlinefinaloverridevirtual

Validation Action - calls the writing and resetting of the TTree variables.

Implements Trk::IMaterialEffectsUpdator.

Definition at line 161 of file MaterialEffectsUpdator.h.

162  {
163  validationActionImpl(cache);
164  }

◆ validationActionImpl()

void Trk::MaterialEffectsUpdator::validationActionImpl ( ICache cache)
staticprivate

Definition at line 806 of file MaterialEffectsUpdator.cxx.

807 {
808  cache.validationEta = 0.;
809  cache.validationPhi = 0.;
810  cache.validationSteps = 0;
811 }

Member Data Documentation

◆ m_cache_tls

boost::thread_specific_ptr<ICache> Trk::MaterialEffectsUpdator::m_cache_tls
mutableprivate

Definition at line 346 of file MaterialEffectsUpdator.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_doCompoundLayerCheck

bool Trk::MaterialEffectsUpdator::m_doCompoundLayerCheck
private

turn on/off the necessary checks when we may have compound layers

Definition at line 313 of file MaterialEffectsUpdator.h.

◆ m_doEloss

bool Trk::MaterialEffectsUpdator::m_doEloss
private

steer energy loss On/Off from outside

Definition at line 315 of file MaterialEffectsUpdator.h.

◆ m_doMs

bool Trk::MaterialEffectsUpdator::m_doMs
private

steer multiple scattering On/Off from outside

Definition at line 316 of file MaterialEffectsUpdator.h.

◆ m_eLossUpdator

ToolHandle<IEnergyLossUpdator> Trk::MaterialEffectsUpdator::m_eLossUpdator
private

AlgoTool for EnergyLoss updates.

Definition at line 339 of file MaterialEffectsUpdator.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_forcedMomentum

double Trk::MaterialEffectsUpdator::m_forcedMomentum
private

Forced momentum value.

Definition at line 337 of file MaterialEffectsUpdator.h.

◆ m_forceMomentum

bool Trk::MaterialEffectsUpdator::m_forceMomentum
private

Force the momentum to be a specific value.

Definition at line 318 of file MaterialEffectsUpdator.h.

◆ m_landauMode

bool Trk::MaterialEffectsUpdator::m_landauMode
private

If in Landau mode, error propagation is done as for landaus.

Definition at line 331 of file MaterialEffectsUpdator.h.

◆ m_materialMapper

ToolHandle<IMaterialMapper> Trk::MaterialEffectsUpdator::m_materialMapper
private

the material mapper for recording the layer material

Definition at line 341 of file MaterialEffectsUpdator.h.

◆ m_momentumCut

double Trk::MaterialEffectsUpdator::m_momentumCut
private

Minimal momentum cut for update.

Definition at line 335 of file MaterialEffectsUpdator.h.

◆ m_momentumMax

double Trk::MaterialEffectsUpdator::m_momentumMax
private

Maximal momentum cut for update.

Definition at line 336 of file MaterialEffectsUpdator.h.

◆ m_msgOutputCorrections

bool Trk::MaterialEffectsUpdator::m_msgOutputCorrections
private

screen output of actual corrections

Definition at line 324 of file MaterialEffectsUpdator.h.

◆ m_msgOutputValidationDirection

bool Trk::MaterialEffectsUpdator::m_msgOutputValidationDirection
private

validation direction used for screen output

Definition at line 322 of file MaterialEffectsUpdator.h.

◆ m_msUpdator

ToolHandle<IMultipleScatteringUpdator> Trk::MaterialEffectsUpdator::m_msUpdator
private

AlgoTool for MultipleScatterin effects.

Definition at line 340 of file MaterialEffectsUpdator.h.

◆ m_useMostProbableEloss

bool Trk::MaterialEffectsUpdator::m_useMostProbableEloss
private

use the most probable energy loss

Definition at line 320 of file MaterialEffectsUpdator.h.

◆ m_validationDirection

int Trk::MaterialEffectsUpdator::m_validationDirection
private

validation direction

Definition at line 333 of file MaterialEffectsUpdator.h.

◆ m_validationIgnoreUnmeasured

bool Trk::MaterialEffectsUpdator::m_validationIgnoreUnmeasured
private

Ignore unmeasured TrackParameters (Navigation!)

Definition at line 329 of file MaterialEffectsUpdator.h.

◆ m_validationMode

bool Trk::MaterialEffectsUpdator::m_validationMode
private

Switch for validation mode.

Definition at line 328 of file MaterialEffectsUpdator.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.

◆ m_xKalmanStraggling

bool Trk::MaterialEffectsUpdator::m_xKalmanStraggling
private

the momentum Error as calculated in xKalman

Definition at line 319 of file MaterialEffectsUpdator.h.


The documentation for this class was generated from the following files:
COVARIANCEUPDATEWITHCHECK
#define COVARIANCEUPDATEWITHCHECK(cov, sign, value)
Definition: MaterialEffectsUpdator.h:28
test_pyathena.eta
eta
Definition: test_pyathena.py:10
Trk::MaterialEffectsUpdator::m_momentumCut
double m_momentumCut
Minimal momentum cut for update.
Definition: MaterialEffectsUpdator.h:335
Trk::MaterialEffectsUpdator::m_useMostProbableEloss
bool m_useMostProbableEloss
use the most probable energy loss
Definition: MaterialEffectsUpdator.h:320
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
Trk::ParticleSwitcher::particle
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
Definition: ParticleHypothesis.h:76
Trk::MaterialEffectsUpdator::modelActionImpl
static void modelActionImpl(ICache &cache, const TrackParameters *parm=nullptr)
Definition: MaterialEffectsUpdator.cxx:814
Trk::MaterialProperties::averageA
float averageA() const
Return the average A of the material [gram/mole].
python.SystemOfUnits.m
int m
Definition: SystemOfUnits.py:91
Trk::MaterialEffectsUpdator::m_validationMode
bool m_validationMode
Switch for validation mode.
Definition: MaterialEffectsUpdator.h:328
Trk::MaterialEffectsUpdator::m_validationIgnoreUnmeasured
bool m_validationIgnoreUnmeasured
Ignore unmeasured TrackParameters (Navigation!)
Definition: MaterialEffectsUpdator.h:329
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
Trk::MaterialEffectsUpdator::m_msgOutputValidationDirection
bool m_msgOutputValidationDirection
validation direction used for screen output
Definition: MaterialEffectsUpdator.h:322
Trk::oppositeMomentum
@ oppositeMomentum
Definition: PropDirection.h:21
AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
Monitored::Z
@ Z
Definition: HistogramFillerUtils.h:24
conifer::pow
constexpr int pow(int x)
Definition: conifer.h:20
python.SystemOfUnits.MeV
int MeV
Definition: SystemOfUnits.py:154
Trk::MaterialEffectsUpdator::m_eLossUpdator
ToolHandle< IEnergyLossUpdator > m_eLossUpdator
AlgoTool for EnergyLoss updates.
Definition: MaterialEffectsUpdator.h:339
Trk::MaterialEffectsUpdator::m_xKalmanStraggling
bool m_xKalmanStraggling
the momentum Error as calculated in xKalman
Definition: MaterialEffectsUpdator.h:319
Trk::MaterialProperties::thicknessInX0
float thicknessInX0() const
Return the radiationlength fraction.
Trk::MaterialEffectsUpdator::getTLSCache
ICache & getTLSCache() const
Definition: MaterialEffectsUpdator.h:347
Trk::MaterialEffectsUpdator::m_materialMapper
ToolHandle< IMaterialMapper > m_materialMapper
the material mapper for recording the layer material
Definition: MaterialEffectsUpdator.h:341
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
Trk::MaterialEffectsUpdator::m_validationDirection
int m_validationDirection
validation direction
Definition: MaterialEffectsUpdator.h:333
Trk::MaterialProperties::averageRho
float averageRho() const
Return the average density of the material.
Trk::loc2
@ loc2
generic first and second local coordinate
Definition: ParamDefs.h:35
python.SystemOfUnits.TeV
int TeV
Definition: SystemOfUnits.py:158
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
Trk::DefinedParameter
std::pair< double, ParamDefs > DefinedParameter
Definition: DefinedParameter.h:27
Trk::MaterialEffectsUpdator::m_doEloss
bool m_doEloss
steer energy loss On/Off from outside
Definition: MaterialEffectsUpdator.h:315
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:27
Trk::AmgSymMatrix
AmgSymMatrix(5) &GXFTrackState
Definition: GXFTrackState.h:156
Trk::PropDirection
PropDirection
Definition: PropDirection.h:19
A
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
Trk::MaterialEffectsUpdator::m_doCompoundLayerCheck
bool m_doCompoundLayerCheck
turn on/off the necessary checks when we may have compound layers
Definition: MaterialEffectsUpdator.h:313
beamspotman.n
n
Definition: beamspotman.py:731
Trk::theta
@ theta
Definition: ParamDefs.h:66
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
Trk::MaterialEffectsUpdator::m_cache_tls
boost::thread_specific_ptr< ICache > m_cache_tls
Definition: MaterialEffectsUpdator.h:346
AmgVector
AmgVector(4) T2BSTrackFilterTool
Definition: T2BSTrackFilterTool.cxx:114
Trk::geantino
@ geantino
Definition: ParticleHypothesis.h:26
Trk::MaterialEffectsUpdator::m_forcedMomentum
double m_forcedMomentum
Forced momentum value.
Definition: MaterialEffectsUpdator.h:337
sign
int sign(int a)
Definition: TRT_StrawNeighbourSvc.h:107
Trk::MaterialEffectsUpdator::m_momentumMax
double m_momentumMax
Maximal momentum cut for update.
Definition: MaterialEffectsUpdator.h:336
Trk::MaterialEffectsUpdator::updateImpl
std::unique_ptr< TrackParameters > updateImpl(ICache &cache, const TrackParameters *parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const
Definition: MaterialEffectsUpdator.cxx:140
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
Trk::ParametersBase
Definition: ParametersBase.h:55
Trk::muon
@ muon
Definition: ParticleHypothesis.h:28
Trk::MaterialEffectsUpdator::m_landauMode
bool m_landauMode
If in Landau mode, error propagation is done as for landaus.
Definition: MaterialEffectsUpdator.h:331
Trk::MaterialEffectsUpdator::m_msUpdator
ToolHandle< IMultipleScatteringUpdator > m_msUpdator
AlgoTool for MultipleScatterin effects.
Definition: MaterialEffectsUpdator.h:340
AthAlgTool::AthAlgTool
AthAlgTool()
Default constructor:
beamspotman.dir
string dir
Definition: beamspotman.py:623
Trk::AssociatedMaterial
Definition: AssociatedMaterial.h:33
Trk::MaterialEffectsUpdator::validationActionImpl
static void validationActionImpl(ICache &cache)
Definition: MaterialEffectsUpdator.cxx:806
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
Trk::ParticleMasses::mass
constexpr double mass[PARTICLEHYPOTHESES]
the array of masses
Definition: ParticleHypothesis.h:53
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
VP1PartSpect::E
@ E
Definition: VP1PartSpectFlags.h:21
Trk::MaterialEffectsUpdator::checkCovariance
bool checkCovariance(AmgSymMatrix(5) &updated) const
A simple check method for the 'removeNoise' update model.
Definition: MaterialEffectsUpdator.cxx:819
Trk::MaterialProperties
Definition: MaterialProperties.h:40
a
TList * a
Definition: liststreamerinfos.cxx:10
Trk::MaterialEffectsUpdator::m_msgOutputCorrections
bool m_msgOutputCorrections
screen output of actual corrections
Definition: MaterialEffectsUpdator.h:324
Trk::MaterialEffectsUpdator::m_doMs
bool m_doMs
steer multiple scattering On/Off from outside
Definition: MaterialEffectsUpdator.h:316
h
mapkey::sf
@ sf
Definition: TElectronEfficiencyCorrectionTool.cxx:38
Trk::MaterialEffectsUpdator::m_forceMomentum
bool m_forceMomentum
Force the momentum to be a specific value.
Definition: MaterialEffectsUpdator.h:318
Trk::MaterialProperties::averageZ
float averageZ() const
Returns the average Z of the material.
Trk::qOverP
@ qOverP
perigee
Definition: ParamDefs.h:67
python.CaloCondTools.log
log
Definition: CaloCondTools.py:20
if
if(febId1==febId2)
Definition: LArRodBlockPhysicsV0.cxx:567
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
ReadCellNoiseFromCoolCompare.l0
l0
Definition: ReadCellNoiseFromCoolCompare.py:359
extractSporadic.q
list q
Definition: extractSporadic.py:98
physics_parameters.parameters
parameters
Definition: physics_parameters.py:144
Trk::phi
@ phi
Definition: ParamDefs.h:75
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
Trk::nonInteractingMuon
@ nonInteractingMuon
Definition: ParticleHypothesis.h:36
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
MuonParameters::beta
@ beta
Definition: MuonParamDefs.h:144
Trk::loc1
@ loc1
Definition: ParamDefs.h:34
Trk::removeNoise
@ removeNoise
Definition: MaterialUpdateMode.h:20
Trk::MaterialProperties::l0
float l0() const
Return the nuclear interaction length.
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
Trk::MaterialEffectsUpdator::postUpdateImpl
std::unique_ptr< TrackParameters > postUpdateImpl(ICache &cache, const TrackParameters &parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const
Definition: MaterialEffectsUpdator.cxx:408
fitman.rho
rho
Definition: fitman.py:532
fitman.k
k
Definition: fitman.py:528
Trk::MaterialEffectsUpdator::ICache
IMaterialEffectsUpdator::ICache ICache
Definition: MaterialEffectsUpdator.h:89
Trk::MaterialEffectsUpdator::preUpdateImpl
std::unique_ptr< TrackParameters > preUpdateImpl(ICache &cache, const TrackParameters *parm, const Layer &sf, PropDirection dir=alongMomentum, ParticleHypothesis particle=pion, MaterialUpdateMode matupmode=addNoise) const
Definition: MaterialEffectsUpdator.cxx:354