CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
l1tVertexFinder::Vertex Class Reference

#include <Vertex.h>

Public Member Functions

void computeParameters ()
 Compute vertex parameters. More...
 
void insert (TP &tp)
 Assign TP to this vertex. More...
 
unsigned int numTracks () const
 Number of tracks originating from this vertex. More...
 
double pT () const
 Sum of fitted tracks transverse momentum [GeV]. More...
 
void reset ()
 Reset/initialize all of the member data. More...
 
const std::vector< TP > & tracks () const
 Tracking Particles in vertex. More...
 
 Vertex ()
 
 Vertex (double vz)
 
double vz () const
 Vertex z position [cm]. More...
 
double z0 () const
 Vertex z0 position [cm]. More...
 
double z0width () const
 Vertex z0 width [cm]. More...
 
 ~Vertex ()
 

Private Attributes

double pT_
 
std::vector< TPtracks_
 
double vz_
 
double z0_
 
double z0width_
 

Detailed Description

Definition at line 10 of file Vertex.h.

Constructor & Destructor Documentation

◆ Vertex() [1/2]

l1tVertexFinder::Vertex::Vertex ( )
inline

Definition at line 13 of file Vertex.h.

13 { Vertex(-999.); }

References Vertex().

Referenced by Vertex().

◆ Vertex() [2/2]

l1tVertexFinder::Vertex::Vertex ( double  vz)
inline

Definition at line 15 of file Vertex.h.

15  : vz_(vz) {
16  z0_ = -999.;
17  z0width_ = -999.;
18  pT_ = -999.;
19  }

References pT_, z0_, and z0width_.

◆ ~Vertex()

l1tVertexFinder::Vertex::~Vertex ( )
inline

Definition at line 21 of file Vertex.h.

21 {}

Member Function Documentation

◆ computeParameters()

void l1tVertexFinder::Vertex::computeParameters ( )

Compute vertex parameters.

Definition at line 6 of file Vertex.cc.

6  {
7  pT_ = 0.;
8  z0_ = 0.;
9  float z0square = 0.;
10  for (const TP& track : tracks_) {
11  pT_ += track->pt();
12  z0_ += track->z0();
13  z0square += track->z0() * track->z0();
14  }
15  z0_ /= tracks_.size();
16  z0square /= tracks_.size();
17  z0width_ = sqrt(std::abs(z0_ * z0_ - z0square));
18  }

References funct::abs(), pT_, mathSSE::sqrt(), HLT_FULL_cff::track, tracks_, z0_, and z0width_.

◆ insert()

void l1tVertexFinder::Vertex::insert ( TP tp)
inline

Assign TP to this vertex.

Definition at line 28 of file Vertex.h.

28 { tracks_.push_back(tp); }

References cmsswSequenceInfo::tp, and tracks_.

Referenced by l1tVertexFinder::VertexFinder::GapClustering().

◆ numTracks()

unsigned int l1tVertexFinder::Vertex::numTracks ( ) const
inline

Number of tracks originating from this vertex.

Definition at line 26 of file Vertex.h.

26 { return tracks_.size(); }

References tracks_.

Referenced by l1tVertexFinder::VertexFinder::GapClustering().

◆ pT()

double l1tVertexFinder::Vertex::pT ( ) const
inline

Sum of fitted tracks transverse momentum [GeV].

Definition at line 32 of file Vertex.h.

32 { return pT_; }

References pT_.

Referenced by l1tVertexFinder::InputData::SortVertexByPt::operator()().

◆ reset()

void l1tVertexFinder::Vertex::reset ( )

Reset/initialize all of the member data.

◆ tracks()

const std::vector<TP>& l1tVertexFinder::Vertex::tracks ( void  ) const
inline

Tracking Particles in vertex.

Definition at line 24 of file Vertex.h.

24 { return tracks_; }

References tracks_.

◆ vz()

double l1tVertexFinder::Vertex::vz ( ) const
inline

Vertex z position [cm].

Definition at line 38 of file Vertex.h.

38 { return vz_; }

References vz_.

Referenced by l1tVertexFinder::VertexNTupler::analyze().

◆ z0()

double l1tVertexFinder::Vertex::z0 ( ) const
inline

Vertex z0 position [cm].

Definition at line 34 of file Vertex.h.

34 { return z0_; }

References z0_.

Referenced by l1tVertexFinder::InputData::SortVertexByZ0::operator()().

◆ z0width()

double l1tVertexFinder::Vertex::z0width ( ) const
inline

Vertex z0 width [cm].

Definition at line 36 of file Vertex.h.

36 { return z0width_; }

References z0width_.

Member Data Documentation

◆ pT_

double l1tVertexFinder::Vertex::pT_
private

Definition at line 46 of file Vertex.h.

Referenced by computeParameters(), pT(), and Vertex().

◆ tracks_

std::vector<TP> l1tVertexFinder::Vertex::tracks_
private

Definition at line 48 of file Vertex.h.

Referenced by computeParameters(), insert(), numTracks(), and tracks().

◆ vz_

double l1tVertexFinder::Vertex::vz_
private

Definition at line 43 of file Vertex.h.

Referenced by vz().

◆ z0_

double l1tVertexFinder::Vertex::z0_
private

Definition at line 44 of file Vertex.h.

Referenced by computeParameters(), Vertex(), and z0().

◆ z0width_

double l1tVertexFinder::Vertex::z0width_
private

Definition at line 45 of file Vertex.h.

Referenced by computeParameters(), Vertex(), and z0width().

HLT_FULL_cff.track
track
Definition: HLT_FULL_cff.py:11724
l1tVertexFinder::Vertex::Vertex
Vertex()
Definition: Vertex.h:13
l1tVertexFinder::Vertex::z0_
double z0_
Definition: Vertex.h:44
DigiToRawDM_cff.TP
TP
Definition: DigiToRawDM_cff.py:51
mathSSE::sqrt
T sqrt(T t)
Definition: SSEVec.h:19
cmsswSequenceInfo.tp
tp
Definition: cmsswSequenceInfo.py:17
l1tVertexFinder::Vertex::vz
double vz() const
Vertex z position [cm].
Definition: Vertex.h:38
l1tVertexFinder::Vertex::tracks_
std::vector< TP > tracks_
Definition: Vertex.h:48
l1tVertexFinder::Vertex::pT_
double pT_
Definition: Vertex.h:46
funct::abs
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
l1tVertexFinder::Vertex::z0width_
double z0width_
Definition: Vertex.h:45
l1tVertexFinder::Vertex::vz_
double vz_
Definition: Vertex.h:43