CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_0/src/TrackingTools/MaterialEffects/interface/MaterialEffectsUpdator.h

Go to the documentation of this file.
00001 #ifndef _CR_MATERIALEFFECTSUPDATOR_H_
00002 #define _CR_MATERIALEFFECTSUPDATOR_H_
00003 
00015 #include "DataFormats/GeometrySurface/interface/Surface.h"
00016 #include "TrackingTools/TrajectoryState/interface/TrajectoryStateOnSurface.h"
00017 #include "DataFormats/TrajectorySeed/interface/PropagationDirection.h"
00018 #include "FWCore/Utilities/interface/Visibility.h"
00019 
00020 class MaterialEffectsUpdator
00021 {  
00022 public:
00025   MaterialEffectsUpdator ( double mass );
00026   virtual ~MaterialEffectsUpdator ();
00027 
00031   virtual TrajectoryStateOnSurface updateState (const TrajectoryStateOnSurface& TSoS, 
00032                                                 const PropagationDirection propDir) const;
00033 
00040   virtual bool updateStateInPlace (TrajectoryStateOnSurface& TSoS, 
00041                                    const PropagationDirection propDir) const;
00042 
00043  
00046   virtual double deltaP (const TrajectoryStateOnSurface& TSoS, const PropagationDirection propDir) const;
00047 
00048 
00051   virtual const AlgebraicSymMatrix55 &deltaLocalError (const TrajectoryStateOnSurface& TSoS, 
00052                                                        const PropagationDirection propDir) const;
00053 
00056   inline double mass () const {
00057     return theMass;
00058   }
00059 
00060   virtual MaterialEffectsUpdator* clone()  const = 0;
00061 
00062  private:
00063   // here comes the actual computation of the values
00064   virtual void compute (const TrajectoryStateOnSurface&, const PropagationDirection) const dso_internal = 0;
00065 
00066   // check of arguments for use with cached values
00067   bool newArguments (const TrajectoryStateOnSurface & TSoS, PropagationDirection  propDir) const dso_internal;
00068   
00069  private:
00070   double theMass;
00071 
00072   // chache previous call state
00073   mutable double theLastOverP;
00074   mutable double theLastDxdz;
00075   mutable float  theLastRL;
00076   mutable PropagationDirection theLastPropDir;
00077 
00078 
00079 protected:  
00080   mutable double theDeltaP;
00081   mutable AlgebraicSymMatrix55 theDeltaCov;
00082   static  AlgebraicSymMatrix55  theNullMatrix;
00083 };
00084 
00085 #endif