CMS 3D CMS Logo

Classes | Public Types | Public Member Functions | Private Attributes

PHcalTB06Info Class Reference

#include <SimDataFormats/HcalTestBeam/interface/PHcalTB06Info.h>

List of all members.

Classes

struct  Hit
struct  Vtx

Public Types

typedef std::vector< float > FloatVector
typedef std::vector< HitHitVector
typedef std::vector< int > IntVector
typedef std::vector< VtxVtxVector

Public Member Functions

void clear ()
float eta () const
int evNum () const
float initE () const
int partID () const
 PHcalTB06Info ()
float phi () const
int primary () const
void saveHit (unsigned int det, double eta, double phi, double e, double t)
void setEdep (double simtot, double sime, double simh)
void setPrimary (int primary, int id, double energy, double eta, double phi)
void setVtxPrim (int evNum, int type, double x, double y, double z, double u, double v, double w, double px, double py, double pz)
void setVtxSec (int id, int pdg, double px, double py, double pz, double ek)
float simEcE () const
float simEtotal () const
float simHcE () const
Hit simHit (unsigned int i) const
float simHitE (unsigned int i) const
float simHitEta (unsigned int i) const
unsigned int simHitID (unsigned int i) const
float simHitPhi (unsigned int i) const
HitVector simHits () const
float simHitT (unsigned int i) const
int vtxPartID (unsigned int i) const
float vtxPrimPx () const
float vtxPrimPy () const
float vtxPrimPz () const
float vtxPrimR () const
float vtxPrimU () const
float vtxPrimV () const
float vtxPrimW () const
float vtxPrimX () const
float vtxPrimY () const
float vtxPrimZ () const
int vtxSec () const
float vtxSecEKin (unsigned int i) const
VtxVector vtxSecondaries () const
Vtx vtxSecondary (unsigned int i) const
float vtxSecPx (unsigned int i) const
float vtxSecPy (unsigned int i) const
float vtxSecPz (unsigned int i) const
int vtxTrackID (unsigned int i) const
int vtxType () const
virtual ~PHcalTB06Info ()

Private Attributes

float digEEc
float digEHc
float digEtot
float eBeam
float etaBeam
int hit
HitVector hits
int idBeam
int nPrimary
float phiBeam
float simEEc
float simEHc
float simEtot
int v1EvNum
int v1Nsec
float v1Px
float v1Py
float v1Pz
float v1R
VtxVector v1Sec
int v1Type
float v1U
float v1V
float v1W
float v1X
float v1Y
float v1Z

Detailed Description

Description: Histogram handling class for analysis

Usage: Simulation information for test beam studies of 2004 Test Beam Contains beam information, hits and digitised results

Definition at line 30 of file PHcalTB06Info.h.


Member Typedef Documentation

typedef std::vector<float> PHcalTB06Info::FloatVector

Definition at line 55 of file PHcalTB06Info.h.

typedef std::vector<Hit> PHcalTB06Info::HitVector

Definition at line 58 of file PHcalTB06Info.h.

typedef std::vector<int> PHcalTB06Info::IntVector

Definition at line 56 of file PHcalTB06Info.h.

typedef std::vector<Vtx> PHcalTB06Info::VtxVector

Definition at line 57 of file PHcalTB06Info.h.


Constructor & Destructor Documentation

PHcalTB06Info::PHcalTB06Info ( )

Definition at line 32 of file PHcalTB06Info.cc.

References clear().

                             {
  clear();
}
PHcalTB06Info::~PHcalTB06Info ( ) [virtual]

Definition at line 40 of file PHcalTB06Info.cc.

                              {
}

Member Function Documentation

void PHcalTB06Info::clear ( void  )

Definition at line 58 of file PHcalTB06Info.cc.

References eBeam, etaBeam, hits, idBeam, nPrimary, phiBeam, simEEc, simEHc, simEtot, v1EvNum, v1Nsec, v1Px, v1Py, v1Pz, v1Sec, v1Type, v1U, v1V, v1W, v1X, v1Y, and v1Z.

Referenced by PHcalTB06Info().

                          {
  nPrimary =  idBeam =0;
  eBeam = etaBeam = phiBeam = 0;

  simEtot = simEEc = simEHc = 0;

  hit = 0;
  hits.clear();

  v1EvNum = v1Type = v1Nsec = 0;
  v1X = v1Y = v1Z = v1U = v1V = v1W = 0;
  v1Px = v1Py = v1Pz = 0;
  v1Sec.clear();
}
float PHcalTB06Info::eta ( void  ) const [inline]

Definition at line 64 of file PHcalTB06Info.h.

References etaBeam.

{return etaBeam;}
int PHcalTB06Info::evNum ( ) const [inline]

Definition at line 78 of file PHcalTB06Info.h.

References v1EvNum.

Referenced by setVtxPrim().

{return v1EvNum;}
float PHcalTB06Info::initE ( ) const [inline]

Definition at line 63 of file PHcalTB06Info.h.

References eBeam.

{return eBeam;}
int PHcalTB06Info::partID ( ) const [inline]

Definition at line 62 of file PHcalTB06Info.h.

References idBeam.

{return idBeam;}
float PHcalTB06Info::phi ( void  ) const [inline]

Definition at line 65 of file PHcalTB06Info.h.

References phiBeam.

{return phiBeam;}
int PHcalTB06Info::primary ( ) const [inline]

Definition at line 61 of file PHcalTB06Info.h.

References nPrimary.

Referenced by setPrimary().

{return nPrimary;}
void PHcalTB06Info::saveHit ( unsigned int  det,
double  eta,
double  phi,
double  e,
double  t 
)

Definition at line 96 of file PHcalTB06Info.cc.

References PHcalTB06Info::Hit::e, PHcalTB06Info::Hit::eta, hit, hits, PHcalTB06Info::Hit::id, LogDebug, PHcalTB06Info::Hit::phi, and PHcalTB06Info::Hit::t.

Referenced by HcalTB06Analysis::fillEvent().

                                      {

  int nh = hit;
  hit++;
  PHcalTB06Info::Hit newHit;
  newHit.id  = id;
  newHit.eta = (float)(eta);
  newHit.phi = (float)(phi);
  newHit.e   = (float)(e);
  newHit.t   = (float)(t);
  hits.push_back(newHit);
  LogDebug("SimHCalData") << "PHcalTB06Info::saveHit " << hit << " ID 0x" 
                          << std::hex << hits[nh].id << std::dec << " Eta " 
                          << hits[nh].eta << " Phi " << hits[nh].phi 
                          << " E " << hits[nh].e << " t " << hits[nh].t;
}
void PHcalTB06Info::setEdep ( double  simtot,
double  sime,
double  simh 
)

Definition at line 86 of file PHcalTB06Info.cc.

References LogDebug, simEEc, simEHc, and simEtot.

Referenced by HcalTB06Analysis::fillEvent().

                                                                   {

  simEtot = (float)simtot;
  simEEc  = (float)sime;
  simEHc  = (float)simh;

  LogDebug("SimHCalData") << "PHcalTB06Info::setEdep: simEtot " << simEtot 
                          << " simEEc " << simEEc << " simEHc " << simEHc;
}
void PHcalTB06Info::setPrimary ( int  primary,
int  id,
double  energy,
double  eta,
double  phi 
)

Definition at line 73 of file PHcalTB06Info.cc.

References eBeam, etaBeam, idBeam, LogDebug, nPrimary, phiBeam, and primary().

Referenced by HcalTB06Analysis::fillEvent().

                                            {

  nPrimary = primary;
  idBeam   = id;
  eBeam    = (float)(energy);
  etaBeam  = (float)(etav);
  phiBeam  = (float)(phiv);
  LogDebug("SimHCalData") << "PHcalTB06Info::setPrimary: nPrimary " << nPrimary
                          << " partID " << idBeam << " initE " << eBeam 
                          << " eta " << etaBeam << " phi " << phiBeam;
}
void PHcalTB06Info::setVtxPrim ( int  evNum,
int  type,
double  x,
double  y,
double  z,
double  u,
double  v,
double  w,
double  px,
double  py,
double  pz 
)

Definition at line 114 of file PHcalTB06Info.cc.

References evNum(), LogDebug, alignCSCRings::r, mathSSE::sqrt(), v1EvNum, v1Px, v1Py, v1Pz, v1R, v1Type, v1U, v1V, v1W, v1X, v1Y, and v1Z.

Referenced by HcalTB06Analysis::fillEvent().

                                                                {

  v1EvNum = evNum;
  v1Type  = type;
  double r= sqrt(x*x+y*y+z*z);
  v1X     = (float)(x);
  v1Y     = (float)(y);
  v1Z     = (float)(z);
  v1R     = (float)(r);
  v1Px    = (float)(px);
  v1Py    = (float)(py);
  v1Pz    = (float)(pz);
  v1U     = (float)(u);
  v1V     = (float)(v);
  v1W     = (float)(w);
  LogDebug("SimHCalData") << "PHcalTB06Info::setVtxPrim: EvNum " << v1EvNum 
                          << " Type " << v1Type << " X/Y/Z/R " << v1X << "/" 
                          << v1Y << "/" << v1Z << "/" << v1R << " Px/Py/Pz " 
                          << v1Px << "/" << v1Py << "/" << v1Pz << " U/V/W "
                          << v1U << "/" << v1V << "/" << v1W;
}
void PHcalTB06Info::setVtxSec ( int  id,
int  pdg,
double  px,
double  py,
double  pz,
double  ek 
)

Definition at line 138 of file PHcalTB06Info.cc.

References PHcalTB06Info::Vtx::eKin, LogDebug, BeamSpotFilterParameters_cfi::newVtx, PHcalTB06Info::Vtx::partID, PHcalTB06Info::Vtx::px, PHcalTB06Info::Vtx::py, PHcalTB06Info::Vtx::pz, PHcalTB06Info::Vtx::trackID, v1Nsec, and v1Sec.

Referenced by HcalTB06Analysis::fillEvent().

                                         {

  int ns = v1Nsec;
  v1Nsec++;
  PHcalTB06Info::Vtx newVtx;
  newVtx.trackID = id;
  newVtx.partID  = pdg;
  newVtx.px      = (float)(px);
  newVtx.py      = (float)(py);
  newVtx.pz      = (float)(pz);
  newVtx.eKin    = (float)(ek);
  v1Sec.push_back(newVtx);
  LogDebug("SimHCalData") << "PHcalTB06Info::setVtxSec " << v1Nsec << " ID " 
                          << v1Sec[ns].trackID << " PDG Code " 
                          << v1Sec[ns].partID << " Px/Py/Pz/Ek " 
                          << v1Sec[ns].px << "/" << v1Sec[ns].py << "/" 
                          << v1Sec[ns].pz << "/" << v1Sec[ns].eKin;
}
float PHcalTB06Info::simEcE ( ) const [inline]

Definition at line 67 of file PHcalTB06Info.h.

References simEEc.

{return simEEc;}
float PHcalTB06Info::simEtotal ( ) const [inline]

Definition at line 66 of file PHcalTB06Info.h.

References simEtot.

{return simEtot;}
float PHcalTB06Info::simHcE ( ) const [inline]

Definition at line 68 of file PHcalTB06Info.h.

References simEHc.

{return simEHc;}
Hit PHcalTB06Info::simHit ( unsigned int  i) const [inline]

Definition at line 71 of file PHcalTB06Info.h.

References hits, and i.

{return hits[i];}
float PHcalTB06Info::simHitE ( unsigned int  i) const [inline]

Definition at line 75 of file PHcalTB06Info.h.

References hits, and i.

{return hits[i].e;}
float PHcalTB06Info::simHitEta ( unsigned int  i) const [inline]

Definition at line 73 of file PHcalTB06Info.h.

References hits, and i.

{return hits[i].eta;}
unsigned int PHcalTB06Info::simHitID ( unsigned int  i) const [inline]

Definition at line 72 of file PHcalTB06Info.h.

References hits, and i.

{return hits[i].id;}
float PHcalTB06Info::simHitPhi ( unsigned int  i) const [inline]

Definition at line 74 of file PHcalTB06Info.h.

References hits, and i.

{return hits[i].phi;}
HitVector PHcalTB06Info::simHits ( ) const [inline]

Definition at line 70 of file PHcalTB06Info.h.

References hits.

{return hits;}
float PHcalTB06Info::simHitT ( unsigned int  i) const [inline]

Definition at line 76 of file PHcalTB06Info.h.

References hits, and i.

{return hits[i].t;}
int PHcalTB06Info::vtxPartID ( unsigned int  i) const [inline]

Definition at line 94 of file PHcalTB06Info.h.

References i, and v1Sec.

{return v1Sec[i].partID;}
float PHcalTB06Info::vtxPrimPx ( ) const [inline]

Definition at line 87 of file PHcalTB06Info.h.

References v1Px.

{return v1Px;}
float PHcalTB06Info::vtxPrimPy ( ) const [inline]

Definition at line 88 of file PHcalTB06Info.h.

References v1Py.

{return v1Py;}
float PHcalTB06Info::vtxPrimPz ( ) const [inline]

Definition at line 89 of file PHcalTB06Info.h.

References v1Pz.

{return v1Pz;}
float PHcalTB06Info::vtxPrimR ( ) const [inline]

Definition at line 83 of file PHcalTB06Info.h.

References v1R.

{return v1R;}
float PHcalTB06Info::vtxPrimU ( ) const [inline]

Definition at line 84 of file PHcalTB06Info.h.

References v1U.

{return v1U;}
float PHcalTB06Info::vtxPrimV ( ) const [inline]

Definition at line 85 of file PHcalTB06Info.h.

References v1V.

{return v1V;}
float PHcalTB06Info::vtxPrimW ( ) const [inline]

Definition at line 86 of file PHcalTB06Info.h.

References v1W.

{return v1W;}
float PHcalTB06Info::vtxPrimX ( ) const [inline]

Definition at line 80 of file PHcalTB06Info.h.

References v1X.

{return v1X;}
float PHcalTB06Info::vtxPrimY ( ) const [inline]

Definition at line 81 of file PHcalTB06Info.h.

References v1Y.

{return v1Y;}
float PHcalTB06Info::vtxPrimZ ( ) const [inline]

Definition at line 82 of file PHcalTB06Info.h.

References v1Z.

{return v1Z;}
int PHcalTB06Info::vtxSec ( ) const [inline]

Definition at line 90 of file PHcalTB06Info.h.

References v1Nsec.

{return v1Nsec;}
float PHcalTB06Info::vtxSecEKin ( unsigned int  i) const [inline]

Definition at line 98 of file PHcalTB06Info.h.

References i, and v1Sec.

{return v1Sec[i].eKin;}
VtxVector PHcalTB06Info::vtxSecondaries ( ) const [inline]

Definition at line 91 of file PHcalTB06Info.h.

References v1Sec.

{return v1Sec;}
Vtx PHcalTB06Info::vtxSecondary ( unsigned int  i) const [inline]

Definition at line 92 of file PHcalTB06Info.h.

References i, and v1Sec.

{return v1Sec[i];}
float PHcalTB06Info::vtxSecPx ( unsigned int  i) const [inline]

Definition at line 95 of file PHcalTB06Info.h.

References i, and v1Sec.

{return v1Sec[i].px;}
float PHcalTB06Info::vtxSecPy ( unsigned int  i) const [inline]

Definition at line 96 of file PHcalTB06Info.h.

References i, and v1Sec.

{return v1Sec[i].py;}
float PHcalTB06Info::vtxSecPz ( unsigned int  i) const [inline]

Definition at line 97 of file PHcalTB06Info.h.

References i, and v1Sec.

{return v1Sec[i].pz;}
int PHcalTB06Info::vtxTrackID ( unsigned int  i) const [inline]

Definition at line 93 of file PHcalTB06Info.h.

References i, and v1Sec.

{return v1Sec[i].trackID;}
int PHcalTB06Info::vtxType ( ) const [inline]

Definition at line 79 of file PHcalTB06Info.h.

References v1Type.

{return v1Type;}

Member Data Documentation

float PHcalTB06Info::digEEc [private]

Definition at line 125 of file PHcalTB06Info.h.

float PHcalTB06Info::digEHc [private]

Definition at line 125 of file PHcalTB06Info.h.

float PHcalTB06Info::digEtot [private]

Definition at line 125 of file PHcalTB06Info.h.

float PHcalTB06Info::eBeam [private]

Definition at line 121 of file PHcalTB06Info.h.

Referenced by clear(), initE(), and setPrimary().

float PHcalTB06Info::etaBeam [private]

Definition at line 121 of file PHcalTB06Info.h.

Referenced by clear(), eta(), and setPrimary().

int PHcalTB06Info::hit [private]

Definition at line 128 of file PHcalTB06Info.h.

Referenced by saveHit().

int PHcalTB06Info::idBeam [private]

Definition at line 120 of file PHcalTB06Info.h.

Referenced by clear(), partID(), and setPrimary().

int PHcalTB06Info::nPrimary [private]

Definition at line 120 of file PHcalTB06Info.h.

Referenced by clear(), primary(), and setPrimary().

float PHcalTB06Info::phiBeam [private]

Definition at line 121 of file PHcalTB06Info.h.

Referenced by clear(), phi(), and setPrimary().

float PHcalTB06Info::simEEc [private]

Definition at line 124 of file PHcalTB06Info.h.

Referenced by clear(), setEdep(), and simEcE().

float PHcalTB06Info::simEHc [private]

Definition at line 124 of file PHcalTB06Info.h.

Referenced by clear(), setEdep(), and simHcE().

float PHcalTB06Info::simEtot [private]

Definition at line 124 of file PHcalTB06Info.h.

Referenced by clear(), setEdep(), and simEtotal().

int PHcalTB06Info::v1EvNum [private]

Definition at line 132 of file PHcalTB06Info.h.

Referenced by clear(), evNum(), and setVtxPrim().

int PHcalTB06Info::v1Nsec [private]

Definition at line 132 of file PHcalTB06Info.h.

Referenced by clear(), setVtxSec(), and vtxSec().

float PHcalTB06Info::v1Px [private]

Definition at line 134 of file PHcalTB06Info.h.

Referenced by clear(), setVtxPrim(), and vtxPrimPx().

float PHcalTB06Info::v1Py [private]

Definition at line 134 of file PHcalTB06Info.h.

Referenced by clear(), setVtxPrim(), and vtxPrimPy().

float PHcalTB06Info::v1Pz [private]

Definition at line 134 of file PHcalTB06Info.h.

Referenced by clear(), setVtxPrim(), and vtxPrimPz().

float PHcalTB06Info::v1R [private]

Definition at line 133 of file PHcalTB06Info.h.

Referenced by setVtxPrim(), and vtxPrimR().

int PHcalTB06Info::v1Type [private]

Definition at line 132 of file PHcalTB06Info.h.

Referenced by clear(), setVtxPrim(), and vtxType().

float PHcalTB06Info::v1U [private]

Definition at line 133 of file PHcalTB06Info.h.

Referenced by clear(), setVtxPrim(), and vtxPrimU().

float PHcalTB06Info::v1V [private]

Definition at line 133 of file PHcalTB06Info.h.

Referenced by clear(), setVtxPrim(), and vtxPrimV().

float PHcalTB06Info::v1W [private]

Definition at line 133 of file PHcalTB06Info.h.

Referenced by clear(), setVtxPrim(), and vtxPrimW().

float PHcalTB06Info::v1X [private]

Definition at line 133 of file PHcalTB06Info.h.

Referenced by clear(), setVtxPrim(), and vtxPrimX().

float PHcalTB06Info::v1Y [private]

Definition at line 133 of file PHcalTB06Info.h.

Referenced by clear(), setVtxPrim(), and vtxPrimY().

float PHcalTB06Info::v1Z [private]

Definition at line 133 of file PHcalTB06Info.h.

Referenced by clear(), setVtxPrim(), and vtxPrimZ().