CMS 3D CMS Logo

Public Member Functions | Public Attributes

ZSelector Struct Reference

List of all members.

Public Member Functions

int operator() (const Candidate &c) const
 ZSelector (double ptMin, double etaDau0Min, double etaDau0Max, double etaDau1Min, double etaDau1Max, double massMin, double massMax, double massMinZMC, double massMaxZMC)

Public Attributes

double etaDau0Max_
double etaDau0Min_
double etaDau1Max_
double etaDau1Min_
double massMax_
double massMaxZMC_
double massMin_
double massMinZMC_
double ptMin_

Detailed Description

Definition at line 23 of file MCAcceptanceAnalyzer.cc.


Constructor & Destructor Documentation

ZSelector::ZSelector ( double  ptMin,
double  etaDau0Min,
double  etaDau0Max,
double  etaDau1Min,
double  etaDau1Max,
double  massMin,
double  massMax,
double  massMinZMC,
double  massMaxZMC 
) [inline]

Definition at line 24 of file MCAcceptanceAnalyzer.cc.

                                                                                                                                                                           :
    ptMin_(ptMin), etaDau0Min_(etaDau0Min),etaDau0Max_(etaDau0Max),  etaDau1Min_(etaDau1Min),etaDau1Max_(etaDau1Max), 
    massMin_(massMin), massMax_(massMax), massMinZMC_(massMinZMC), massMaxZMC_(massMaxZMC) { }

Member Function Documentation

int ZSelector::operator() ( const Candidate c) const [inline]

allowing asymmetric cut....

Definition at line 27 of file MCAcceptanceAnalyzer.cc.

References debug_cff::d0, debug_cff::d1, reco::Candidate::daughter(), reco::Candidate::eta(), m, reco::Candidate::mass(), mcMuDaughter(), reco::Candidate::numberOfDaughters(), reco::Candidate::p4(), and reco::Candidate::pt().

                                           {
    //   std::cout << "c.numberOfDaughters(): " << c.numberOfDaughters()<< std::endl;    
    if (c.numberOfDaughters()<2) return 0; 
    if (c.numberOfDaughters()>=6)      return 0;
    const Candidate * d0 = c.daughter(0);
    const Candidate * d1 = c.daughter(1);
    if(c.numberOfDaughters()>2) {
    if (d0->numberOfDaughters()>0)  d0 = mcMuDaughter(d0);
    if (d1->numberOfDaughters()>0)  d1 = mcMuDaughter(d1);
    }
    int temp_cut= 0;
    if( ( fabs(d0->eta()) > etaDau0Min_ && fabs(d1->eta())>etaDau1Min_ && fabs(d0->eta()) < etaDau0Max_ && fabs(d1->eta()) <etaDau1Max_ ) ||  ( fabs(d0->eta()) > etaDau1Min_ && fabs(d1->eta())>etaDau0Min_ && fabs(d0->eta()) < etaDau1Max_ && fabs(d1->eta()) <etaDau0Max_ ) ) {
      temp_cut=1;
      if(d0->pt() > ptMin_ && d1->pt() > ptMin_) {
        temp_cut=2;
        double m = (d0->p4() + d1->p4()).mass();
        if(m > massMin_ && m < massMax_) temp_cut=3; 
        if (c.mass()> massMinZMC_ && c.mass() < massMaxZMC_) temp_cut =4;  
      }
    } 
    
    return temp_cut;
  }

Member Data Documentation

Definition at line 51 of file MCAcceptanceAnalyzer.cc.

Definition at line 51 of file MCAcceptanceAnalyzer.cc.

Definition at line 51 of file MCAcceptanceAnalyzer.cc.

Definition at line 51 of file MCAcceptanceAnalyzer.cc.

Definition at line 51 of file MCAcceptanceAnalyzer.cc.

Definition at line 51 of file MCAcceptanceAnalyzer.cc.

Definition at line 51 of file MCAcceptanceAnalyzer.cc.

Definition at line 51 of file MCAcceptanceAnalyzer.cc.

Definition at line 51 of file MCAcceptanceAnalyzer.cc.