CMS 3D CMS Logo

TkBsCandidate.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: DataFormats/L1TCorrelator
4 // Class : TkBsCandidate
5 //
6 
10 #include <cmath>
11 
12 using namespace l1t;
13 
16  : L1Candidate(p4), phiCandList_{cand1, cand2} {}
17 
18 // deltaR between the Phi pair
19 double TkBsCandidate::dRPhiPair() const {
20  const LorentzVector& lva = phiCandidate(0).p4();
21  const LorentzVector& lvb = phiCandidate(1).p4();
22  return reco::deltaR(lva, lvb);
23 }
24 // position difference between track pair
25 double TkBsCandidate::dxyPhiPair() const {
26  const TkPhiCandidate& phia = phiCandidate(0);
27  const TkPhiCandidate& phib = phiCandidate(1);
28  return std::sqrt(std::pow(phia.vx() - phib.vx(), 2) + std::pow(phia.vy() - phib.vy(), 2));
29 }
30 double TkBsCandidate::dzPhiPair() const { return (phiCandidate(0).vz() - phiCandidate(1).vz()); }
l1t::TkPhiCandidate
Definition: TkPhiCandidate.h:18
l1t::TkBsCandidate::dxyPhiPair
double dxyPhiPair() const
Definition: TkBsCandidate.cc:25
reco::LeafCandidate::vz
double vz() const override
z coordinate of vertex position
Definition: LeafCandidate.h:171
deltaR.h
l1t::L1Candidate
Definition: L1Candidate.h:15
l1t::TkBsCandidate::phiCandidate
const TkPhiCandidate & phiCandidate(size_t i) const
Definition: TkBsCandidate.h:25
mathSSE::sqrt
T sqrt(T t)
Definition: SSEVec.h:19
l1t::TkPhiCandidate::vx
double vx() const override
x coordinate of vertex position
Definition: TkPhiCandidate.cc:40
TkBsCandidate.h
l1t
delete x;
Definition: CaloConfig.h:22
reco::LeafCandidate::p4
const LorentzVector & p4() const final
four-momentum Lorentz vector
Definition: LeafCandidate.h:114
p4
double p4[4]
Definition: TauolaWrapper.h:92
l1t::TkPhiCandidate::vy
double vy() const override
y coordinate of vertex position
Definition: TkPhiCandidate.cc:41
l1t::TkBsCandidate::dRPhiPair
double dRPhiPair() const
Definition: TkBsCandidate.cc:19
l1t::TkBsCandidate::TkBsCandidate
TkBsCandidate()
Definition: TkBsCandidate.cc:14
l1t::TkBsCandidate::dzPhiPair
double dzPhiPair() const
Definition: TkBsCandidate.cc:30
reco::deltaR
constexpr auto deltaR(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
Definition: deltaR.h:30
funct::pow
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:30
reco::Candidate::LorentzVector
math::XYZTLorentzVector LorentzVector
Lorentz vector.
Definition: Candidate.h:36
TkPhiCandidate.h