20 return surface().bounds().inside(p);
25 setSurface( computeSurface());
32 vector< const GeomDet*> comps = basicComponents();
35 float theRmin = comps.front()->position().perp();
36 float theRmax = theRmin;
37 float theZmin = comps.front()->position().z();
38 float theZmax = theZmin;
39 for ( vector< const GeomDet*>::const_iterator deti = comps.begin();
40 deti != comps.end(); deti++) {
41 vector<GlobalPoint> corners =
43 for (vector<GlobalPoint>::const_iterator ic = corners.begin();
44 ic != corners.end(); ic++) {
47 theRmin =
min( theRmin, r);
48 theRmax =
max( theRmax, r);
49 theZmin =
min( theZmin, z);
50 theZmax =
max( theZmax, z);
55 float rdet = (**deti).position().perp();
56 float thick = (**deti).surface().bounds().thickness();
57 theRmin =
min( theRmin, rdet-thick/2.
F);
58 theRmax =
max( theRmax, rdet+thick/2.
F);
73 pair<bool, TrajectoryStateOnSurface>
79 <<
"ERROR: BarrelDetLayer::compatible() is used before the layer surface is initialized" ;
88 auto deltaZ = 0.5f*bounds().length();
89 if (z0<deltaZ)
return make_pair(
true, myState);
92 deltaZ += 0.5f*bounds().thickness() *
101 return make_pair(z0<deltaZ, myState);
virtual BoundCylinder * computeSurface()
virtual void initialize()
const CartesianTrajectoryError cartesianError() const
GlobalPoint globalPosition() const
bool contains(const Local3DPoint &p) const
virtual std::pair< bool, TrajectoryStateOnSurface > compatible(const TrajectoryStateOnSurface &ts, const Propagator &, const MeasurementEstimator &) const final
Abs< T >::type abs(const T &t)
void setSurface(BoundCylinder *cp)
virtual ~BarrelDetLayer()
const GlobalError position() const
Position error submatrix.
TrajectoryStateOnSurface propagate(STA const &state, SUR const &surface) const
static std::vector< GlobalPoint > corners(const Plane &)
static float computeRadius(Bounds const &bounds)
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
GlobalVector globalDirection() const