Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-09-16 03:24:07

0001 #ifndef RecoLocalMuon_DTLinearDriftAlgo_H
0002 #define RecoLocalMuon_DTLinearDriftAlgo_H
0003 
0004 /** \class DTLinearDriftAlgo
0005  *  Concrete implementation of DTRecHitBaseAlgo.
0006  *  Compute drift distance using constant drift velocity
0007  *  as defined in the "driftVelocity" parameter.
0008  *
0009  *  \author G. Cerminara - INFN Torino
0010  */
0011 
0012 #include "RecoLocalMuon/DTRecHit/interface/DTRecHitBaseAlgo.h"
0013 #include "FWCore/Framework/interface/ConsumesCollector.h"
0014 
0015 class DTLinearDriftAlgo : public DTRecHitBaseAlgo {
0016 public:
0017   /// Constructor
0018   DTLinearDriftAlgo(const edm::ParameterSet& config, edm::ConsumesCollector);
0019 
0020   /// Destructor
0021   ~DTLinearDriftAlgo() override;
0022 
0023   // Operations
0024 
0025   /// Pass the Event Setup to the algo at each event
0026   void setES(const edm::EventSetup& setup) override;
0027 
0028   /// First step in computation of Left/Right hits from a Digi.
0029   /// The results are the local position (in DTLayer frame) of the
0030   /// Left and Right hit, and the error (which is common). Returns
0031   /// false on failure. The hit is assumed to be at the wire center.
0032   bool compute(const DTLayer* layer,
0033                const DTDigi& digi,
0034                LocalPoint& leftPoint,
0035                LocalPoint& rightPoint,
0036                LocalError& error) const override;
0037 
0038   /// Second step in hit position computation.
0039   /// It is the same as first step since the angular information is not used
0040   /// NOTE: Only position and error of the new hit are modified
0041   bool compute(const DTLayer* layer,
0042                const DTRecHit1D& recHit1D,
0043                const float& angle,
0044                DTRecHit1D& newHit1D) const override;
0045 
0046   /// Third (and final) step in hits position computation.
0047   /// Also the hit position along the wire is available
0048   /// and can be used to correct the drift time for particle
0049   /// TOF and propagation of signal along the wire.
0050   /// NOTE: Only position and error of the new hit are modified
0051   bool compute(const DTLayer* layer,
0052                const DTRecHit1D& recHit1D,
0053                const float& angle,
0054                const GlobalPoint& globPos,
0055                DTRecHit1D& newHit1D) const override;
0056 
0057 private:
0058   // Do the actual work.
0059   virtual bool compute(const DTLayer* layer,
0060                        const DTWireId& wireId,
0061                        const float digiTime,
0062                        const GlobalPoint& globPos,
0063                        LocalPoint& leftPoint,
0064                        LocalPoint& rightPoint,
0065                        LocalError& error,
0066                        int step) const;
0067 
0068   // Interface to the method which does the actual work suited for 2nd and 3rd steps
0069   virtual bool compute(const DTLayer* layer,
0070                        const DTWireId& wireId,
0071                        const float digiTime,
0072                        const GlobalPoint& globPos,
0073                        DTRecHit1D& newHit1D,
0074                        int step) const;
0075 
0076   // The Drift Velocity (cm/ns)
0077   const float vDrift;
0078   // // The Drift Velocity (cm/ns) for MB1 Wheel1 (non fluxed chamber) 21-Dec-2006 SL
0079   // const float vDriftMB1W1;
0080 
0081   // The resolution on the Hits (cm)
0082   const float hitResolution;
0083 
0084   // Times below MinTime (ns) are considered as coming from previous BXs.
0085   const float minTime;
0086 
0087   // Times above MaxTime (ns) are considered as coming from following BXs
0088   const float maxTime;
0089 
0090   // Switch on/off the verbosity
0091   const bool debug;
0092 };
0093 #endif