src
DataFormats
GeometrySurface
src
SimpleCylinderBounds.cc
Go to the documentation of this file.
1
#include "
DataFormats/GeometrySurface/interface/LocalError.h
"
2
#include "
DataFormats/GeometrySurface/interface/SimpleCylinderBounds.h
"
3
4
SimpleCylinderBounds::SimpleCylinderBounds
(
float
rmin,
float
rmax,
float
zmin
,
float
zmax
)
5
: theRmin(rmin), theRmax(rmax), theZmin(
zmin
), theZmax(
zmax
) {
6
if
(
theRmin
>
theRmax
)
7
std::swap
(
theRmin
,
theRmax
);
8
if
(
theZmin
>
theZmax
)
9
std::swap
(
theZmin
,
theZmax
);
10
}
11
12
bool
SimpleCylinderBounds::inside
(
const
Local3DPoint
&
p
)
const
{
13
return
p
.z() >
theZmin
&&
p
.z() <
theZmax
&&
p
.perp() >
theRmin
&&
p
.perp() <
theRmax
;
14
}
15
16
bool
SimpleCylinderBounds::inside
(
const
Local3DPoint
&
p
,
const
LocalError
&
err
,
float
scale
)
const
{
17
SimpleCylinderBounds
tmp
(
theRmin
,
theRmax
,
theZmin
-
sqrt
(
err
.yy()) *
scale
,
theZmax
+
sqrt
(
err
.yy()) *
scale
);
18
19
return
tmp
.inside(
p
);
20
}
21
22
bool
SimpleCylinderBounds::inside
(
const
Local2DPoint
&
p
,
const
LocalError
&
err
)
const
{
return
Bounds::inside
(
p
,
err
); }
23
24
Bounds
*
SimpleCylinderBounds::clone
()
const
{
return
new
SimpleCylinderBounds
(*
this
); }
LocalError.h
Bounds::inside
virtual bool inside(const Local3DPoint &) const =0
Determine if the point is inside the bounds.
SiStripMonitorCluster_cfi.zmax
zmax
Definition:
SiStripMonitorCluster_cfi.py:215
SimpleCylinderBounds::inside
bool inside(const Local3DPoint &p) const override
Determine if the point is inside the bounds.
Definition:
SimpleCylinderBounds.cc:12
edm::swap
void swap(Association< C > &lhs, Association< C > &rhs)
Definition:
Association.h:112
Point2DBase< float, LocalTag >
submitPVResolutionJobs.err
err
Definition:
submitPVResolutionJobs.py:84
SimpleCylinderBounds.h
SimpleCylinderBounds::theRmin
float theRmin
Definition:
SimpleCylinderBounds.h:40
SimpleCylinderBounds::SimpleCylinderBounds
SimpleCylinderBounds(float rmin, float rmax, float zmin, float zmax)
Definition:
SimpleCylinderBounds.cc:4
SimpleCylinderBounds::theZmin
float theZmin
Definition:
SimpleCylinderBounds.h:42
mathSSE::sqrt
T sqrt(T t)
Definition:
SSEVec.h:19
SimpleCylinderBounds::theZmax
float theZmax
Definition:
SimpleCylinderBounds.h:43
SimpleCylinderBounds::theRmax
float theRmax
Definition:
SimpleCylinderBounds.h:41
LocalError
Definition:
LocalError.h:12
SimpleCylinderBounds::clone
Bounds * clone() const override
Definition:
SimpleCylinderBounds.cc:24
Point3DBase< float, LocalTag >
SimpleCylinderBounds
Definition:
SimpleCylinderBounds.h:19
SiStripMonitorCluster_cfi.zmin
zmin
Definition:
SiStripMonitorCluster_cfi.py:214
pfClustersFromCombinedCaloHF_cfi.scale
scale
Definition:
pfClustersFromCombinedCaloHF_cfi.py:51
Bounds
Definition:
Bounds.h:18
createJobs.tmp
tmp
align.sh
Definition:
createJobs.py:716
AlCaHLTBitMon_ParallelJobs.p
def p
Definition:
AlCaHLTBitMon_ParallelJobs.py:153
Generated for CMSSW Reference Manual by
1.8.14