Main Page
Namespaces
Classes
Package Documentation
TrackingTools
GeomPropagators
src
RealQuadEquation.h
Go to the documentation of this file.
1
#ifndef RealQuadEquation_H
2
#define RealQuadEquation_H
3
4
#include <cmath>
5
#include "
FWCore/Utilities/interface/Visibility.h
"
6
11
struct
dso_internal
RealQuadEquation
{
12
13
double
first
;
14
double
second
;
15
bool
hasSolution
;
16
17
RealQuadEquation
(
double
A
,
double
B
,
double
C
) {
18
double
D
= B*B - 4*A*
C
;
19
if
(D<0) hasSolution =
false
;
20
else
{
21
hasSolution =
true
;
22
auto
q
= -0.5*(B + std::copysign(
std::sqrt
(D),B));
23
first =
q
/
A
;
24
second = C/
q
;
25
}
26
}
27
28
};
29
30
#endif
RealQuadEquation::second
double second
Definition:
RealQuadEquation.h:14
RealQuadEquation::RealQuadEquation
RealQuadEquation(double A, double B, double C)
Definition:
RealQuadEquation.h:17
RealQuadEquation::hasSolution
bool hasSolution
Definition:
RealQuadEquation.h:15
double_binary
Definition:
DDStreamer.cc:241
Visibility.h
patCaloMETCorrections_cff.C
C
Definition:
patCaloMETCorrections_cff.py:45
mathSSE::sqrt
T sqrt(T t)
Definition:
SSEVec.h:18
funct::D
DecomposeProduct< arg, typename Div::arg > D
Definition:
Factorize.h:150
dso_internal
#define dso_internal
patCaloMETCorrections_cff.A
A
Definition:
patCaloMETCorrections_cff.py:43
lumiQueryAPI.q
q
Definition:
lumiQueryAPI.py:1839
RealQuadEquation::first
double first
Definition:
RealQuadEquation.h:13
RealQuadEquation
Definition:
RealQuadEquation.h:11
Generated for CMSSW Reference Manual by
1.8.11