71 std::vector<math::XYZPointF>
result;
75 std::vector<reco::CaloClusterPtr>
matchingBC(2);
83 for ( std::vector<reco::TransientTrack>::const_iterator iTk=tracks.begin(); iTk!=tracks.end(); ++iTk) {
87 if ( !( myTSOS.
isValid() ) )
continue;
95 if ( (*iTk).innermostMeasurementState().globalPosition().eta() > 0.) {
109 result.push_back(ecalImpactPosition );
114 float bcDistanceToTrack=9999;
119 for (
unsigned i = 0;
i < bcHandle->size(); ++
i ) {
120 float dEta= bcHandle->ptrAt(
i)->position().eta() - ecalImpactPosition.eta() ;
121 float dPhi= bcHandle->ptrAt(
i)->position().phi() - ecalImpactPosition.phi() ;
122 if (
sqrt(dEta*dEta + dPhi*dPhi) < bcDistanceToTrack ) {
124 bcDistanceToTrack=
sqrt(dEta*dEta + dPhi*dPhi);
130 matchingBC[iTrk]=bcHandle->ptrAt(goodBC);
static BoundCylinder * initBarrel()
TrajectoryStateOnSurface stateAtECAL_
static float barrelHalfLength()
static BoundDisk * initNegative()
GlobalPoint globalPosition() const
static const ReferenceCountingPointer< BoundDisk > theNegativeEtaEndcap_
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< float > > XYZPointF
point in space with cartesian internal representation
static const BoundDisk & positiveEtaEndcap()
ConversionTrackEcalImpactPoint(const MagneticField *field)
~ConversionTrackEcalImpactPoint()
static BoundDisk * initPositive()
static float endcapRadius()
std::vector< reco::CaloClusterPtr > matchingBC_
double dPhi(double phi1, double phi2)
static const BoundDisk & negativeEtaEndcap()
std::vector< math::XYZPointF > find(const std::vector< reco::TransientTrack > &tracks, const edm::Handle< edm::View< reco::CaloCluster > > &bcHandle)
static const BoundCylinder & barrel()
static const ReferenceCountingPointer< BoundDisk > thePositiveEtaEndcap_
static const ReferenceCountingPointer< BoundCylinder > theBarrel_
std::vector< reco::CaloClusterPtr > matchingBC() const
static float barrelRadius()
PropagatorWithMaterial * forwardPropagator_
const MagneticField * theMF_
PropagationDirection dir_