ATLAS Offline Software
AlignTSOS.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef TRKALIGNEVENT_ALIGNTSOS_H
6 #define TRKALIGNEVENT_ALIGNTSOS_H
7 
10 #include "Identifier/Identifier.h"
11 #include "TrkAlignEvent/Residual.h"
12 
13 #include <vector>
14 
26 namespace CLHEP {
27  class HepVector;
28 }
29 
30 namespace Trk {
31 
33  class RIO_OnTrack;
34  class AlignModule;
35  class TrkDetElementBase;
36 
37  class AlignTSOS : public TrackStateOnSurface {
38 
39  public:
40 
49  const RIO_OnTrack * rio,
51 
53  const CompetingRIOsOnTrack * crio,
55 
56  AlignTSOS(const TrackStateOnSurface& tsos,
58 
60  AlignTSOS(const AlignTSOS& atsos);
61 
63  virtual ~AlignTSOS();
64 
66  AlignTSOS& operator=(const AlignTSOS& atsos);
67 
69  const AlignModule* module() const { return m_module; }
70  AlignModule* module() { return m_module; }
71 
73  void setValid(bool isvalid) { m_isvalid=isvalid; }
74  bool isValid() const { return m_isvalid; }
75 
77  int nResDim() const { return m_residuals.size(); }
78 
81 
83  Identifier identify() const;
84 
86  const RIO_OnTrack* rio() const;
87 
90 
92  const CompetingRIOsOnTrack* crio() const { return m_crio; }
93 
95  void addResidual(const Residual& residual) { m_residuals.push_back(residual); }
96 
98  const std::vector<Residual>& residuals() const { return m_residuals; }
99 
101  void clearResiduals() { m_residuals.clear(); }
102 
104  std::vector<Residual>::const_iterator firstResidual() const { return m_residuals.begin(); }
105 
107  std::vector<Residual>::const_iterator lastResidual() const { return m_residuals.end(); }
108 
110  const TrkDetElementBase* detelement(int i=0) const { return m_detelements[i]; }
111 
113  int nDetElements() const { return m_detelements.size(); }
114 
116  std::string dumpMeasType() const;
117 
119  void setAlphaStrip(double alpha) { m_alphaStrip = alpha; }
120 
122  double alphaStrip() const { return m_alphaStrip; }
123 
126 
128  Trk::ParamDefs measDir() const { return m_measDir; }
129 
131  std::string dumpMeasDir() const;
132 
135 
137  void setUnbiasedTrackPars(const TrackParameters * trkPars) { m_unbiasedTrackPars = trkPars; }
138 
140  const std::vector<Amg::VectorX> * derivatives() const { return m_derivatives; }
141 
143  const std::vector<Amg::VectorX> * derivativesVtx() const { return m_derivativesVtx; }
144 
146  void setDerivatives(std::vector<Amg::VectorX> * derivs) { m_derivatives = derivs; }
147 
149  void setDerivativesVtx(std::vector<Amg::VectorX> * derivs) { m_derivativesVtx = derivs; }
150 
151  virtual TrackStateOnSurface::Variety variety() const override final {
153  }
154  private:
155  // private methods
156  AlignTSOS(); // don't use this one
157 
158  // private variables
160  const RIO_OnTrack * m_rio;
162 
164 
165  std::vector<Residual> m_residuals;
166 
167  std::vector<const TrkDetElementBase *> m_detelements;
168 
169  std::vector<Amg::VectorX> * m_derivatives;
170 
171  bool m_isvalid;
172 
174 
176 
177  double m_alphaStrip;
178 
179  std::vector<Amg::VectorX> * m_derivativesVtx;
180 
181  }; // end class
182 
184  MsgStream& operator << ( MsgStream& sl, const AlignTSOS& atsos);
185 
186 } // end namespace
187 
188 #endif // TRKALIGNEVENT_ALIGNTSOS_H
Trk::AlignTSOS::clearResiduals
void clearResiduals()
clears vector of residuals
Definition: AlignTSOS.h:101
Trk::AlignTSOS::setCompetingRIOsOnTrack
void setCompetingRIOsOnTrack(const CompetingRIOsOnTrack *crio)
sets CompetingRIOsOnTrack
Definition: AlignTSOS.h:89
Trk::AlignTSOS::setUnbiasedTrackPars
void setUnbiasedTrackPars(const TrackParameters *trkPars)
setter for unbiased track parameters
Definition: AlignTSOS.h:137
Trk::AlignTSOS::measType
TrackState::MeasurementType measType() const
returns measurement type enum
Definition: AlignTSOS.h:80
Trk::AlignTSOS::m_residuals
std::vector< Residual > m_residuals
Definition: AlignTSOS.h:165
Trk::AlignTSOS::setMeasDir
void setMeasDir(Trk::ParamDefs dir)
set the measurement direction
Definition: AlignTSOS.h:125
Trk::AlignTSOS::rio
const RIO_OnTrack * rio() const
returns RIO_OnTrack or leading RIO of CompetingRIOsOnTrack (assigned by c'tor)
Definition: AlignTSOS.cxx:157
Trk::AlignTSOS::m_derivatives
std::vector< Amg::VectorX > * m_derivatives
Definition: AlignTSOS.h:169
Trk::AlignTSOS::isValid
bool isValid() const
Definition: AlignTSOS.h:74
ClusterSeg::residual
@ residual
Definition: ClusterNtuple.h:20
Trk::AlignTSOS::residuals
const std::vector< Residual > & residuals() const
returns vector of Residuals
Definition: AlignTSOS.h:98
TrackStateDefs.h
Trk::ParamDefs
ParamDefs
Definition: ParamDefs.h:32
Trk::AlignTSOS
Definition: AlignTSOS.h:37
Trk::AlignModule
Definition: AlignModule.h:45
Trk::AlignTSOS::variety
virtual TrackStateOnSurface::Variety variety() const override final
Use this method to find if this is a Single, Multi or Align TrackStateOnsurface.
Definition: AlignTSOS.h:151
Trk::RIO_OnTrack
Definition: RIO_OnTrack.h:70
Trk::TrkDetElementBase
Definition: TrkDetElementBase.h:52
Trk::AlignTSOS::m_isvalid
bool m_isvalid
Definition: AlignTSOS.h:171
Trk::AlignTSOS::measDir
Trk::ParamDefs measDir() const
retrieve the measurement direction
Definition: AlignTSOS.h:128
const
bool const RAWDATA *ch2 const
Definition: LArRodBlockPhysicsV0.cxx:560
Trk::AlignTSOS::AlignTSOS
AlignTSOS()
Trk::AlignTSOS::m_alphaStrip
double m_alphaStrip
Definition: AlignTSOS.h:177
Trk::AlignTSOS::derivatives
const std::vector< Amg::VectorX > * derivatives() const
returns pointer to vector of derivatives
Definition: AlignTSOS.h:140
Trk::AlignTSOS::m_measDir
Trk::ParamDefs m_measDir
direction of measurement (set to Trk::x by default)
Definition: AlignTSOS.h:175
Trk::AlignTSOS::module
const AlignModule * module() const
accessor method for AlignModule to which tsos belongs
Definition: AlignTSOS.h:69
Trk::AlignTSOS::m_detelements
std::vector< const TrkDetElementBase * > m_detelements
Definition: AlignTSOS.h:167
AlignModule
AlignModule is a grouping of TrkDetElementBase objects, grouped according to the type of alignment,...
Trk::AlignTSOS::m_derivativesVtx
std::vector< Amg::VectorX > * m_derivativesVtx
Definition: AlignTSOS.h:179
Trk::AlignTSOS::dumpMeasType
std::string dumpMeasType() const
returns string corresponding to the measurement type
Definition: AlignTSOS.cxx:194
Trk::AlignTSOS::dumpMeasDir
std::string dumpMeasDir() const
returns string corresponding to the measurement direction
Definition: AlignTSOS.cxx:214
Trk::AlignTSOS::m_module
AlignModule * m_module
Definition: AlignTSOS.h:159
Trk::AlignTSOS::nDetElements
int nDetElements() const
method for retrieving number of detector elements
Definition: AlignTSOS.h:113
Trk::AlignTSOS::setDerivativesVtx
void setDerivativesVtx(std::vector< Amg::VectorX > *derivs)
setter for the derivatives w.r.t.
Definition: AlignTSOS.h:149
lumiFormat.i
int i
Definition: lumiFormat.py:85
Trk::MeasurementBaseType::CompetingRIOsOnTrack
@ CompetingRIOsOnTrack
Definition: MeasurementBase.h:50
Trk::AlignTSOS::operator=
AlignTSOS & operator=(const AlignTSOS &atsos)
asignment operator
Definition: AlignTSOS.cxx:111
Trk::AlignTSOS::derivativesVtx
const std::vector< Amg::VectorX > * derivativesVtx() const
returns pointer to vector of derivatives w.r.t.
Definition: AlignTSOS.h:143
Trk::AlignTSOS::lastResidual
std::vector< Residual >::const_iterator lastResidual() const
returns last Residual iterator
Definition: AlignTSOS.h:107
CLHEP
STD'S.
Definition: IAtRndmGenSvc.h:19
Trk::CompetingRIOsOnTrack
Base class for all CompetingRIOsOnTack implementations, extends the common MeasurementBase.
Definition: CompetingRIOsOnTrack.h:64
Trk::TrackState::MeasurementType
MeasurementType
enum describing the flavour of MeasurementBase
Definition: TrackStateDefs.h:26
Trk::AlignTSOS::detelement
const TrkDetElementBase * detelement(int i=0) const
method for retrieving detector elements (one if RIO, more if CRIO)
Definition: AlignTSOS.h:110
Trk::ParametersBase
Definition: ParametersBase.h:55
Trk::AlignTSOS::m_crio
const CompetingRIOsOnTrack * m_crio
Definition: AlignTSOS.h:161
Trk::AlignTSOS::m_unbiasedTrackPars
const TrackParameters * m_unbiasedTrackPars
Definition: AlignTSOS.h:163
beamspotman.dir
string dir
Definition: beamspotman.py:623
Trk::AlignTSOS::unbiasedTrackPars
const TrackParameters * unbiasedTrackPars() const
returns pointer to unbiased track parameters if present
Definition: AlignTSOS.h:134
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
Trk::TrackStateOnSurface::Variety
Variety
Definition: TrackStateOnSurface.h:212
Trk::AlignTSOS::m_measType
TrackState::MeasurementType m_measType
Definition: AlignTSOS.h:173
Trk::TrackStateOnSurface
represents the track state (measurement, material, fit parameters and quality) at a surface.
Definition: TrackStateOnSurface.h:71
Trk::AlignTSOS::alphaStrip
double alphaStrip() const
returns strip angle for fan-out structured modules (SCT endcap)
Definition: AlignTSOS.h:122
Trk::AlignTSOS::setAlphaStrip
void setAlphaStrip(double alpha)
returns strip angle for fan-out structured modules (SCT endcap)
Definition: AlignTSOS.h:119
Trk::AlignTSOS::m_rio
const RIO_OnTrack * m_rio
Definition: AlignTSOS.h:160
Trk::MeasurementBaseType::RIO_OnTrack
@ RIO_OnTrack
Definition: MeasurementBase.h:49
Trk::AlignTSOS::identify
Identifier identify() const
returns Identifier of RIO
Definition: AlignTSOS.cxx:147
Trk::AlignTSOS::~AlignTSOS
virtual ~AlignTSOS()
destructor
Definition: AlignTSOS.cxx:86
Residual.h
Trk::AlignTSOS::module
AlignModule * module()
Definition: AlignTSOS.h:70
Trk::operator<<
MsgStream & operator<<(MsgStream &sl, const AlignModule &alignModule)
overload of << operator for MsgStream for debug output
Definition: AlignModule.cxx:204
Trk::AlignTSOS::setDerivatives
void setDerivatives(std::vector< Amg::VectorX > *derivs)
setter for the derivatives
Definition: AlignTSOS.h:146
Trk::AlignTSOS::crio
const CompetingRIOsOnTrack * crio() const
returns CompetingRIOsOnTrack
Definition: AlignTSOS.h:92
Trk::AlignTSOS::nResDim
int nResDim() const
returns number of measurement residual + scatterer residual dimensions
Definition: AlignTSOS.h:77
Trk::AlignTSOS::addResidual
void addResidual(const Residual &residual)
pushes back vector of Residuals to alignTSOS residuals
Definition: AlignTSOS.h:95
Trk::AlignTSOS::setValid
void setValid(bool isvalid)
set and retrieve flag to indicate whether hit valid for alignment
Definition: AlignTSOS.h:73
Trk::Residual
Definition: Tracking/TrkAlignment/TrkAlignEvent/TrkAlignEvent/Residual.h:24
Trk::AlignTSOS::firstResidual
std::vector< Residual >::const_iterator firstResidual() const
returns first Residual iterator
Definition: AlignTSOS.h:104
Trk::TrackStateOnSurface::Align
@ Align
Definition: TrackStateOnSurface.h:215
TrackStateOnSurface.h
Identifier
Definition: IdentifierFieldParser.cxx:14