CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
MuonSeedFinder Class Reference

#include <MuonSeedFinder.h>

Inheritance diagram for MuonSeedFinder:
MuonSeedVFinder

Public Member Functions

 MuonSeedFinder (const edm::ParameterSet &pset)
 Constructor. More...
 
void seeds (const MuonTransientTrackingRecHit::MuonRecHitContainer &hits, std::vector< TrajectorySeed > &result)
 
virtual void setBField (const MagneticField *field)
 
virtual ~MuonSeedFinder ()
 Destructor. More...
 
- Public Member Functions inherited from MuonSeedVFinder
void setBeamSpot (const GlobalVector &gv)
 
virtual ~MuonSeedVFinder ()
 

Private Member Functions

void analyze () const
 
float computePt (MuonTransientTrackingRecHit::ConstMuonRecHitPointer muon, const MagneticField *field) const
 

Private Attributes

MuonDTSeedFromRecHits theBarrel
 
MuonCSCSeedFromRecHits theEndcap
 
const MagneticFieldtheField
 
float theMinMomentum
 
MuonOverlapSeedFromRecHits theOverlap
 

Additional Inherited Members

- Protected Attributes inherited from MuonSeedVFinder
MuonSeedPtExtractorthePtExtractor
 

Detailed Description

Uses SteppingHelixPropagator

Author
A. Vitelli - INFN Torino
porting R. Bellan - INFN Torino

Uses SteppingHelixPropagator

Author
R. Wilkinson

Definition at line 22 of file MuonSeedFinder.h.

Constructor & Destructor Documentation

MuonSeedFinder::MuonSeedFinder ( const edm::ParameterSet pset)

Constructor.

Definition at line 19 of file MuonSeedFinder.cc.

References MuonSeedFromRecHits::setPtExtractor(), theBarrel, theEndcap, theMinMomentum, theOverlap, and MuonSeedVFinder::thePtExtractor.

19  :
20  theBarrel(),
21  theOverlap(),
22  theEndcap()
23 {
24 
25  // FIXME put it in a pSet
26  // theMinMomentum = pset.getParameter<double>("EndCapSeedMinPt"); //3.0
27  theMinMomentum = 3.0;
32 
33 }
MuonOverlapSeedFromRecHits theOverlap
MuonSeedPtExtractor * thePtExtractor
void setPtExtractor(const MuonSeedPtExtractor *extractor)
MuonCSCSeedFromRecHits theEndcap
MuonDTSeedFromRecHits theBarrel
virtual MuonSeedFinder::~MuonSeedFinder ( )
inlinevirtual

Destructor.

Definition at line 29 of file MuonSeedFinder.h.

References analyze(), computePt(), hfClusterShapes_cfi::hits, mps_fire::result, seeds(), setBField(), and MuonSeedVFinder::thePtExtractor.

29 {delete thePtExtractor;}
MuonSeedPtExtractor * thePtExtractor

Member Function Documentation

void MuonSeedFinder::analyze ( ) const
private

Referenced by ~MuonSeedFinder().

float MuonSeedFinder::computePt ( MuonTransientTrackingRecHit::ConstMuonRecHitPointer  muon,
const MagneticField field 
) const
private

Referenced by ~MuonSeedFinder().

void MuonSeedFinder::seeds ( const MuonTransientTrackingRecHit::MuonRecHitContainer hits,
std::vector< TrajectorySeed > &  result 
)
virtual

Implements MuonSeedVFinder.

Definition at line 45 of file MuonSeedFinder.cc.

References MuonSeedFromRecHits::add(), MuonSeedFromRecHits::clear(), MuonSeedFromRecHits::firstRecHit(), LogDebug, LogTrace, metname, MuonCSCSeedFromRecHits::seed(), MuonDTSeedFromRecHits::seed(), MuonOverlapSeedFromRecHits::seeds(), AlCaHLTBitMon_QueryRunRegistry::string, theBarrel, theEndcap, and theOverlap.

Referenced by ~MuonSeedFinder().

47 {
48  const std::string metname = "Muon|RecoMuon|MuonSeedFinder";
49 
50  // MuonDumper debug;
51 
52  unsigned int num_bar = 0;
53  for ( MuonRecHitContainer::const_iterator iter = hits.begin(); iter!= hits.end(); iter++ ){
54  if ( (*iter)->isDT() ) {
55  theBarrel.add(*iter);
56  theOverlap.add(*iter);
57  num_bar++;
58  }
59  }
60 
61  unsigned int num_endcap = 0;
62  for ( MuonRecHitContainer::const_iterator iter = hits.begin(); iter!= hits.end(); iter++ ){
63  if ( (*iter)->isCSC() )
64  {
65 //std::cout << **iter << std::endl;
66  theEndcap.add(*iter);
67  theOverlap.add(*iter);
68  ++num_endcap;
69  }
70  }
71 
72  // don't do dim-2 seeds in the overlap
73  if ( num_bar >1 || (num_bar==1 && (num_endcap==0 || theBarrel.firstRecHit()->dimension() == 4))) {
74  LogDebug(metname)
75  << "Barrel Seeds " << num_bar << endl;
76  result.push_back(theBarrel.seed());
77 
78  }
79 
80  if(num_endcap > 1 || (num_endcap==1 && num_bar==0))
81  {
82  LogDebug(metname)
83  << "Endcap Seeds " << num_endcap << endl;
84  result.push_back(theEndcap.seed());
85  }
86 
87  if(num_bar > 0 && num_endcap > 0)
88  {
89  LogTrace(metname) << "Overlap Seed" << endl;
90  std::vector<TrajectorySeed> overlapSeeds = theOverlap.seeds();
91  result.insert(result.end(), overlapSeeds.begin(), overlapSeeds.end());
92  }
93 
94  theBarrel.clear();
95  theOverlap.clear();
96  theEndcap.clear();
97 
98 
99 }
#define LogDebug(id)
virtual TrajectorySeed seed() const
const std::string metname
MuonTransientTrackingRecHit::ConstMuonRecHitPointer firstRecHit() const
MuonOverlapSeedFromRecHits theOverlap
#define LogTrace(id)
virtual TrajectorySeed seed() const
void add(MuonTransientTrackingRecHit::MuonRecHitPointer hit)
std::vector< TrajectorySeed > seeds() const
MuonCSCSeedFromRecHits theEndcap
MuonDTSeedFromRecHits theBarrel
void MuonSeedFinder::setBField ( const MagneticField field)
virtual

Implements MuonSeedVFinder.

Definition at line 36 of file MuonSeedFinder.cc.

References MuonSeedFromRecHits::setBField(), theBarrel, theEndcap, theField, and theOverlap.

Referenced by ~MuonSeedFinder().

37 {
38  theField = field;
39  theBarrel.setBField(field);
40  theOverlap.setBField(field);
41  theEndcap.setBField(field);
42 }
MuonOverlapSeedFromRecHits theOverlap
void setBField(const MagneticField *field)
const MagneticField * theField
MuonCSCSeedFromRecHits theEndcap
MuonDTSeedFromRecHits theBarrel

Member Data Documentation

MuonDTSeedFromRecHits MuonSeedFinder::theBarrel
private

Definition at line 48 of file MuonSeedFinder.h.

Referenced by MuonSeedFinder(), seeds(), and setBField().

MuonCSCSeedFromRecHits MuonSeedFinder::theEndcap
private

Definition at line 50 of file MuonSeedFinder.h.

Referenced by MuonSeedFinder(), seeds(), and setBField().

const MagneticField* MuonSeedFinder::theField
private

Definition at line 46 of file MuonSeedFinder.h.

Referenced by setBField().

float MuonSeedFinder::theMinMomentum
private

Definition at line 45 of file MuonSeedFinder.h.

Referenced by MuonSeedFinder().

MuonOverlapSeedFromRecHits MuonSeedFinder::theOverlap
private

Definition at line 49 of file MuonSeedFinder.h.

Referenced by MuonSeedFinder(), seeds(), and setBField().