CMS 3D CMS Logo

/data/doxygen/doxygen-1.7.3/gen/CMSSW_4_2_8/src/Alignment/CommonAlignmentParametrization/interface/FrameToFrameDerivative.h

Go to the documentation of this file.
00001 #ifndef Alignment_CommonAlignmentParametrization_FrameToFrameDerivative_h
00002 #define Alignment_CommonAlignmentParametrization_FrameToFrameDerivative_h
00003 
00004 #include "CondFormats/Alignment/interface/Definitions.h"
00005 #include "DataFormats/Math/interface/AlgebraicROOTObjects.h"
00006 
00014 
00015 class Alignable;
00016 
00017 class FrameToFrameDerivative
00018 {
00019   public:
00020 
00022   AlgebraicMatrix frameToFrameDerivative(const Alignable* object,
00023                                          const Alignable* composedObject) const;
00024 
00029   AlgebraicMatrix66 getDerivative(const align::RotationType &objectRot,
00030                                   const align::RotationType &composeRot,
00031                                   const align::GlobalPoint &objectPos,
00032                                   const align::GlobalPoint &composePos) const;
00033 
00034   private:
00036   inline static AlgebraicMatrix transform(const align::RotationType&);
00037 
00039   AlgebraicMatrix getDerivative(const align::RotationType &objectRot,
00040                                 const align::RotationType &composeRot,
00041                                 const align::GlobalVector &posVec) const;
00042   
00044   AlgebraicVector linearEulerAngles(const AlgebraicMatrix &rotDelta) const;
00045  
00047   AlgebraicMatrix derivativePosPos(const AlgebraicMatrix &RotDet,
00048                                    const AlgebraicMatrix &RotRot) const;
00049 
00051   AlgebraicMatrix derivativePosRot(const AlgebraicMatrix &RotDet,
00052                                    const AlgebraicMatrix &RotRot,
00053                                    const AlgebraicVector &S) const;
00054 
00056   AlgebraicMatrix derivativeRotRot(const AlgebraicMatrix &RotDet,
00057                                    const AlgebraicMatrix &RotRot) const;
00058 
00059 };
00060 
00061 AlgebraicMatrix FrameToFrameDerivative::transform(const align::RotationType& rot)
00062 {
00063   AlgebraicMatrix R(3, 3);
00064 
00065   R(1, 1) = rot.xx(); R(1, 2) = rot.xy(); R(1, 3) = rot.xz();
00066   R(2, 1) = rot.yx(); R(2, 2) = rot.yy(); R(2, 3) = rot.yz();
00067   R(3, 1) = rot.zx(); R(3, 2) = rot.zy(); R(3, 3) = rot.zz();
00068 
00069   return R;
00070 }
00071 
00072 #endif
00073