CMS 3D CMS Logo

HelpertRecHit2DLocalPos.cc

Go to the documentation of this file.
00001 #include "TrackingTools/TransientTrackingRecHit/interface/HelpertRecHit2DLocalPos.h"
00002 #include "DataFormats/GeometryCommonDetAlgo/interface/ErrorFrameTransformer.h"
00003 #include "Geometry/CommonDetUnit/interface/GeomDet.h"
00004 #include "DataFormats/TrackingRecHit/interface/AlignmentPositionError.h"
00005 
00006 AlgebraicSymMatrix HelpertRecHit2DLocalPos::parError( const LocalError& le,
00007                                                       const GeomDet& det) const
00008 {
00009   AlgebraicSymMatrix m(2);
00010   if ( det.alignmentPositionError() != 0) {
00011     LocalError lape =
00012       ErrorFrameTransformer().transform( det.alignmentPositionError()->globalError(),
00013                                          det.surface());
00014     m[0][0] = le.xx()+lape.xx();
00015     m[0][1] = le.xy()+lape.xy();
00016     m[1][1] = le.yy()+lape.yy();
00017   } else {
00018     m[0][0] = le.xx();
00019     m[0][1] = le.xy();
00020     m[1][1] = le.yy();
00021   };
00022   return m;
00023 }
00024 
00025 void
00026 HelpertRecHit2DLocalPos::getKfComponents(KfComponentsHolder & holder,
00027                         const TrackingRecHit &hit2dLocalPos,
00028                         const GeomDet& det) const 
00029 {
00030     hit2dLocalPos.getKfComponents(holder);
00031     if ( det.alignmentPositionError() != 0) {
00032         LocalError lape =
00033             ErrorFrameTransformer().transform( det.alignmentPositionError()->globalError(),
00034                     det.surface());
00035         AlgebraicSymMatrix22 &m = holder.errors<2>();
00036         m(0, 0) += lape.xx();
00037         m(0, 1) += lape.xy();
00038         m(1, 1) += lape.yy();
00039     }
00040 }

Generated on Tue Jun 9 17:48:41 2009 for CMSSW by  doxygen 1.5.4