48 edm::LogWarning(
"ElectronMomentumCorrector::correct")<<
"unexpected classification" ;
63 float finalMomentum = electron.
p4().t();
64 float finalMomentumError = 999.;
70 finalMomentum = scEnergy; finalMomentumError =
errorEnergy_;
80 finalMomentum = scEnergy; finalMomentumError =
errorEnergy_;
89 float errorEOverP =
sqrt(
94 if ( eOverP > 1 + 2.5*errorEOverP )
96 finalMomentum = scEnergy; finalMomentumError =
errorEnergy_;
102 else if ( eOverP < 1 - 2.5*errorEOverP )
104 finalMomentum = scEnergy; finalMomentumError =
errorEnergy_;
111 else if (electron.
isEE())
116 {
edm::LogWarning(
"ElectronMomentumCorrector::correct")<<
"nor barrel neither endcap electron ?!" ; }
118 else if (electron.
isGap())
129 finalMomentumError =
sqrt(finalMomentumVariance);
136 ( oldMomentum.x()*finalMomentum/oldMomentum.t(),
137 oldMomentum.y()*finalMomentum/oldMomentum.t(),
138 oldMomentum.z()*finalMomentum/oldMomentum.t(),
XYZTLorentzVectorD XYZTLorentzVector
Lorentz vector with cylindrical internal representation using pseudorapidity.
bool isMomentumCorrected() const
math::XYZVector trackMomentumAtVtx() const
void correctMomentum(const LorentzVector &momentum, float trackMomentumError, float electronMomentumError)
float ecalEnergyError() const
Classification classification() const
float errorTrackMomentum_
virtual const LorentzVector & p4() const
four-momentum Lorentz vector
math::XYZTLorentzVector newMomentum_