Fork me on GitHub

Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • modules/Isolation.cc

    r844a970 re2339af  
    110110
    111111  fUseRhoCorrection = GetBool("UseRhoCorrection", true);
     112
     113  fDeltaRMin = GetDouble("DeltaRMin", 0.01);
     114  fUseMiniCone = GetBool("UseMiniCone", false);
    112115
    113116  fClassifier->fPTMin = GetDouble("PTMin", 0.5);
     
    157160  Double_t sumChargedNoPU, sumChargedPU, sumNeutral, sumAllParticles;
    158161  Double_t sumDBeta, ratioDBeta, sumRhoCorr, ratioRhoCorr, sum, ratio;
    159   Int_t counter;
     162  Bool_t pass = kFALSE;
    160163  Double_t eta = 0.0;
    161164  Double_t rho = 0.0;
     
    197200    sumAllParticles = 0.0;
    198201
    199     counter = 0;
    200202    itIsolationArray.Reset();
    201 
    202203    while((isolation = static_cast<Candidate*>(itIsolationArray.Next())))
    203204    {
    204205      const TLorentzVector &isolationMomentum = isolation->Momentum;
    205206
    206       if(candidateMomentum.DeltaR(isolationMomentum) <= fDeltaRMax &&
    207          candidate->GetUniqueID() != isolation->GetUniqueID())
    208       {
     207      if(fUseMiniCone)
     208      {
     209         pass = candidateMomentum.DeltaR(isolationMomentum) <= fDeltaRMax &&
     210         candidateMomentum.DeltaR(isolationMomentum) > fDeltaRMin;
     211      }
     212      else
     213      {
     214         pass = candidateMomentum.DeltaR(isolationMomentum) <= fDeltaRMax &&
     215         candidate->GetUniqueID() != isolation->GetUniqueID();
     216      }
     217
     218      if(pass)
     219      {
     220
    209221        sumAllParticles += isolationMomentum.Pt();
    210222        if(isolation->Charge != 0)
     
    223235          sumNeutral += isolationMomentum.Pt();
    224236        }
    225         ++counter;
    226       }
     237      }
     238
    227239    }
    228240
    229     // find rho
     241   // find rho
    230242    rho = 0.0;
    231243    if(fRhoInputArray)
     
    240252      }
    241253    }
     254
     255
    242256
    243257    // correct sum for pile-up contamination
Note: See TracChangeset for help on using the changeset viewer.