Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-03-17 10:38:46

0001 #ifndef Alignment_CommonAlignment_SurveyDet_h
0002 #define Alignment_CommonAlignment_SurveyDet_h
0003 
0004 /** \class SurveyDet
0005  *
0006  *  Class to hold survey info.
0007  *
0008  *  $Date: 2007/04/07 03:29:38 $
0009  *  $Revision: 1.4 $
0010  *  \author Chung Khim Lae
0011  */
0012 
0013 #include "Alignment/CommonAlignment/interface/AlignableSurface.h"
0014 
0015 class SurveyDet {
0016 public:
0017   /// Set the surface and 9 survey points to find its position and rotation.
0018   ///
0019   ///  -----------   ^   -----------
0020   /// | . | . | . |  |  | 4 | 3 | 2 |
0021   ///  -----------   |    -----------
0022   /// | . | . | . |  L  | 5 | 0 | 1 |
0023   ///  -----------   |   -----------
0024   /// | . | . | . |  |  | 6 | 7 | 8 |
0025   ///  -----------   v   -----------
0026   /// <---- W ---->
0027   ///
0028   /// The left sensor shows how the 9 points are chosen (W = width, L = length)
0029   /// The right sensor shows how the points are indexed.
0030   /// Also set the survey errors.
0031   SurveyDet(const AlignableSurface&,   // set the surface
0032             const align::ErrorMatrix&  // set the survey errors
0033   );
0034 
0035   inline const align::PositionType& position() const;
0036 
0037   inline const align::RotationType& rotation() const;
0038 
0039   inline const align::ErrorMatrix& errors() const;
0040 
0041   inline const align::LocalPoints& localPoints() const;
0042 
0043   inline align::GlobalPoints globalPoints() const;
0044 
0045   /// Find the Jacobian for a local point to be used in HIP algo.
0046   /// Does not check the range of index of local point.
0047   AlgebraicMatrix derivatives(unsigned int index  // index of point
0048   ) const;
0049 
0050 private:
0051   AlignableSurface theSurface;  // surface of det from survey info
0052 
0053   align::ErrorMatrix theErrors;
0054 
0055   std::vector<align::LocalPoint> thePoints;  // survey points on the surface
0056 };
0057 
0058 const align::PositionType& SurveyDet::position() const { return theSurface.position(); }
0059 
0060 const align::RotationType& SurveyDet::rotation() const { return theSurface.rotation(); }
0061 
0062 const align::ErrorMatrix& SurveyDet::errors() const { return theErrors; }
0063 
0064 const align::LocalPoints& SurveyDet::localPoints() const { return thePoints; }
0065 
0066 align::GlobalPoints SurveyDet::globalPoints() const { return theSurface.toGlobal(thePoints); }
0067 
0068 #endif