CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_4_1_8_patch9/src/SimDataFormats/HcalTestBeam/interface/PHcalTB04Info.h

Go to the documentation of this file.
00001 #ifndef HcalTestBeam_PHcalTB04Info_h
00002 #define HcalTestBeam_PHcalTB04Info_h
00003 // -*- C++ -*-
00004 //
00005 // Package:     HcalTestBeam
00006 // Class  :     PHcalTB04Info
00007 // 
00017 //
00018 // Original Author:  Sunanda Banerjee
00019 //         Created:  Sun May 14 10:14:34 CEST 2006
00020 // $Id: PHcalTB04Info.h,v 1.2 2006/11/15 05:52:36 sunanda Exp $
00021 //
00022 
00023 // system include files
00024 #include <string>
00025 #include <vector>
00026 #include <memory>
00027 #include <cmath>
00028 
00029 // user include files
00030 
00031 // forward declarations
00032 class HcalTB04Analysis;
00033 
00034 class PHcalTB04Info {
00035 
00036   typedef std::vector<float>  FloatVector;
00037   typedef std::vector<int>    IntVector;
00038   friend class HcalTB04Analysis;
00039 
00040 public:
00041   PHcalTB04Info();
00042   virtual ~PHcalTB04Info();
00043 
00044   // ---------- const member functions ---------------------
00045   int         primary()     const {return nPrimary;}
00046   int         partID()      const {return idBeam;}
00047   float       initE()       const {return eBeam;}
00048   float       eta()         const {return etaBeam;}
00049   float       phi()         const {return phiBeam;}
00050   int         crystal()     const {return nCrystal;}
00051   IntVector   idsEcal()     const {return idEcal;}
00052   int         tower()       const {return nTower;}
00053   IntVector   idsHcal()     const {return idHcal;}
00054   float       simEtotal()   const {return simEtot;}
00055   float       simEcE()      const {return simEEc;}
00056   float       simHcE()      const {return simEHc;}
00057   float       digEtotal()   const {return digEtot;}
00058   float       digEcE()      const {return digEEc;}
00059   float       digHcE()      const {return digEHc;}
00060   FloatVector simEEcal()    const {return esime;}
00061   FloatVector digEEcal()    const {return edige;}
00062   FloatVector simEHcal()    const {return esimh;}
00063   FloatVector digEHcal()    const {return edigh;}
00064 
00065   int         nHit()        const {return hit;}
00066   IntVector   detectorHit() const {return detHit;}
00067   IntVector   etaIndexHit() const {return etaHit;}
00068   IntVector   phiIndexHit() const {return phiHit;}
00069   IntVector   layerHit()    const {return layHit;}
00070   FloatVector energyHit()   const {return eHit;}
00071   FloatVector timeHit()     const {return tHit;}
00072 
00073   int         evNum()       const {return v1EvNum;}
00074   int         vtxType()     const {return v1Type;}
00075   int         vtxSec()      const {return v1Nsec;}
00076   IntVector   vtxTrkID()    const {return v1secTrackID;}
00077   IntVector   vtxPartID()   const {return v1secPartID;}
00078   float       vtxPrimX()    const {return v1X;}
00079   float       vtxPrimY()    const {return v1Y;}
00080   float       vtxPrimZ()    const {return v1Z;}
00081   float       vtxPrimR()    const {return v1R;}
00082   float       vtxPrimU()    const {return v1U;}
00083   float       vtxPrimV()    const {return v1V;}
00084   float       vtxPrimW()    const {return v1W;}
00085   float       vtxPrimPx()   const {return v1Px;}
00086   float       vtxPrimPy()   const {return v1Py;}
00087   float       vtxPrimPz()   const {return v1Pz;}
00088   FloatVector vtxSecPx()    const {return v1secPx;}
00089   FloatVector vtxSecPy()    const {return v1secPy;}
00090   FloatVector vtxSecPz()    const {return v1secPz;}
00091   FloatVector vtxSecEk()    const {return v1secEk;}
00092 
00093   // ---------- static member functions --------------------
00094 
00095   // ---------- member functions ---------------------------
00096   void clear();
00097   void setIDs(std::vector<int>, std::vector<int>);
00098   void setPrimary(int primary, int id, double energy, double eta, double phi);
00099   void setEdep(double simtot, double sime, double simh, 
00100                double digtot, double dige, double digh);
00101   void setEdepEcal(std::vector<double> esim, std::vector<double> edig);
00102   void setEdepHcal(std::vector<double> esim, std::vector<double> edig);
00103 
00104   void setTrnsProf(std::vector<double> es1, std::vector<double> eq1, 
00105                    std::vector<double> es2, std::vector<double> eq2);
00106   void setLongProf(std::vector<double> es, std::vector<double> eq);
00107   void saveHit(int det, int lay, int eta, int phi, double e, double t);
00108 
00109   //Vertex associated methods
00110   void setVtxPrim(int evNum, int type, double x, double y, double z, double u,
00111                   double v, double w, double px, double py, double pz); 
00112   void setVtxSec(int id, int pdg, double px, double py, double pz, double ek); 
00113 
00114 private:
00115   //  PHcalTB04Info(const PHcalTB04Info&); 
00116   //  const PHcalTB04Info& operator=(const PHcalTB04Info&); 
00117 
00118   // ---------- member data --------------------------------
00119 
00120   //Beam parameters
00121   int          nPrimary, idBeam;
00122   float        eBeam, etaBeam, phiBeam;
00123 
00124   //Deposited energies
00125   float        simEtot, simEEc, simEHc;
00126   float        digEtot, digEEc, digEHc;
00127   FloatVector  esime, edige;
00128   FloatVector  esimh, edigh;
00129   FloatVector  latsimEta, latdigEta;
00130   FloatVector  latsimPhi, latdigPhi;
00131   FloatVector  longsim,   longdig;
00132 
00133   //Tower Members
00134   int          nCrystal;
00135   IntVector    idEcal;
00136   int          nTower;
00137   IntVector    idHcal;
00138 
00139   //Hit Members
00140   int         hit;
00141   IntVector   detHit, etaHit, phiHit, layHit;
00142   FloatVector eHit, tHit;
00143 
00144   //Vertex members
00145   int          v1EvNum, v1Type, v1Nsec;
00146   IntVector    v1secTrackID, v1secPartID;
00147   float        v1X, v1Y, v1Z, v1R, v1U, v1V, v1W;
00148   float        v1Px, v1Py, v1Pz;
00149   FloatVector  v1secPx, v1secPy, v1secPz, v1secEk;
00150 };
00151 
00152 
00153 #endif