CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
trklet::L1SimTrack Class Reference

#include <L1SimTrack.h>

Public Member Functions

int charge () const
 
double d0 () const
 
double dxy () const
 
double eta () const
 
int eventid () const
 
 L1SimTrack ()
 
 L1SimTrack (int eventid, int trackid, int type, double pt, double eta, double phi, double vx, double vy, double vz)
 
double phi () const
 
double pt () const
 
int trackid () const
 
int type () const
 
double vx () const
 
double vy () const
 
double vz () const
 
void write (std::ofstream &out)
 
void write (std::ostream &out)
 
 ~L1SimTrack ()=default
 

Private Attributes

double eta_
 
int eventid_
 
double phi_
 
double pt_
 
int trackid_
 
int type_
 
double vx_
 
double vy_
 
double vz_
 

Detailed Description

Definition at line 14 of file L1SimTrack.h.

Constructor & Destructor Documentation

◆ L1SimTrack() [1/2]

L1SimTrack::L1SimTrack ( )

Definition at line 7 of file L1SimTrack.cc.

7  {
8  eventid_ = -1;
9  trackid_ = -1;
10 }

◆ L1SimTrack() [2/2]

L1SimTrack::L1SimTrack ( int  eventid,
int  trackid,
int  type,
double  pt,
double  eta,
double  phi,
double  vx,
double  vy,
double  vz 
)

Definition at line 12 of file L1SimTrack.cc.

13  {
14  eventid_ = eventid;
15  trackid_ = trackid;
16  type_ = type;
17  pt_ = pt;
18  eta_ = eta;
19  phi_ = phi;
20  vx_ = vx;
21  vy_ = vy;
22  vz_ = vz;
23 }

References PVValHelper::eta, and DiDispStaMuonMonitor_cfi::pt.

◆ ~L1SimTrack()

trklet::L1SimTrack::~L1SimTrack ( )
default

Member Function Documentation

◆ charge()

int trklet::L1SimTrack::charge ( void  ) const
inline

Definition at line 34 of file L1SimTrack.h.

34  {
35  if (type_ == 11 || type_ == 13 || type_ == -211 || type_ == -321 || type_ == -2212)
36  return -1;
37  return 1;
38  }

References type_.

Referenced by trklet::Stub::Stub().

◆ d0()

double trklet::L1SimTrack::d0 ( ) const
inline

Definition at line 33 of file L1SimTrack.h.

33 { return -dxy(); }

References dxy().

◆ dxy()

double trklet::L1SimTrack::dxy ( ) const
inline

Definition at line 32 of file L1SimTrack.h.

32 { return -vx() * sin(phi()) + vy() * cos(phi()); }

References funct::cos(), phi(), funct::sin(), vx(), and vy().

Referenced by Electron.Electron::cutBasedId(), d0(), and ntupleDataFormat.Track::dxyPull().

◆ eta()

double trklet::L1SimTrack::eta ( void  ) const
inline

Definition at line 27 of file L1SimTrack.h.

27 { return eta_; }

References eta_.

Referenced by Particle.Particle::__str__(), trklet::TrackletEventProcessor::event(), Jet.Jet::jetID(), and Jet.Jet::puJetId().

◆ eventid()

int trklet::L1SimTrack::eventid ( ) const
inline

Definition at line 23 of file L1SimTrack.h.

23 { return eventid_; }

References eventid_.

◆ phi()

double trklet::L1SimTrack::phi ( void  ) const
inline

Definition at line 28 of file L1SimTrack.h.

28 { return phi_; }

References phi_.

Referenced by Particle.Particle::__str__(), dxy(), and ntupleDataFormat.Track::phiPull().

◆ pt()

double trklet::L1SimTrack::pt ( ) const
inline

◆ trackid()

int trklet::L1SimTrack::trackid ( ) const
inline

Definition at line 24 of file L1SimTrack.h.

24 { return trackid_; }

References trackid_.

Referenced by trklet::TrackletEventProcessor::event(), and trklet::Stub::Stub().

◆ type()

int trklet::L1SimTrack::type ( ) const
inline

Definition at line 25 of file L1SimTrack.h.

25 { return type_; }

References type_.

Referenced by trklet::TrackletEventProcessor::event().

◆ vx()

double trklet::L1SimTrack::vx ( ) const
inline

Definition at line 29 of file L1SimTrack.h.

29 { return vx_; }

References vx_.

Referenced by dxy(), and trklet::TrackletEventProcessor::event().

◆ vy()

double trklet::L1SimTrack::vy ( ) const
inline

Definition at line 30 of file L1SimTrack.h.

30 { return vy_; }

References vy_.

Referenced by dxy(), and trklet::TrackletEventProcessor::event().

◆ vz()

double trklet::L1SimTrack::vz ( ) const
inline

Definition at line 31 of file L1SimTrack.h.

31 { return vz_; }

References vz_.

Referenced by trklet::TrackletEventProcessor::event().

◆ write() [1/2]

void L1SimTrack::write ( std::ofstream &  out)

Definition at line 25 of file L1SimTrack.cc.

25  {
26  if (pt_ > -2.0) {
27  out << "SimTrack: " << eventid_ << "\t" << trackid_ << "\t" << type_ << "\t" << pt_ << "\t" << eta_ << "\t" << phi_
28  << "\t" << vx_ << "\t" << vy_ << "\t" << vz_ << "\t" << endl;
29  }
30 }

References MillePedeFileConverter_cfg::out.

◆ write() [2/2]

void trklet::L1SimTrack::write ( std::ostream &  out)

Member Data Documentation

◆ eta_

double trklet::L1SimTrack::eta_
private

Definition at line 45 of file L1SimTrack.h.

Referenced by eta().

◆ eventid_

int trklet::L1SimTrack::eventid_
private

Definition at line 41 of file L1SimTrack.h.

Referenced by eventid().

◆ phi_

double trklet::L1SimTrack::phi_
private

Definition at line 46 of file L1SimTrack.h.

Referenced by phi().

◆ pt_

double trklet::L1SimTrack::pt_
private

Definition at line 44 of file L1SimTrack.h.

Referenced by pt().

◆ trackid_

int trklet::L1SimTrack::trackid_
private

Definition at line 42 of file L1SimTrack.h.

Referenced by trackid().

◆ type_

int trklet::L1SimTrack::type_
private

◆ vx_

double trklet::L1SimTrack::vx_
private

Definition at line 47 of file L1SimTrack.h.

Referenced by vx().

◆ vy_

double trklet::L1SimTrack::vy_
private

Definition at line 48 of file L1SimTrack.h.

Referenced by vy().

◆ vz_

double trklet::L1SimTrack::vz_
private

Definition at line 49 of file L1SimTrack.h.

Referenced by vz().

trklet::L1SimTrack::vy_
double vy_
Definition: L1SimTrack.h:48
trklet::L1SimTrack::vy
double vy() const
Definition: L1SimTrack.h:30
trklet::L1SimTrack::type
int type() const
Definition: L1SimTrack.h:25
trklet::L1SimTrack::type_
int type_
Definition: L1SimTrack.h:43
trklet::L1SimTrack::vz
double vz() const
Definition: L1SimTrack.h:31
trklet::L1SimTrack::eventid_
int eventid_
Definition: L1SimTrack.h:41
trklet::L1SimTrack::vz_
double vz_
Definition: L1SimTrack.h:49
funct::sin
Sin< T >::type sin(const T &t)
Definition: Sin.h:22
trklet::L1SimTrack::trackid
int trackid() const
Definition: L1SimTrack.h:24
trklet::L1SimTrack::eventid
int eventid() const
Definition: L1SimTrack.h:23
funct::cos
Cos< T >::type cos(const T &t)
Definition: Cos.h:22
trklet::L1SimTrack::phi_
double phi_
Definition: L1SimTrack.h:46
trklet::L1SimTrack::dxy
double dxy() const
Definition: L1SimTrack.h:32
trklet::L1SimTrack::eta_
double eta_
Definition: L1SimTrack.h:45
trklet::L1SimTrack::phi
double phi() const
Definition: L1SimTrack.h:28
trklet::L1SimTrack::trackid_
int trackid_
Definition: L1SimTrack.h:42
trklet::L1SimTrack::pt
double pt() const
Definition: L1SimTrack.h:26
trklet::L1SimTrack::eta
double eta() const
Definition: L1SimTrack.h:27
trklet::L1SimTrack::pt_
double pt_
Definition: L1SimTrack.h:44
trklet::L1SimTrack::vx_
double vx_
Definition: L1SimTrack.h:47
MillePedeFileConverter_cfg.out
out
Definition: MillePedeFileConverter_cfg.py:31
trklet::L1SimTrack::vx
double vx() const
Definition: L1SimTrack.h:29