Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

HadLateEcConfigurer.cxx

Go to the documentation of this file.
00001 #include "FastShowerUtils/HadLateEcConfigurer.h"
00002 
00003 //S0
00004 #include "FastShowerUtils/Samplers/S0HadLateHcalEc1.h"
00005 #include "FastShowerUtils/Samplers/PeakMeanS0HadLateHcalEc1.h"
00006 #include "FastShowerUtils/Samplers/PeakSigmaS0HadLateHcalEc1.h"
00007 #include "FastShowerUtils/Samplers/TailFracS0HadLateHcalEc1.h"
00008 //C01
00009 //#include "FastShowerUtils/SamplerRouterADPhiSample.h"
00010 #include "FastShowerUtils/C0SamplerRouterADPhiSample.h"
00011 //#include "FastShowerUtils/SamplerRouterRndmSample.h"
00012 #include "FastShowerUtils/C0SamplerRouterRandomSample.h"
00013 //
00014 #include "FastShowerUtils/Samplers/C0HadLateHcalEc1.h"
00015 #include "FastShowerUtils/Samplers/PeakMeanC0HadLateHcalEc1.h"
00016 #include "FastShowerUtils/Samplers/PeakSigmaC0HadLateHcalEc1.h"
00017 #include "FastShowerUtils/Samplers/TailFracC0HadLateHcalEc1.h"
00018 //C02
00019 #include "FastShowerUtils/Samplers/C0HadLateHcalEc2.h"
00020 #include "FastShowerUtils/Samplers/PeakMeanC0HadLateHcalEc21.h"
00021 #include "FastShowerUtils/Samplers/PeakSigmaC0HadLateHcalEc21.h"
00022 #include "FastShowerUtils/Samplers/PeakMeanC0HadLateHcalEc22.h"
00023 #include "FastShowerUtils/Samplers/PeakSigmaC0HadLateHcalEc22.h"
00024 //SN
00025 //#include "FastShowerUtils/SamplerRouterC0Sample.h"
00026 #include "FastShowerUtils/SNSamplerRouterC0Sample.h"
00027 //
00028 #include "FastShowerUtils/Samplers/SNHadLateHcalEc1.h"
00029 #include "FastShowerUtils/Samplers/PeakMeanSNHadLateHcalEc1.h"
00030 #include "FastShowerUtils/Samplers/PeakSigmaSNHadLateHcalEc11.h"
00031 #include "FastShowerUtils/Samplers/PeakSigmaSNHadLateHcalEc12.h"
00032 //AN1
00033 //#include "FastShowerUtils/SamplerRouterSNSample.h"
00034 #include "FastShowerUtils/ANSamplerRouterSNSample.h"
00035 //
00036 #include "FastShowerUtils/Samplers/ANHadLateHcalEc1.h"
00037 #include "FastShowerUtils/Samplers/PeakMeanANHadLateHcalEc1.h"
00038 #include "FastShowerUtils/Samplers/PeakSigmaANHadLateHcalEc1.h"
00039 #include "FastShowerUtils/Samplers/TailFracANHadLateHcalEc1.h"
00040 //AN2
00041 #include "FastShowerUtils/Samplers/ANHadLateHcalEc2.h"
00042 //
00043 //HaloCells
00044 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell1.h"
00045 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell2.h"
00046 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell3.h"
00047 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell4.h"
00048 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell5.h"
00049 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell6.h"
00050 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell7.h"
00051 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell8.h"
00052 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell9.h"
00053 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell10.h"
00054 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell11.h"
00055 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell12.h"
00056 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell13.h"
00057 #include "FastShowerUtils/HaloCells/HadLateHcalEcHaloCell14.h"
00058 //
00059 //Normalisers
00060 #include "FastShowerUtils/Normalisers/HadLateEcalNormaliser.h"
00061 #include "FastShowerUtils/Normalisers/HadLateHcalNormaliser.h"
00062 #include "FastShowerUtils/Normalisers/HadEcalEtaResponseEc.h"
00063 #include "FastShowerUtils/Normalisers/HadHcalEtaResponseEc.h"
00064 #include "FastShowerUtils/Normalisers/HadLateHcalCoreFracEc.h"
00065 //
00066 #include "FastShowerUtils/PtrConverter.h"
00067 #include "FastShowerUtils/ISampler.h"
00068 #include "FastShowerUtils/SamplerPtr.h"
00069 #include "FastShowerUtils/INormaliser.h"
00070 #include "FastShowerUtils/NormaliserPtr.h"
00071 #include "FastShowerUtils/IDepositor.h"
00072 #include "FastShowerUtils/DepositorPtr.h"
00073 #include "FastShowerUtils/CoreDepositor.h"
00074 #include "FastShowerUtils/HaloDepositor.h"
00075 #include "FastShowerUtils/PencilDepositor.h"
00076 //
00077 #include "FastShowerUtils/PtrAdapter.h"
00078 //
00079 #include <string>
00080 #include <algorithm>
00081 
00082 namespace FastShower{
00083 
00084   //
00085   HadLateEcConfigurer::HadLateEcConfigurer(Moni m):ConfigurerBase(m){
00086     this->initialise();
00087   }
00088   HadLateEcConfigurer::HadLateEcConfigurer(NoMoni nm):ConfigurerBase(nm){
00089     this->initialise();
00090   }
00091   void HadLateEcConfigurer::initialise(){
00092     //S0
00093     this->addFn("S0PeakMean",        new  PeakMeanS0HadLateHcalEc1);
00094     this->addFn("S0PeakSigma",       new  PeakSigmaS0HadLateHcalEc1);
00095     this->addFn("S0TailFrac",        new  TailFracS0HadLateHcalEc1);
00096     //C01
00097     this->addFn("C01PeakMean",       new  PeakMeanC0HadLateHcalEc1);
00098     this->addFn("C01PeakSigma",      new  PeakSigmaC0HadLateHcalEc1);
00099     this->addFn("C01TailFrac",       new  TailFracC0HadLateHcalEc1);
00100     //C021
00101     this->addFn("C021PeakMean",      new  PeakMeanC0HadLateHcalEc21);
00102     this->addFn("C021PeakSigma",     new  PeakSigmaC0HadLateHcalEc21);
00103     //C022
00104     this->addFn("C022PeakMean",      new  PeakMeanC0HadLateHcalEc22);
00105     this->addFn("C022PeakSigma",     new  PeakSigmaC0HadLateHcalEc22);
00106     //SN11
00107     this->addFn("SN1PeakMean",       new  PeakMeanSNHadLateHcalEc1);
00108     this->addFn("SN1PeakSigma",      new  PeakSigmaSNHadLateHcalEc11);
00109     //SN12
00110     this->addFn("SN2PeakMean",       new  PeakMeanSNHadLateHcalEc1);
00111     this->addFn("SN2PeakSigma",      new  PeakSigmaSNHadLateHcalEc12);
00112     //AN1 
00113     this->addFn("AN1PeakMean",       new  PeakMeanANHadLateHcalEc1);
00114     this->addFn("AN1PeakSigma",      new  PeakSigmaANHadLateHcalEc1);
00115     this->addFn("AN1TailFrac",       new  TailFracANHadLateHcalEc1);
00116     //AN2 
00117     this->addFn("AN2PeakMean",       new  PeakMeanANHadLateHcalEc1);
00118     this->addFn("AN2PeakSigma",      new  PeakSigmaANHadLateHcalEc1);
00119     //
00120     //*******************************************************
00121     //*           Functions for HaloDepositor               *
00122     //*******************************************************
00123     this->addFnPP("HaloCell1",  new  HadLateHcalEcHaloCell1);
00124     this->addFnPP("HaloCell2",  new  HadLateHcalEcHaloCell2);
00125     this->addFnPP("HaloCell3",  new  HadLateHcalEcHaloCell3);
00126     this->addFnPP("HaloCell4",  new  HadLateHcalEcHaloCell4);
00127     this->addFnPP("HaloCell5",  new  HadLateHcalEcHaloCell5);
00128     this->addFnPP("HaloCell6",  new  HadLateHcalEcHaloCell6);
00129     this->addFnPP("HaloCell7",  new  HadLateHcalEcHaloCell7);
00130     this->addFnPP("HaloCell8",  new  HadLateHcalEcHaloCell8);
00131     this->addFnPP("HaloCell9",  new  HadLateHcalEcHaloCell9);
00132     this->addFnPP("HaloCell10",  new  HadLateHcalEcHaloCell10);
00133     this->addFnPP("HaloCell11",  new  HadLateHcalEcHaloCell11);
00134     this->addFnPP("HaloCell12",  new  HadLateHcalEcHaloCell12);
00135     this->addFnPP("HaloCell13",  new  HadLateHcalEcHaloCell13);
00136     this->addFnPP("HaloCell14",  new  HadLateHcalEcHaloCell14);
00137     //
00138     //*******************************************************
00139     //*              Functions for Normalisers              *
00140     //*******************************************************
00141     this->addFnPP("EcalEtaResponse",  new  HadEcalEtaResponseEc);
00142     this->addFnPP("HcalEtaResponse",  new  HadHcalEtaResponseEc);
00143     this->addFnPP("HcalCoreFraction", new  HadLateHcalCoreFracEc);
00144     //
00145     //*******************************************************
00146     //*       IUpdating Gaussians (Peaks for Samplers)      *
00147     //*******************************************************
00148     this->addIUG("S0Peak",   this->makeUpdatingGaussian0LP("S0") );
00149     this->addIUG("C01Peak",  this->makeUpdatingGaussian0LP("C01") );
00150     this->addIUG("C021Peak", this->makeUpdatingGaussian0LP("C021") );
00151     this->addIUG("C022Peak", this->makeUpdatingGaussian0LP("C022") );
00152     this->addIUG("SN1Peak",  this->makeUpdatingGaussian01P("SN1") );
00153     this->addIUG("SN2Peak",  this->makeUpdatingGaussian01P("SN2") );
00154     this->addIUG("AN1Peak",  this->makeUpdatingGaussian0LP("AN1") );
00155     this->addIUG("AN2Peak",  this->makeUpdatingGaussian0LP("AN2") );
00156     //
00157     //*******************************************************
00158     //*       Samplers                                      *
00159     //*******************************************************
00160     this->addSampler("S0",   new S0HadLateHcalEc1(this, "S0") );
00161     this->addSampler("C01",  new C0HadLateHcalEc1(this, "C01") );
00162     this->addSampler("C021", new C0HadLateHcalEc2(this, "C021") );
00163     this->addSampler("C022", new C0HadLateHcalEc2(this, "C022") );
00164     this->addSampler("SN1",  new SNHadLateHcalEc1(this, "SN1") );
00165     this->addSampler("SN2",  new SNHadLateHcalEc1(this, "SN2") );
00166     this->addSampler("AN1",  new ANHadLateHcalEc1(this, "AN1") );
00167     this->addSampler("AN2",  new ANHadLateHcalEc2(this, "AN2") );
00168 
00169     this->addSampler("C0",   this->makeC0() );
00170     this->addSampler("SN",   this->makeSN() );
00171     this->addSampler("AN",   this->makeAN() );
00172     //
00173     //*******************************************************
00174     //*       Depositors                                    *
00175     //*******************************************************
00176     this->addDepositorsE();
00177     this->addDepositorsH();
00178     //*******************************************************
00179     //*       Normalisers                                   *
00180     //*******************************************************
00181     this->normalisers();
00182    }
00183   //
00185   ISampler* HadLateEcConfigurer::makeC0() const {
00186 
00187     std::vector< std::pair<double, ISampler*> > vr;
00188     vr.push_back(std::pair<double, ISampler*>(0.5, this->findSampler("C021"))); 
00189     vr.push_back(std::pair<double, ISampler*>(1.0, this->findSampler("C022")));
00190     //ISampler* rndmSampler = new  SamplerRouterRndmSample(vr, 0.0, "C02Router");
00191     ISampler* rndmSampler = new  C0SamplerRouterRandomSample(vr, 0.0, "C02Router");
00192     
00193     std::vector< std::pair<double, ISampler*> > v;
00194     v.push_back(std::pair<double, ISampler*>(0.035, this->findSampler("C01"))); 
00195     v.push_back(std::pair<double, ISampler*>(0.050, rndmSampler)); 
00196     //return new SamplerRouterADPhiSample(v, 0.0, "C0Router");
00197     return new C0SamplerRouterADPhiSample(v, 0.0, "C0Router");
00198     
00199   }
00201   ISampler* HadLateEcConfigurer::makeSN() const {
00202 
00203     std::vector< std::pair<double, ISampler*> > v;
00204     v.push_back(std::pair<double, ISampler*>(0.6, this->findSampler("SN1"))); 
00205     v.push_back(std::pair<double, ISampler*>(1.0, this->findSampler("SN2"))); 
00206     //return new SamplerRouterC0Sample(v, 0.0, "SNRouter");
00207     return new SNSamplerRouterC0Sample(v, 0.0, "SNRouter");
00208     
00209   }
00211   ISampler* HadLateEcConfigurer::makeAN() const {
00212 
00213     std::vector< std::pair<double, ISampler*> > v;
00214     v.push_back(std::pair<double, ISampler*>(0.15, this->findSampler("AN1"))); 
00215     v.push_back(std::pair<double, ISampler*>(1.00, this->findSampler("AN2"))); 
00216     //return new SamplerRouterSNSample(v, 0.0, "ANRouter");
00217     return new ANSamplerRouterSNSample(v, 0.0, "ANRouter");
00218 
00219   }
00221   void HadLateEcConfigurer::addDepositorsE(){
00222     
00223     this->addEdepositor( "ECalPencil", new PencilDepositor);
00224 
00225   }
00227   void HadLateEcConfigurer::addDepositorsH(){
00228     
00229     this->addHdepositor( "HcalCore",
00230                          new CoreDepositor(
00231                                            this->findSampler("S0"),
00232                                            this->findSampler("C0"),
00233                                            this->findSampler("SN"),
00234                                            this->findSampler("AN")
00235                                            )
00236                          );
00237 
00238     this->addHdepositor( "HcalHalo", new HaloDepositor(this,"Halo"));
00239     
00240   }
00242   EnergyLimiter* HadLateEcConfigurer::energyLimiter() const {
00243     cout<<"HadLateEcConfigurer: constructing energy limiter"<<endl;
00244     return new EnergyLimiter(10., 50., "HadLateEcEnergyLimiter");
00245   }
00247   void HadLateEcConfigurer::normalisers(){
00248     this->addNormaliser("EcalNormaliser",  
00249                         new HadLateEcalNormaliser(this,"HadLateEcEcalNormaliser"));
00250     this->addNormaliser("HcalNormaliser",  
00251                         new HadLateHcalNormaliser(this,"HadLateEcHcalNormaliser"));
00252   }
00253 }//namespace
00254 
00255 
00256 
00257 
00258 
00259 
00260 
00261 
00262 

Generated on Tue Mar 18 11:49:59 2003 for FastShowerUtils by doxygen1.3-rc1