48 const double &met_phi,
49 const double &met_set) {
83 for (std::vector<SigInputObj>::const_iterator
obj = eventVec.begin();
obj != eventVec.end(); ++
obj) {
84 double et_tmp =
obj->get_energy();
85 double phi_tmp =
obj->get_phi();
86 double sigma_et =
obj->get_sigma_e();
87 double sigma_tan =
obj->get_sigma_tan();
89 double cosphi =
cos(phi_tmp);
90 double sinphi =
sin(phi_tmp);
91 double xval = et_tmp * cosphi;
92 double yval = et_tmp * sinphi;
97 double sigma0_2 = sigma_et * sigma_et;
98 double sigma1_2 = sigma_tan * sigma_tan;
100 v_tot(0, 0) -= sigma0_2 * cosphi * cosphi + sigma1_2 * sinphi * sinphi;
101 v_tot(0, 1) -= cosphi * sinphi * (sigma0_2 - sigma1_2);
102 v_tot(1, 0) -= cosphi * sinphi * (sigma0_2 - sigma1_2);
103 v_tot(1, 1) -= sigma1_2 * cosphi * cosphi + sigma0_2 * sinphi * sinphi;
113 for (std::vector<SigInputObj>::const_iterator
obj = eventVec.begin();
obj != eventVec.end(); ++
obj) {
114 double et_tmp =
obj->get_energy();
115 double phi_tmp =
obj->get_phi();
116 double sigma_et =
obj->get_sigma_e();
117 double sigma_tan =
obj->get_sigma_tan();
119 double cosphi =
cos(phi_tmp);
120 double sinphi =
sin(phi_tmp);
121 double xval = et_tmp * cosphi;
122 double yval = et_tmp * sinphi;
127 double sigma0_2 = sigma_et * sigma_et;
128 double sigma1_2 = sigma_tan * sigma_tan;
130 v_tot(0, 0) += sigma0_2 * cosphi * cosphi + sigma1_2 * sinphi * sinphi;
131 v_tot(0, 1) += cosphi * sinphi * (sigma0_2 - sigma1_2);
132 v_tot(1, 0) += cosphi * sinphi * (sigma0_2 - sigma1_2);
133 v_tot(1, 1) += sigma1_2 * cosphi * cosphi + sigma0_2 * sinphi * sinphi;
148 ROOT::Math::SVector<double, 2> metvec;
157 met_phi = TMath::ATan2(ymet_,
xmet_);
163 if (fabs(det) < 0.000001)
173 double lnSignificance = ROOT::Math::Dot(metvec, (v_tot * metvec));
177 return lnSignificance;
const void addObjects(const std::vector< metsig::SigInputObj > &EventVec)
const double significance(double &met_r, double &met_phi, double &met_set)
ROOT::Math::SMatrix< double, 2 > METCovMatrix
Sin< T >::type sin(const T &t)
const void setSignifMatrix(const reco::METCovMatrix &input, const double &met_r, const double &met_phi, const double &met_set)
reset the signficance matrix (this is the most likely case), so that the vector sum can be continued ...
reco::METCovMatrix signifmatrix_
const void subtractObjects(const std::vector< metsig::SigInputObj > &EventVec)
static std::string const input
Cos< T >::type cos(const T &t)
const void addSignifMatrix(const reco::METCovMatrix &input)