Fork me on GitHub

Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • modules/IdentificationMap.cc

    r341014c r95aa610  
    1717 */
    1818
     19
    1920/** \class IdentificationMap
    2021 *
     
    3233#include "classes/DelphesFormula.h"
    3334
     35#include "ExRootAnalysis/ExRootResult.h"
     36#include "ExRootAnalysis/ExRootFilter.h"
    3437#include "ExRootAnalysis/ExRootClassifier.h"
    35 #include "ExRootAnalysis/ExRootFilter.h"
    36 #include "ExRootAnalysis/ExRootResult.h"
    3738
     39#include "TMath.h"
     40#include "TString.h"
     41#include "TFormula.h"
     42#include "TRandom3.h"
     43#include "TObjArray.h"
    3844#include "TDatabasePDG.h"
    39 #include "TFormula.h"
    4045#include "TLorentzVector.h"
    41 #include "TMath.h"
    42 #include "TObjArray.h"
    43 #include "TRandom3.h"
    44 #include "TString.h"
    4546
    4647#include <algorithm>
     48#include <stdexcept>
    4749#include <iostream>
    4850#include <sstream>
    49 #include <stdexcept>
    5051
    5152using namespace std;
     
    7879
    7980  fEfficiencyMap.clear();
    80   for(i = 0; i < size / 3; ++i)
     81  for(i = 0; i < size/3; ++i)
    8182  {
    8283    formula = new DelphesFormula;
    83     formula->Compile(param[i * 3 + 2].GetString());
    84     pdg = param[i * 3].GetInt();
    85     fEfficiencyMap.insert(make_pair(pdg, make_pair(param[i * 3 + 1].GetInt(), formula)));
     84    formula->Compile(param[i*3 + 2].GetString());
     85    pdg = param[i*3].GetInt();
     86    fEfficiencyMap.insert(make_pair(pdg, make_pair(param[i*3 + 1].GetInt(), formula)));
    8687  }
    8788
     
    128129  Double_t pt, eta, phi, e;
    129130  TMisIDMap::iterator itEfficiencyMap;
    130   pair<TMisIDMap::iterator, TMisIDMap::iterator> range;
     131  pair <TMisIDMap::iterator, TMisIDMap::iterator> range;
    131132  DelphesFormula *formula;
    132133  Int_t pdgCodeIn, pdgCodeOut, charge;
     
    135136
    136137  fItInputArray->Reset();
    137   while((candidate = static_cast<Candidate *>(fItInputArray->Next())))
     138  while((candidate = static_cast<Candidate*>(fItInputArray->Next())))
    138139  {
    139140    const TLorentzVector &candidatePosition = candidate->Position;
     
    143144    pt = candidateMomentum.Pt();
    144145    e = candidateMomentum.E();
    145 
     146   
    146147    pdgCodeIn = candidate->PID;
    147148    charge = candidate->Charge;
     
    170171      {
    171172        // change PID of particle
    172         if(pdgCodeOut != 0) candidate->PID = charge * pdgCodeOut;
     173        if(pdgCodeOut != 0) candidate->PID = charge*pdgCodeOut;
    173174        fOutputArray->Add(candidate);
    174175        break;
Note: See TracChangeset for help on using the changeset viewer.