CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
AlignmentParameters.h
Go to the documentation of this file.
1 #ifndef Alignment_CommonAlignment_AlignmentParameters_H
2 #define Alignment_CommonAlignment_AlignmentParameters_H
3 
4 #include <vector>
5 
8 
10 
27 
28 // include and not forward declare to ensure automatic conversion from AlignableDet(Unit):
29 // NO: include problems... #include "Alignment/CommonAlignment/interface/AlignableDetOrUnitPtr.h"
31 class Alignable;
33 class RecHit;
34 
36 {
37 
38 public:
39 
41 
44 
46  AlignmentParameters(Alignable* object, const AlgebraicVector& par,
47  const AlgebraicSymMatrix& cov);
48 
50  AlignmentParameters(Alignable* object, const AlgebraicVector& par,
51  const AlgebraicSymMatrix& cov, const std::vector<bool>& sel);
52 
55 
57  virtual ~AlignmentParameters();
58 
60  virtual void apply() = 0;
62  virtual int type() const = 0;
63 
65  virtual AlignmentParameters* clone(const AlgebraicVector& par,
66  const AlgebraicSymMatrix& cov) const = 0;
68  const AlgebraicSymMatrix& cov) const = 0;
69 
71  const std::vector<bool>& selector( void ) const;
72 
74  int numSelected( void ) const;
75 
77  AlgebraicVector selectedParameters( void ) const;
78 
81 
83  const AlgebraicVector& parameters(void) const;
84 
86  const AlgebraicSymMatrix& covariance(void) const;
87 
90  const AlignableDetOrUnitPtr &alidet) const = 0;
92  const AlignableDetOrUnitPtr &alidet) const;
93 
98 
100  Alignable* alignable( void ) const;
101 
106  virtual unsigned int hierarchyLevel() const;
107 
109  int size(void) const;
110 
112  bool isValid(void) const;
114  void setValid(bool v);
115 
116 protected:
117 
118  // private helper methods
120  const std::vector<bool>& sel) const;
122  const std::vector<bool>& sel) const;
124  const std::vector<bool>& sel) const;
126  const std::vector<bool>& sel) const;
127 
128  // data members
129 
131 
133 
135 
136  bool bValid;
137 
138 
139 };
140 
141 #endif
142 
143 
AlgebraicSymMatrix collapseSymMatrix(const AlgebraicSymMatrix &m, const std::vector< bool > &sel) const
AlgebraicVector selectedParameters(void) const
Get selected parameters.
AlgebraicSymMatrix expandSymMatrix(const AlgebraicSymMatrix &m, const std::vector< bool > &sel) const
const std::vector< bool > & selector(void) const
Get alignment parameter selector vector.
const AlgebraicVector & parameters(void) const
Get alignment parameters.
AlignmentUserVariables * userVariables(void) const
Get pointer to user variables.
virtual AlgebraicMatrix derivatives(const TrajectoryStateOnSurface &tsos, const AlignableDetOrUnitPtr &alidet) const =0
Get derivatives of selected parameters.
CLHEP::HepMatrix AlgebraicMatrix
void setValid(bool v)
Set validity flag.
(Abstract) Base class for alignment algorithm user variables
Alignable * alignable(void) const
Get pointer to corresponding alignable.
AlignmentParametersData::DataContainer DataContainer
AlgebraicSymMatrix selectedCovariance(void) const
Get covariance matrix of selected parameters.
int numSelected(void) const
Get number of selected parameters.
CLHEP::HepVector AlgebraicVector
virtual int type() const =0
tell type (AlignmentParametersFactory::ParametersType - but no circular dependency) ...
AlgebraicVector expandVector(const AlgebraicVector &m, const std::vector< bool > &sel) const
void setUserVariables(AlignmentUserVariables *auv)
Set pointer to user variables.
int size(void) const
Get number of parameters.
virtual AlignmentParameters * clone(const AlgebraicVector &par, const AlgebraicSymMatrix &cov) const =0
Enforce clone methods in derived classes.
AlgebraicVector collapseVector(const AlgebraicVector &m, const std::vector< bool > &sel) const
virtual ~AlignmentParameters()
Destructor.
bool isValid(void) const
Get validity flag.
CLHEP::HepSymMatrix AlgebraicSymMatrix
AlignmentParameters()
Default constructor.
bool bValid
True if parameters are valid.
virtual unsigned int hierarchyLevel() const
virtual AlignmentParameters * cloneFromSelected(const AlgebraicVector &par, const AlgebraicSymMatrix &cov) const =0
const AlgebraicSymMatrix & covariance(void) const
Get parameter covariance matrix.
AlignmentUserVariables * theUserVariables
virtual void apply()=0
apply parameters to alignable
virtual AlgebraicMatrix selectedDerivatives(const TrajectoryStateOnSurface &tsos, const AlignableDetOrUnitPtr &alidet) const