CMS 3D CMS Logo

VertexCompositePtrCandidate.cc
Go to the documentation of this file.
2 
3 using namespace reco;
4 
6  const LorentzVector& p4,
7  const Point& vtx,
8  const CovarianceMatrix& err,
9  double chi2,
10  double ndof,
11  int pdgId,
12  int status,
13  bool integerCharge)
14  : CompositePtrCandidate(q, p4, vtx, pdgId, status, integerCharge), chi2_(chi2), ndof_(ndof), time_(0.) {
16 }
17 
19  const LorentzVector& p4,
20  const Point& vtx,
21  double time,
22  const CovarianceMatrix4D& err,
23  double chi2,
24  double ndof,
25  int pdgId,
26  int status,
27  bool integerCharge)
28  : CompositePtrCandidate(q, p4, vtx, pdgId, status, integerCharge), chi2_(chi2), ndof_(ndof), time_(time) {
30 }
31 
33 
35  return new VertexCompositePtrCandidate(*this);
36 }
37 
39  Error4D temp;
41  err = temp.Sub<Error>(0, 0);
42 }
43 
45  index idx = 0;
46  for (index i = 0; i < dimension4D; ++i)
47  for (index j = 0; j <= i; ++j)
48  err(i, j) = covariance_[idx++];
49 }
50 
52  index idx = 0;
53  for (index i = 0; i < dimension4D; ++i) {
54  for (index j = 0; j <= i; ++j) {
55  if (i == dimension || j == dimension) {
56  covariance_[idx++] = 0.0;
57  } else {
58  covariance_[idx++] = err(i, j);
59  }
60  }
61  }
62 }
63 
65  index idx = 0;
66  for (index i = 0; i < dimension4D; ++i)
67  for (index j = 0; j <= i; ++j)
68  covariance_[idx++] = err(i, j);
69 }
reco::VertexCompositePtrCandidate::covariance_
Double32_t covariance_[size4D]
covariance matrix (4x4) as vector
Definition: VertexCompositePtrCandidate.h:130
reco::VertexCompositePtrCandidate::Error
math::Error< dimension >::type Error
the following functions are implemented to have a more consistent interface with the one of reco::Ver...
Definition: VertexCompositePtrCandidate.h:107
mps_fire.i
i
Definition: mps_fire.py:428
mps_update.status
status
Definition: mps_update.py:69
reco::VertexCompositePtrCandidate::clone
VertexCompositePtrCandidate * clone() const override
returns a clone of the candidate
Definition: VertexCompositePtrCandidate.cc:34
reco::VertexCompositePtrCandidate::CovarianceMatrix4D
math::Error< dimension4D >::type CovarianceMatrix4D
covariance error matrix (3x3)
Definition: VertexCompositePtrCandidate.h:20
reco::Candidate::Charge
int Charge
electric charge type
Definition: Candidate.h:34
CovarianceMatrix
Definition: CovarianceMatrix.h:27
reco
fixed size matrix
Definition: AlignmentAlgorithmBase.h:45
hltPixelTracks_cff.chi2
chi2
Definition: hltPixelTracks_cff.py:25
groupFilesInBlocks.temp
list temp
Definition: groupFilesInBlocks.py:142
reco::VertexCompositePtrCandidate
Definition: VertexCompositePtrCandidate.h:16
ndof
Definition: HIMultiTrackSelector.h:49
reco::VertexCompositePtrCandidate::~VertexCompositePtrCandidate
~VertexCompositePtrCandidate() override
destructor
Definition: VertexCompositePtrCandidate.cc:32
VertexCompositePtrCandidate.h
reco::VertexCompositePtrCandidate::idx
index idx(index i, index j) const
position index
Definition: VertexCompositePtrCandidate.h:134
reco::VertexCompositePtrCandidate::Error4D
math::Error< dimension4D >::type Error4D
Definition: VertexCompositePtrCandidate.h:108
reco::VertexCompositePtrCandidate::dimension4D
Definition: VertexCompositePtrCandidate.h:18
Point
Structure Point Contains parameters of Gaussian fits to DMRs.
Definition: DMRtrends.cc:57
p4
double p4[4]
Definition: TauolaWrapper.h:92
EgammaValidation_cff.pdgId
pdgId
Definition: EgammaValidation_cff.py:118
submitPVResolutionJobs.q
q
Definition: submitPVResolutionJobs.py:84
submitPVResolutionJobs.err
err
Definition: submitPVResolutionJobs.py:85
reco::VertexCompositePtrCandidate::setCovariance
void setCovariance(const CovarianceMatrix &m)
set covariance matrix
Definition: VertexCompositePtrCandidate.cc:51
extraflags_cff.vtx
vtx
Definition: extraflags_cff.py:18
reco::Candidate::index
unsigned int index
index type
Definition: Candidate.h:50
reco::Candidate::dimension
Definition: Candidate.h:44
reco::CompositePtrCandidate
Definition: CompositePtrCandidate.h:17
reco::VertexCompositePtrCandidate::fillVertexCovariance
void fillVertexCovariance(CovarianceMatrix &v) const override
fill SMatrix
Definition: VertexCompositePtrCandidate.cc:38
reco::Candidate::LorentzVector
math::XYZTLorentzVector LorentzVector
Lorentz vector.
Definition: Candidate.h:36
dqmiolumiharvest.j
j
Definition: dqmiolumiharvest.py:66
ntuplemaker.time
time
Definition: ntuplemaker.py:310
reco::VertexCompositePtrCandidate::VertexCompositePtrCandidate
VertexCompositePtrCandidate()
Definition: VertexCompositePtrCandidate.h:24