#include <ForwardDetLayer.h>
Public Member Functions | |
virtual std::pair< bool, TrajectoryStateOnSurface > | compatible (const TrajectoryStateOnSurface &, const Propagator &, const MeasurementEstimator &) const |
bool | contains (const Local3DPoint &p) const |
ForwardDetLayer () | |
virtual Location | location () const |
Which part of the detector (barrel, endcap) | |
virtual const BoundDisk & | specificSurface () const |
virtual const BoundSurface & | surface () const |
The surface of the GeometricSearchDet. | |
virtual | ~ForwardDetLayer () |
Protected Member Functions | |
virtual BoundDisk * | computeSurface () |
virtual void | initialize () |
float | rmax () const |
float | rmin () const |
void | setSurface (BoundDisk *cp) |
float | zmax () const |
float | zmin () const |
Private Attributes | |
ReferenceCountingPointer < BoundDisk > | theDisk |
A specialization of the DetLayer interface for forward layers. Forward layers are disks with their axes parallel to the global Z axis. The methods that have a common implementation for all ForwardDetLayers are implemented in this class, but some methods are left abstract.
Definition at line 20 of file ForwardDetLayer.h.
ForwardDetLayer::ForwardDetLayer | ( | ) |
Definition at line 9 of file ForwardDetLayer.cc.
: theDisk(0) //theRmin(0), theRmax(0), theZmin(0), theZmax(0) {}
ForwardDetLayer::~ForwardDetLayer | ( | ) | [virtual] |
Definition at line 15 of file ForwardDetLayer.cc.
{ }
pair< bool, TrajectoryStateOnSurface > ForwardDetLayer::compatible | ( | const TrajectoryStateOnSurface & | ts, |
const Propagator & | , | ||
const MeasurementEstimator & | |||
) | const [virtual] |
tests the geometrical compatibility of the Det with the predicted state. The FreeTrajectoryState argument is propagated to the Det surface using the Propagator argument. The resulting TrajectoryStateOnSurface is tested for compatibility with the surface bounds. If compatible, a std::pair< true, propagatedState> is returned. If the propagation fails, or if the state is not compatible, a std::pair< false, propagatedState> is returned.
Implements GeometricSearchDet.
Reimplemented in MuRingForwardDoubleLayer, GCC11_FINAL, GCC11_FINAL, GCC11_FINAL, GCC11_FINAL, GCC11_FINAL, GCC11_FINAL, GCC11_FINAL, and GCC11_FINAL.
Definition at line 109 of file ForwardDetLayer.cc.
References BoundSurface::bounds(), deltaR(), TrajectoryStateOnSurface::hasError(), SimpleDiskBounds::inside(), TrajectoryStateOnSurface::isValid(), TrajectoryStateOnSurface::localDirection(), TrajectoryStateOnSurface::localError(), TrajectoryStateOnSurface::localPosition(), LocalTrajectoryError::positionError(), Propagator::propagate(), rmax(), rmin(), specificSurface(), mathSSE::sqrt(), surface(), funct::tan(), theDisk, PV3DBase< T, PVType, FrameType >::theta(), Bounds::thickness(), tmp, LocalError::xx(), LocalError::yy(), zmax(), zmin(), and zPos.
Referenced by MuRingForwardLayer::compatibleDets().
{ if(theDisk == 0) edm::LogError("DetLayers") << "ERROR: BarrelDetLayer::compatible() is used before the layer surface is initialized" ; // throw an exception? which one? TrajectoryStateOnSurface myState = prop.propagate( ts, specificSurface()); if ( !myState.isValid()) return make_pair( false, myState); // take into account the thickness of the layer float deltaR = surface().bounds().thickness()/2. * fabs( tan( myState.localDirection().theta())); // take into account the error on the predicted state const float nSigma = 3.; if (myState.hasError()) { LocalError err = myState.localError().positionError(); // ignore correlation for the moment... deltaR += nSigma * sqrt(err.xx() + err.yy()); } float zPos = (zmax()+zmin())/2.; SimpleDiskBounds tmp( rmin()-deltaR, rmax()+deltaR, zmin()-zPos, zmax()-zPos); return make_pair( tmp.inside(myState.localPosition()), myState); }
BoundDisk * ForwardDetLayer::computeSurface | ( | ) | [protected, virtual] |
Reimplemented in MuRingForwardDoubleLayer.
Definition at line 34 of file ForwardDetLayer.cc.
References GeometricSearchDet::basicComponents(), GeometricSearchDet::components(), BoundingBox::corners(), Vector3DBase< T, FrameTag >::dot(), F(), LogDebug, max(), min, pos, alignCSCRings::r, makeMuonMisalignmentScenario::rot, Vector3DBase< T, FrameTag >::unit(), tablePrinter::width, z, and zPos.
Referenced by initialize().
{ LogDebug("DetLayers") << "ForwaLayer::computeSurface callded" ; vector<const GeomDet*> comps= basicComponents(); vector<const GeomDet*>::const_iterator ifirst = comps.begin(); vector<const GeomDet*>::const_iterator ilast = comps.end(); // Find extension in R float theRmin = components().front()->position().perp(); float theRmax = theRmin; float theZmin = components().back()->position().z(); float theZmax = theZmin; for ( vector<const GeomDet*>::const_iterator deti = ifirst; deti != ilast; deti++) { vector<GlobalPoint> corners = BoundingBox().corners( dynamic_cast<const BoundPlane&>((**deti).surface())); for (vector<GlobalPoint>::const_iterator ic = corners.begin(); ic != corners.end(); ic++) { float r = ic->perp(); LogDebug("DetLayers") << "corner.perp(): " << r ; float z = ic->z(); theRmin = min( theRmin, r); theRmax = max( theRmax, r); theZmin = min( theZmin, z); theZmax = max( theZmax, z); } // in addition to the corners we have to check the middle of the // det +/- length/2 // , since the min (max) radius for typical fw dets is reached there float rdet = (**deti).position().perp(); float len = (**deti).surface().bounds().length(); float width = (**deti).surface().bounds().width(); GlobalVector xAxis = (**deti).toGlobal(LocalVector(1,0,0)); GlobalVector yAxis = (**deti).toGlobal(LocalVector(0,1,0)); GlobalVector perpDir = GlobalVector( (**deti).position() - GlobalPoint(0,0,(**deti).position().z()) ); double xAxisCos = xAxis.unit().dot(perpDir.unit()); double yAxisCos = yAxis.unit().dot(perpDir.unit()); LogDebug("DetLayers") << "in ForwardDetLayer::computeSurface(),xAxisCos,yAxisCos: " << xAxisCos << " , " << yAxisCos ; LogDebug("DetLayers") << "det pos.perp,length,width: " << rdet << " , " << len << " , " << width ; if( fabs(xAxisCos) > fabs(yAxisCos) ) { theRmin = min( theRmin, rdet-width/2.F); theRmax = max( theRmax, rdet+width/2.F); }else{ theRmin = min( theRmin, rdet-len/2.F); theRmax = max( theRmax, rdet+len/2.F); } } LogDebug("DetLayers") << "creating SimpleDiskBounds with r range" << theRmin << " " << theRmax << " and z range " << theZmin << " " << theZmax ; // By default the forward layers are positioned around the z axis of the // global frame, and the axes of their local frame coincide with // those of the global grame (z along the disk axis) float zPos = (theZmax+theZmin)/2.; PositionType pos(0.,0.,zPos); RotationType rot; return new BoundDisk( pos, rot, SimpleDiskBounds( theRmin, theRmax, theZmin-zPos, theZmax-zPos)); }
bool ForwardDetLayer::contains | ( | const Local3DPoint & | p | ) | const |
Definition at line 24 of file ForwardDetLayer.cc.
References BoundSurface::bounds(), Bounds::inside(), and surface().
void ForwardDetLayer::initialize | ( | ) | [protected, virtual] |
Definition at line 29 of file ForwardDetLayer.cc.
References computeSurface(), and setSurface().
{ setSurface( computeSurface()); }
virtual Location ForwardDetLayer::location | ( | ) | const [inline, virtual] |
Which part of the detector (barrel, endcap)
Implements DetLayer.
Definition at line 35 of file ForwardDetLayer.h.
References Reference_intrackfit_cff::endcap.
{return GeomDetEnumerators::endcap;}
float ForwardDetLayer::rmax | ( | ) | const [inline, protected] |
Definition at line 48 of file ForwardDetLayer.h.
References theDisk.
Referenced by MuRingForwardDoubleLayer::compatible(), compatible(), GCC11_FINAL::computeDisk(), and MuRingForwardDoubleLayer::computeSurface().
{ return theDisk->outerRadius();}
float ForwardDetLayer::rmin | ( | ) | const [inline, protected] |
Definition at line 47 of file ForwardDetLayer.h.
References theDisk.
Referenced by MuRingForwardDoubleLayer::compatible(), compatible(), GCC11_FINAL::computeDisk(), and MuRingForwardDoubleLayer::computeSurface().
{ return theDisk->innerRadius();}
void ForwardDetLayer::setSurface | ( | BoundDisk * | cp | ) | [protected] |
Definition at line 20 of file ForwardDetLayer.cc.
References CommonMethods::cp(), and theDisk.
Referenced by initialize(), MuRingForwardDoubleLayer::MuRingForwardDoubleLayer(), MuRingForwardLayer::MuRingForwardLayer(), and TECLayer::TECLayer().
virtual const BoundDisk& ForwardDetLayer::specificSurface | ( | ) | const [inline, virtual] |
Reimplemented in GCC11_FINAL, GCC11_FINAL, and GCC11_FINAL.
Definition at line 38 of file ForwardDetLayer.h.
References theDisk.
Referenced by MuonNavigationSchool::addEndcapLayer(), MuonTkNavigationSchool::addEndcapLayer(), DirectTrackerNavigation::checkCompatible(), DirectMuonNavigation::checkCompatible(), MuRingForwardDoubleLayer::compatible(), compatible(), MuRingForwardLayer::compatibleDets(), MuRingForwardDoubleLayer::computeSurface(), MuonShowerInformationFiller::crossingPoint(), MultipleScatteringGeometry::detLayers(), RectangularEtaPhiTrackingRegion::estimator(), InnerDeltaPhi::initForwardLayer(), SimpleNavigationSchool::linkNextBarrelLayer(), OutInConversionSeedFinder::makeEstimator(), MSLayer::MSLayer(), MuRingForwardDoubleLayer::MuRingForwardDoubleLayer(), MuRingForwardLayer::MuRingForwardLayer(), ForwardLayerMirrorImage::operator()(), DiskLessInnerRadius::operator()(), TECLayer::TECLayer(), SimpleNavigableLayer::wellInside(), and whatIsTheNextStep().
{ return *theDisk;}
virtual const BoundSurface& ForwardDetLayer::surface | ( | ) | const [inline, virtual] |
The surface of the GeometricSearchDet.
Implements GeometricSearchDet.
Reimplemented in GCC11_FINAL, GCC11_FINAL, GCC11_FINAL, GCC11_FINAL, GCC11_FINAL, GCC11_FINAL, and GCC11_FINAL.
Definition at line 28 of file ForwardDetLayer.h.
References theDisk.
Referenced by MuRingForwardDoubleLayer::compatible(), compatible(), MuRingForwardLayer::compatibleDets(), TECLayer::computeCrossings(), contains(), RectangularEtaPhiTrackingRegion::estimator(), PixelTripletNoTipGenerator::hitTriplets(), ThirdHitRZPredictionBase::initLayer(), ThirdHitPrediction::initLayer(), OutInConversionSeedFinder::makeEstimator(), MuonDetLayerComp::operator()(), MuonNavigationPrinter::printLayers(), and SimpleNavigableLayer::wellInside().
{ return *theDisk;}
float ForwardDetLayer::zmax | ( | ) | const [inline, protected] |
Definition at line 50 of file ForwardDetLayer.h.
References theDisk.
Referenced by MuRingForwardDoubleLayer::compatible(), compatible(), GCC11_FINAL::computeDisk(), and MuRingForwardDoubleLayer::computeSurface().
float ForwardDetLayer::zmin | ( | ) | const [inline, protected] |
Definition at line 49 of file ForwardDetLayer.h.
References theDisk.
Referenced by MuRingForwardDoubleLayer::compatible(), compatible(), GCC11_FINAL::computeDisk(), and MuRingForwardDoubleLayer::computeSurface().
Reimplemented in GCC11_FINAL.
Definition at line 58 of file ForwardDetLayer.h.
Referenced by compatible(), rmax(), rmin(), setSurface(), specificSurface(), surface(), zmax(), and zmin().