CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
CTPPSTrkDetector Class Reference

#include <CTPPSTrkDetector.h>

Public Member Functions

void AddHit (unsigned int detID, double x, double y, double z)
 
void clear ()
 
 CTPPSTrkDetector (double detw, double deth, double detin)
 
virtual ~CTPPSTrkDetector ()
 

Public Attributes

const double ppsDetectorHeight_
 
const double ppsDetectorPosition_
 
const double ppsDetectorWidth_
 
std::vector< unsigned int > ppsDetId_
 
int ppsNHits_
 
std::vector< double > ppsX_
 
std::vector< double > ppsY_
 
std::vector< double > ppsZ_
 

Detailed Description

Definition at line 5 of file CTPPSTrkDetector.h.

Constructor & Destructor Documentation

CTPPSTrkDetector::CTPPSTrkDetector ( double  detw,
double  deth,
double  detin 
)

Definition at line 3 of file CTPPSTrkDetector.cc.

References clear().

3  :
const double ppsDetectorPosition_
const double ppsDetectorHeight_
const double ppsDetectorWidth_
virtual CTPPSTrkDetector::~CTPPSTrkDetector ( )
inlinevirtual

Definition at line 8 of file CTPPSTrkDetector.h.

References ppsDetectorWidth_.

8 {};

Member Function Documentation

void CTPPSTrkDetector::AddHit ( unsigned int  detID,
double  x,
double  y,
double  z 
)

Definition at line 5 of file CTPPSTrkDetector.cc.

References ppsDetectorHeight_, ppsDetectorPosition_, ppsDetectorWidth_, ppsDetId_, ppsNHits_, ppsX_, ppsY_, and ppsZ_.

Referenced by clear().

6 {
7 // Detector is in the negative side, but DetectorPosition is a positive number
8  // if (detID >0);
9  if (x>0) return; // The detector is on the negative side
10  if (fabs(x)>ppsDetectorWidth_+ppsDetectorPosition_) return; // hit beyond detector area (W)
11  if (fabs(x)<ppsDetectorPosition_) return; // hit falls below detector area
12  if (fabs(y)>ppsDetectorHeight_*0.5) return; // hit falls beyond detector area (H)
13  ppsDetId_.push_back(detID);ppsX_.push_back(x);ppsY_.push_back(y);ppsZ_.push_back(z);
14  ppsNHits_++;
15 }
const double ppsDetectorPosition_
std::vector< double > ppsX_
std::vector< unsigned int > ppsDetId_
const double ppsDetectorHeight_
std::vector< double > ppsZ_
std::vector< double > ppsY_
const double ppsDetectorWidth_
void CTPPSTrkDetector::clear ( void  )
inline

Member Data Documentation

const double CTPPSTrkDetector::ppsDetectorHeight_

Definition at line 12 of file CTPPSTrkDetector.h.

Referenced by AddHit().

const double CTPPSTrkDetector::ppsDetectorPosition_

Definition at line 13 of file CTPPSTrkDetector.h.

Referenced by AddHit().

const double CTPPSTrkDetector::ppsDetectorWidth_

Definition at line 8 of file CTPPSTrkDetector.h.

Referenced by AddHit(), and ~CTPPSTrkDetector().

std::vector<unsigned int> CTPPSTrkDetector::ppsDetId_

Definition at line 14 of file CTPPSTrkDetector.h.

Referenced by AddHit().

int CTPPSTrkDetector::ppsNHits_
std::vector<double> CTPPSTrkDetector::ppsX_

Definition at line 16 of file CTPPSTrkDetector.h.

Referenced by AddHit(), and CTPPSFastTrackingProducer::SearchTrack().

std::vector<double> CTPPSTrkDetector::ppsY_

Definition at line 17 of file CTPPSTrkDetector.h.

Referenced by AddHit(), and CTPPSFastTrackingProducer::SearchTrack().

std::vector<double> CTPPSTrkDetector::ppsZ_

Definition at line 18 of file CTPPSTrkDetector.h.

Referenced by AddHit().