ATLAS Offline Software
Public Member Functions | List of all members
Analysis::TauPi0Candidate Class Reference

#include <TauPi0Candidate.h>

Collaboration diagram for Analysis::TauPi0Candidate:

Public Member Functions

 TauPi0Candidate ()
 default constructor More...
 
 TauPi0Candidate (const TauPi0Candidate &rhs)
 copy constructor More...
 
virtual ~TauPi0Candidate ()
 destructor (virtual) More...
 
TauPi0Candidateoperator= (const TauPi0Candidate &rhs)
 assignment operator More...
 
bool operator== (const TauPi0Candidate &rhs) const
 Equality operator. More...
 
bool operator!= (const TauPi0Candidate &rhs) const
 Inequality operator. More...
 
void dump ()
 

Accessors for clusters (copied from TauCommonDetails)

std::vector< TauPi0Cluster * > m_pi0ClusterVector
 pi0 cluster vector More...
 
const std::vector< TauPi0Cluster * > & pi0ClusterVec () const
 Get pi0 cluster vector (const) More...
 
std::vector< TauPi0Cluster * > & pi0ClusterVec ()
 Get pi0 cluster vector. More...
 
const TauPi0Clusterpi0Cluster (unsigned int i) const
 Get pi0 cluster Concider using direct access through clusterLinkVec() instead. More...
 
unsigned int nPi0Cluster () const
 Get length of cluster vector Concider using direct access through pi0LinkVec() instead. More...
 
CLHEP::HepLorentzVector hlv () const
 
void addPi0Cluster (TauPi0Cluster *pi0Cluster)
 Add cluster to pi0 cluster vector Concider using direct access through pi0LinkVec() instead. More...
 

Detailed Description

Definition at line 28 of file TauPi0Candidate.h.

Constructor & Destructor Documentation

◆ TauPi0Candidate() [1/2]

Analysis::TauPi0Candidate::TauPi0Candidate ( )

default constructor

Definition at line 14 of file TauPi0Candidate.cxx.

15  {
16  }

◆ TauPi0Candidate() [2/2]

Analysis::TauPi0Candidate::TauPi0Candidate ( const TauPi0Candidate rhs)

copy constructor

Parameters
rhsTauPi0Candidate instance to assign from

Definition at line 19 of file TauPi0Candidate.cxx.

19  :
20  m_pi0ClusterVector(rhs.m_pi0ClusterVector)
21  {
22  }

◆ ~TauPi0Candidate()

Analysis::TauPi0Candidate::~TauPi0Candidate ( )
virtual

destructor (virtual)

Definition at line 55 of file TauPi0Candidate.cxx.

56  {
57  }

Member Function Documentation

◆ addPi0Cluster()

void Analysis::TauPi0Candidate::addPi0Cluster ( TauPi0Cluster pi0Cluster)

Add cluster to pi0 cluster vector Concider using direct access through pi0LinkVec() instead.

Parameters
pi0cluster
contcluster container

◆ dump()

void Analysis::TauPi0Candidate::dump ( )

Definition at line 60 of file TauPi0Candidate.cxx.

61  {
62  std::cout << "in TauPi0Candidate::dump()" << std::endl;
63  std::cout << "-------------------------" <<std::endl;
64  std::cout << "number of Pi0Clusters = " << this->nPi0Cluster() << std::endl;
65  std::cout.precision(6);
66 
67  for(int i=0; i < (int)this->nPi0Cluster(); ++i) {
68  std::cout << "4 mom of cluster no " << i << ": pt = " << this->pi0Cluster(i)->cluster()->pt() <<
69  "\t eta = " << this->pi0Cluster(i)->cluster()->eta() <<
70  "\t phi = " << this->pi0Cluster(i)->cluster()->phi() <<
71  "\t m = " << this->pi0Cluster(i)->cluster()->m() <<
72  "\t E = " << this->pi0Cluster(i)->cluster()->e() << std::endl;
73 
74  }
75  std::cout << "4 mom of candidate: pt = " << std::sqrt(this->hlv().px()*this->hlv().px()+this->hlv().py()*this->hlv().py()) <<
76  "\t eta = " << this->hlv().eta() <<
77  "\t phi = " << this->hlv().phi() <<
78  "\t m = " << this->hlv().m() <<
79  "\t E = " << this->hlv().e() << std::endl;
80  std::cout << std::endl << std::endl;
81  std::cout << "-------------------------" << std::endl;
82  }

◆ hlv()

CLHEP::HepLorentzVector Analysis::TauPi0Candidate::hlv ( ) const

◆ nPi0Cluster()

unsigned int Analysis::TauPi0Candidate::nPi0Cluster ( ) const

Get length of cluster vector Concider using direct access through pi0LinkVec() instead.

Returns
length

◆ operator!=()

Inequality operator.

Parameters
rhsTauPi0Candidate instance to compare to
Returns
!operator==

Definition at line 46 of file TauPi0Candidate.cxx.

46  {
47  if(m_pi0ClusterVector.size()!=rhs.m_pi0ClusterVector.size()) return true;
48  for(unsigned iPi0Cluster=0; iPi0Cluster!=m_pi0ClusterVector.size();++iPi0Cluster){
49  if (*(m_pi0ClusterVector.at(iPi0Cluster))!=*(rhs.m_pi0ClusterVector.at(iPi0Cluster))) return true;
50  }
51  return false;
52  }

◆ operator=()

TauPi0Candidate & Analysis::TauPi0Candidate::operator= ( const TauPi0Candidate rhs)

assignment operator

Parameters
rhsTauPi0Candidate instance to assign from

Definition at line 25 of file TauPi0Candidate.cxx.

26  {
27  if (this!=&rhs){
28  m_pi0ClusterVector = rhs.m_pi0ClusterVector;
29  }
30  return *this;
31  }

◆ operator==()

bool Analysis::TauPi0Candidate::operator== ( const TauPi0Candidate rhs) const

Equality operator.

Parameters
rhsright hand side TauPi0Candidate instance to compare
Returns
true if equal, false otherwise

Definition at line 38 of file TauPi0Candidate.cxx.

38  {
39  if(m_pi0ClusterVector.size()!=rhs.m_pi0ClusterVector.size()) return false;
40  for(unsigned iPi0Cluster=0; iPi0Cluster!=m_pi0ClusterVector.size();++iPi0Cluster){
41  if (*(m_pi0ClusterVector.at(iPi0Cluster))!=*(rhs.m_pi0ClusterVector.at(iPi0Cluster))) return false;
42  }
43  return true;
44  }

◆ pi0Cluster()

const TauPi0Cluster* Analysis::TauPi0Candidate::pi0Cluster ( unsigned int  i) const

Get pi0 cluster Concider using direct access through clusterLinkVec() instead.

Parameters
iindex
Returns
cluster

◆ pi0ClusterVec() [1/2]

std::vector<TauPi0Cluster*>& Analysis::TauPi0Candidate::pi0ClusterVec ( )

Get pi0 cluster vector.

Returns
pi0 clusters vector

◆ pi0ClusterVec() [2/2]

const std::vector<TauPi0Cluster*>& Analysis::TauPi0Candidate::pi0ClusterVec ( ) const

Get pi0 cluster vector (const)

Returns
(const) pi0 clusters vector

Member Data Documentation

◆ m_pi0ClusterVector

std::vector<TauPi0Cluster*> Analysis::TauPi0Candidate::m_pi0ClusterVector
private

pi0 cluster vector

Definition at line 104 of file TauPi0Candidate.h.


The documentation for this class was generated from the following files:
P4EEtaPhiMBase::pt
virtual double pt() const
transverse momentum
Definition: P4EEtaPhiMBase.cxx:101
test_pyathena.px
px
Definition: test_pyathena.py:18
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
Analysis::TauPi0Candidate::m_pi0ClusterVector
std::vector< TauPi0Cluster * > m_pi0ClusterVector
pi0 cluster vector
Definition: TauPi0Candidate.h:104
Analysis::TauPi0Candidate::hlv
CLHEP::HepLorentzVector hlv() const
Analysis::TauPi0Cluster::cluster
const CaloCluster * cluster() const
Get cluster Consider using direct access through clusterLink() instead.
lumiFormat.i
int i
Definition: lumiFormat.py:85
Amg::py
@ py
Definition: GeoPrimitives.h:39
Analysis::TauPi0Candidate::pi0Cluster
const TauPi0Cluster * pi0Cluster(unsigned int i) const
Get pi0 cluster Concider using direct access through clusterLinkVec() instead.
Analysis::TauPi0Candidate::nPi0Cluster
unsigned int nPi0Cluster() const
Get length of cluster vector Concider using direct access through pi0LinkVec() instead.
CaloCluster::eta
virtual double eta() const
Retrieve eta independent of signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:755
CaloCluster::e
virtual double e() const
Retrieve energy independent of signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:753
CaloCluster::m
virtual double m() const
Retrieve mass independent of signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:764
CaloCluster::phi
virtual double phi() const
Retrieve phi independent of signal state.
Definition: Calorimeter/CaloEvent/CaloEvent/CaloCluster.h:759