CMS 3D CMS Logo

AlignTransformError.h
Go to the documentation of this file.
1 #ifndef AlignTransformError_H
2 #define AlignTransformError_H
4 
5 #include "CLHEP/Matrix/SymMatrix.h"
6 #include "CLHEP/Vector/RotationInterfaces.h"
7 
9 
14 public:
15  typedef CLHEP::HepSymMatrix SymMatrix;
16 
17 
19  AlignTransformError( const SymMatrix & symMatrix,
20  align::ID irawId ) :
21  m_rawId(irawId)
22  {
23  for ( unsigned int i=0; i<m_nPars; ++i )
24  for ( unsigned int j=0; j<=i; ++j )
25  m_Parameters[i*(i+1)/2+j] = symMatrix[i][j];
26  }
27 
28  SymMatrix matrix() const {
29  SymMatrix result(m_nPars);
30  for ( unsigned int i=0; i<m_nPars; ++i )
31  for ( unsigned int j=0; j<=i; ++j )
32  result[i][j] = m_Parameters[i*(i+1)/2+j];
33  return result;
34  }
35 
36  align::ID rawId() const { return m_rawId; }
37 
38 private:
39 
40  static const unsigned int m_nPars = 3;
41  double m_Parameters[m_nPars*(m_nPars+1)/2];
43 
44 
45 
47 };
48 #endif //AlignTransformError_H
int i
Definition: DBlmapReader.cc:9
SymMatrix matrix() const
CLHEP::HepSymMatrix SymMatrix
uint32_t ID
Definition: Definitions.h:26
AlignTransformError(const SymMatrix &symMatrix, align::ID irawId)
int j
Definition: DBlmapReader.cc:9
align::ID rawId() const
static const unsigned int m_nPars
double m_Parameters[m_nPars *(m_nPars+1)/2]
#define COND_SERIALIZABLE
Definition: Serializable.h:38