Fork me on GitHub

Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • display/Delphes3DGeometry.cc

    r1fa50c2 rf53a4d2  
    1717 */
    1818
    19 #include "display/Delphes3DGeometry.h"
    2019#include <set>
    2120#include <map>
     
    2524#include <sstream>
    2625#include <cassert>
     26
     27#include "TAxis.h"
    2728#include "TGeoManager.h"
    2829#include "TGeoVolume.h"
     
    3435#include "TGeoCone.h"
    3536#include "TGeoArb8.h"
    36 #include "external/ExRootAnalysis/ExRootConfReader.h"
    37 #include "classes/DelphesClasses.h"
    3837#include "TF2.h"
     38#include "TFormula.h"
    3939#include "TH1F.h"
    4040#include "TMath.h"
     41#include "TString.h"
     42
     43#include "display/Delphes3DGeometry.h"
     44
     45#include "classes/DelphesClasses.h"
     46#include "external/ExRootAnalysis/ExRootConfReader.h"
    4147
    4248using namespace std;
     
    9096   tk_length_ = confReader->GetDouble(Form("%s::HalfLength",ParticlePropagator), 3.0)*100.;     // tk_length
    9197   tk_Bz_     = confReader->GetDouble("ParticlePropagator::Bz", 0.0);                           // tk_Bz
    92 
     98   
     99   TString buffer;
     100   const char *it;
     101 
     102   
    93103   {
    94104   TString tkEffFormula = confReader->GetString(Form("%s::EfficiencyFormula",TrackingEfficiency),"abs(eta)<3.0");
     
    96106   tkEffFormula.ReplaceAll("eta","y");
    97107   tkEffFormula.ReplaceAll("phi","0.");
    98    TF2* tkEffFunction = new TF2("tkEff",tkEffFormula,0,1000,-10,10);
     108 
     109   buffer.Clear();
     110   for(it = tkEffFormula.Data(); *it; ++it)
     111   {
     112     if(*it == ' ' || *it == '\t' || *it == '\r' || *it == '\n' || *it == '\\' ) continue;
     113     buffer.Append(*it);
     114   }
     115
     116   TF2* tkEffFunction = new TF2("tkEff",buffer,0,1000,-10,10);
    99117   TH1F etaHisto("eta","eta",100,5.,-5.);
    100118   Double_t pt,eta;
     
    118136   muonEffFormula.ReplaceAll("eta","y");
    119137   muonEffFormula.ReplaceAll("phi","0.");
    120    TF2* muEffFunction = new TF2("muEff",muonEffFormula,0,1000,-10,10);
     138   
     139   buffer.Clear();
     140   for(it = muonEffFormula.Data(); *it; ++it)
     141   {
     142     if(*it == ' ' || *it == '\t' || *it == '\r' || *it == '\n' || *it == '\\' ) continue;
     143     buffer.Append(*it);
     144   }
     145
     146   TF2* muEffFunction = new TF2("muEff",buffer,0,1000,-10,10);
    121147   TH1F etaHisto("eta2","eta2",100,5.,-5.);
    122148   Double_t pt,eta;
Note: See TracChangeset for help on using the changeset viewer.