CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
reco::BeamSpot Class Reference

#include <BeamSpot.h>

Public Types

enum  { dimension = 7 }
 
enum  { dim3 = 3 }
 
enum  { resdim = 2 }
 
enum  BeamType { Unknown =-1, Fake =0, LHC =1, Tracker =2 }
 beam spot flags More...
 
typedef math::Error< dim3 >::type Covariance3DMatrix
 
typedef math::Error< dimension >::type CovarianceMatrix
 
typedef math::XYZPoint Point
 point in the space More...
 
typedef math::Error< resdim >::type ResCovMatrix
 

Public Member Functions

 BeamSpot ()
 default constructor More...
 
 BeamSpot (const Point &point, double sigmaZ, double dxdz, double dydz, double BeamWidthX, const CovarianceMatrix &error, BeamType type=Unknown)
 constructor from values More...
 
double beamWidthFromBeta (double z, double e) const
 
double BeamWidthX () const
 beam width X More...
 
double BeamWidthXError () const
 error on beam width X, assume error in X = Y More...
 
double BeamWidthY () const
 beam width Y More...
 
double BeamWidthYError () const
 error on beam width Y, assume error in X = Y More...
 
double betaStar () const
 
double covariance (int i, int j) const
 (i,j)-th element of error matrix More...
 
CovarianceMatrix covariance () const
 return full covariance matrix of dim 7 More...
 
Covariance3DMatrix covariance3D () const
 return only 3D position covariance matrix More...
 
double dxdz () const
 dxdz slope More...
 
double dxdzError () const
 error on dxdz More...
 
double dydz () const
 dydz slope More...
 
double dydzError () const
 error on dydz More...
 
double emittanceX () const
 additional information More...
 
double emittanceY () const
 
const Pointposition () const
 position More...
 
const Point position (const double z) const
 position of the beam spot at a given z value (it takes into account the dxdz and dydz slopes) More...
 
void print (std::stringstream &ss) const
 print information More...
 
Covariance3DMatrix rotatedCovariance3D () const
 
void setBeamWidthX (double v)
 
void setBeamWidthY (double v)
 
void setbetaStar (double v)
 
void setEmittanceX (double v)
 
void setEmittanceY (double v)
 
void setType (BeamType type)
 set beam type More...
 
double sigmaZ () const
 sigma z More...
 
double sigmaZ0Error () const
 error on sigma z More...
 
BeamType type () const
 return beam type More...
 
double x (const double z) const
 x coordinate of the beeam spot position at a given z value (it takes into account the dxdz slope) More...
 
double x0 () const
 x coordinate More...
 
double x0Error () const
 error on x More...
 
double y (const double z) const
 y coordinate of the beeam spot position at a given z value (it takes into account the dydz slope) More...
 
double y0 () const
 y coordinate More...
 
double y0Error () const
 error on y More...
 
double z0 () const
 z coordinate More...
 
double z0Error () const
 error on z More...
 

Private Attributes

Double32_t BeamWidthX_
 
Double32_t BeamWidthY_
 
Double32_t betaStar_
 
Double32_t dxdz_
 
Double32_t dydz_
 
Double32_t emittanceX_
 
Double32_t emittanceY_
 
CovarianceMatrix error_
 errors More...
 
Point position_
 position More...
 
Double32_t sigmaZ_
 
BeamType type_
 

Detailed Description

Reconstructed beam spot object which provides position, error, and width of the beam position.

Author
Francisco Yumiceva, Fermilab (yumic.nosp@m.eva@.nosp@m.fnal..nosp@m.gov)

Definition at line 22 of file BeamSpot.h.

Member Typedef Documentation

Definition at line 33 of file BeamSpot.h.

Definition at line 31 of file BeamSpot.h.

point in the space

Definition at line 29 of file BeamSpot.h.

Definition at line 35 of file BeamSpot.h.

Member Enumeration Documentation

anonymous enum
Enumerator
dimension 

Definition at line 30 of file BeamSpot.h.

anonymous enum
Enumerator
dim3 

Definition at line 32 of file BeamSpot.h.

32 { dim3 = 3 };
anonymous enum
Enumerator
resdim 

Definition at line 34 of file BeamSpot.h.

beam spot flags

Enumerator
Unknown 
Fake 
LHC 
Tracker 

Definition at line 26 of file BeamSpot.h.

Constructor & Destructor Documentation

reco::BeamSpot::BeamSpot ( )

default constructor

Definition at line 24 of file BeamSpot.cc.

References gen::k, and reco::Unknown.

24  {
25  // initialize
26  position_ = Point(0.,0.,0.);
27  sigmaZ_ = 0.;
28  dxdz_ = 0.;
29  dydz_ = 0.;
30  BeamWidthX_ = 0.; BeamWidthY_ = 0;
31  for (int j=0; j<7; j++) {
32  for (int k=j; k<7; k++) {
33  error_(j,k) = 0.;
34  }
35  }
36  type_ = Unknown;
37  emittanceX_ = 0;
38  emittanceY_ = 0;
39  betaStar_ = 0;
40  }
Double32_t dxdz_
Definition: BeamSpot.h:159
Double32_t emittanceX_
Definition: BeamSpot.h:161
math::XYZPoint Point
point in the space
Definition: BeamSpot.h:29
CovarianceMatrix error_
errors
Definition: BeamSpot.h:154
Double32_t BeamWidthX_
Definition: BeamSpot.h:157
Point position_
position
Definition: BeamSpot.h:152
Double32_t emittanceY_
Definition: BeamSpot.h:162
int k[5][pyjets_maxn]
Double32_t BeamWidthY_
Definition: BeamSpot.h:158
BeamType type_
Definition: BeamSpot.h:165
Double32_t betaStar_
Definition: BeamSpot.h:163
Double32_t sigmaZ_
Definition: BeamSpot.h:156
Double32_t dydz_
Definition: BeamSpot.h:160
reco::BeamSpot::BeamSpot ( const Point point,
double  sigmaZ,
double  dxdz,
double  dydz,
double  BeamWidthX,
const CovarianceMatrix error,
BeamType  type = Unknown 
)
inline

constructor from values

Definition at line 41 of file BeamSpot.h.

References BeamWidthX(), BeamWidthX_, BeamWidthY_, betaStar_, dxdz(), dxdz_, dydz(), dydz_, emittanceX_, emittanceY_, relativeConstraints::error, error_, point, position_, sigmaZ(), sigmaZ_, type(), and type_.

47  {
48  position_ = point;
49  sigmaZ_ = sigmaZ;
50  dxdz_ = dxdz;
51  dydz_ = dydz;
54  error_ = error;
55  type_ = type;
57  betaStar_ = 0;
58  };
Double32_t dxdz_
Definition: BeamSpot.h:159
Double32_t emittanceX_
Definition: BeamSpot.h:161
CovarianceMatrix error_
errors
Definition: BeamSpot.h:154
Double32_t BeamWidthX_
Definition: BeamSpot.h:157
double dydz() const
dydz slope
Definition: BeamSpot.h:84
Point position_
position
Definition: BeamSpot.h:152
Double32_t emittanceY_
Definition: BeamSpot.h:162
double BeamWidthX() const
beam width X
Definition: BeamSpot.h:86
double dxdz() const
dxdz slope
Definition: BeamSpot.h:82
double sigmaZ() const
sigma z
Definition: BeamSpot.h:80
Double32_t BeamWidthY_
Definition: BeamSpot.h:158
BeamType type_
Definition: BeamSpot.h:165
Double32_t betaStar_
Definition: BeamSpot.h:163
Double32_t sigmaZ_
Definition: BeamSpot.h:156
*vegas h *****************************************************used in the default bin number in original ***version of VEGAS is ***a higher bin number might help to derive a more precise ***grade subtle point
Definition: invegas.h:5
BeamType type() const
return beam type
Definition: BeamSpot.h:129
Double32_t dydz_
Definition: BeamSpot.h:160

Member Function Documentation

double reco::BeamSpot::beamWidthFromBeta ( double  z,
double  e 
) const
inline

Definition at line 139 of file BeamSpot.h.

References betaStar_, position_, funct::pow(), and mathSSE::sqrt().

139  {
140  return sqrt( e*betaStar_*(1 + pow((z-position_.Z())/betaStar_,2) ) );
141  }
Point position_
position
Definition: BeamSpot.h:152
T sqrt(T t)
Definition: SSEVec.h:18
Double32_t betaStar_
Definition: BeamSpot.h:163
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:40
double reco::BeamSpot::BeamWidthX ( ) const
inline

beam width X

Definition at line 86 of file BeamSpot.h.

References BeamWidthX_.

Referenced by PrimaryVertexMonitor::analyze(), MuonMiniAOD::analyze(), DiMuonHistograms::analyze(), RecoMuonValidator::analyze(), MuonKinVsEtaAnalyzer::analyze(), EfficiencyAnalyzer::analyze(), MuonRecoOneHLT::analyze(), PrimaryVertexValidation::analyze(), BeamSpot(), BeamSpotTransientTrackingRecHit::BeamSpotTransientTrackingRecHit(), AlcaBeamSpotManager::createWeightedPayloads(), beamspot::dumpBeamSpotTxt(), BeamFitter::dumpBWTxtFile(), BeamFitter::dumpTxtFile(), TwoBodyDecayVirtualMeasurement::extractBeamSpotError(), MuonVPlusJetsIDSelectionFunctor::fall10Cuts(), BeamSpotHistogramMaker::fill(), DAClusterizerInZ::fill(), DAClusterizerInZ_vect::fill(), DAClusterizerInZT_vect::fill(), TrackingNtuple::fillBeamSpot(), BeamMonitorBx::FillTables(), PrimaryVertexValidation::fillTrackHistos(), ApeEstimator::fillTrackVariables(), BeamMonitorBx::FillTrendHistos(), BSFitter::Fit(), BeamMonitor::FitAndFill(), MuonPFAnalyzer::getPrimaryVertex(), L1TMuonDQMOffline::getPrimaryVertex(), L1TTauOffline::getPrimaryVertex(), MuonVPlusJetsIDSelectionFunctor::kitQCDCuts(), KFBasedPixelFitter::MyBeamSpotHit::MyBeamSpotHit(), HIBestVertexProducer::produce(), AlCaGammaJetProducer::produce(), FFTJetVertexAdder::produce(), AlCaHBHEMuonProducer::produce(), TemplatedSecondaryVertexProducer< IPTI, VTX >::produce(), BeamFitter::runFitterNoTxt(), BeamFitter::runPVandTrkFitter(), HIProtoTrackSelector::select(), MuonVPlusJetsIDSelectionFunctor::spring10Cuts(), BeamMonitorBx::weight(), and BeamFitter::write2DB().

86 { return BeamWidthX_; }
Double32_t BeamWidthX_
Definition: BeamSpot.h:157
double reco::BeamSpot::BeamWidthXError ( ) const
inline

error on beam width X, assume error in X = Y

Definition at line 103 of file BeamSpot.h.

References error_, and mathSSE::sqrt().

Referenced by AlcaBeamSpotManager::createWeightedPayloads(), BeamFitter::dumpBWTxtFile(), BeamMonitorBx::FillTables(), BeamMonitorBx::FillTrendHistos(), BeamMonitor::FitAndFill(), BeamFitter::runFitterNoTxt(), and BeamMonitorBx::weight().

103 { return sqrt ( error_(6,6) );}
CovarianceMatrix error_
errors
Definition: BeamSpot.h:154
T sqrt(T t)
Definition: SSEVec.h:18
double reco::BeamSpot::BeamWidthY ( ) const
inline
double reco::BeamSpot::BeamWidthYError ( ) const
inline

error on beam width Y, assume error in X = Y

Definition at line 105 of file BeamSpot.h.

References error_, and mathSSE::sqrt().

Referenced by AlcaBeamSpotManager::createWeightedPayloads(), BeamMonitorBx::FillTables(), BeamMonitorBx::FillTrendHistos(), BeamMonitor::FitAndFill(), BeamFitter::runFitterNoTxt(), and BeamMonitorBx::weight().

105 { return sqrt ( error_(6,6) );}
CovarianceMatrix error_
errors
Definition: BeamSpot.h:154
T sqrt(T t)
Definition: SSEVec.h:18
double reco::BeamSpot::betaStar ( ) const
inline

Definition at line 138 of file BeamSpot.h.

References betaStar_.

Referenced by beamspot::dumpBeamSpotTxt(), and BeamFitter::dumpTxtFile().

138 { return betaStar_; }
Double32_t betaStar_
Definition: BeamSpot.h:163
double reco::BeamSpot::covariance ( int  i,
int  j 
) const
inline
CovarianceMatrix reco::BeamSpot::covariance ( void  ) const
inline

return full covariance matrix of dim 7

Definition at line 116 of file BeamSpot.h.

References error_.

116 { return error_; }
CovarianceMatrix error_
errors
Definition: BeamSpot.h:154
Covariance3DMatrix reco::BeamSpot::covariance3D ( ) const
inline

return only 3D position covariance matrix

Definition at line 118 of file BeamSpot.h.

References error_, gen::k, and makeMuonMisalignmentScenario::matrix.

Referenced by pat::PATElectronProducer::embedHighLevel(), pat::PATSingleVertexSelector::filter_(), PF_PU_AssoMapAlgos::GetCleanedKshort(), PF_PU_AssoMapAlgos::GetCleanedLambda(), and PF_PU_AssoMapAlgos::GetCleanedNI().

118  {
119 
121  for (int j=0; j<3; j++) {
122  for (int k=j; k<3; k++) {
123  matrix(j,k) = error_(j,k);
124  }
125  }
126  return matrix;
127  };
math::Error< dim3 >::type Covariance3DMatrix
Definition: BeamSpot.h:33
CovarianceMatrix error_
errors
Definition: BeamSpot.h:154
int k[5][pyjets_maxn]
double reco::BeamSpot::dxdz ( ) const
inline
double reco::BeamSpot::dxdzError ( ) const
inline

error on dxdz

Definition at line 98 of file BeamSpot.h.

References error_, and mathSSE::sqrt().

Referenced by AlcaBeamSpotManager::createWeightedPayloads(), BeamMonitor::FitAndFill(), BeamFitter::runFitterNoTxt(), and BeamMonitorBx::weight().

98 { return sqrt ( error_(4,4) ); }
CovarianceMatrix error_
errors
Definition: BeamSpot.h:154
T sqrt(T t)
Definition: SSEVec.h:18
double reco::BeamSpot::dydz ( ) const
inline
double reco::BeamSpot::dydzError ( ) const
inline

error on dydz

Definition at line 100 of file BeamSpot.h.

References error_, and mathSSE::sqrt().

Referenced by AlcaBeamSpotManager::createWeightedPayloads(), BeamMonitor::FitAndFill(), BeamFitter::runFitterNoTxt(), and BeamMonitorBx::weight().

100 { return sqrt ( error_(5,5) ); }
CovarianceMatrix error_
errors
Definition: BeamSpot.h:154
T sqrt(T t)
Definition: SSEVec.h:18
double reco::BeamSpot::emittanceX ( ) const
inline

additional information

Definition at line 136 of file BeamSpot.h.

References emittanceX_.

Referenced by beamspot::dumpBeamSpotTxt(), and BeamFitter::dumpTxtFile().

136 { return emittanceX_; }
Double32_t emittanceX_
Definition: BeamSpot.h:161
double reco::BeamSpot::emittanceY ( ) const
inline

Definition at line 137 of file BeamSpot.h.

References emittanceY_.

Referenced by beamspot::dumpBeamSpotTxt(), and BeamFitter::dumpTxtFile().

137 { return emittanceY_; }
Double32_t emittanceY_
Definition: BeamSpot.h:162
const Point& reco::BeamSpot::position ( ) const
inline

position

Definition at line 62 of file BeamSpot.h.

References position_.

Referenced by ElectronMcSignalValidator::analyze(), ElectronGeneralAnalyzer::analyze(), TrackTypeMonitor::analyze(), ElectronTagProbeAnalyzer::analyze(), EwkMuDQM::analyze(), StandaloneTrackMonitor::analyze(), PatTrackAnalyzer::analyze(), PatBJetTrackAnalyzer::analyze(), MuonMiniAOD::analyze(), EwkMuLumiMonitorDQM::analyze(), TrackingRecoMaterialAnalyser::analyze(), ElectronSeedAnalyzer::analyze(), ElectronMcFakeValidator::analyze(), RecoMuonValidator::analyze(), DiMuonHistograms::analyze(), dqm::TrackAnalyzer::analyze(), MuonKinVsEtaAnalyzer::analyze(), MuonRecoAnalyzer::analyze(), ElectronAnalyzer::analyze(), EfficiencyAnalyzer::analyze(), GsfElectronDataAnalyzer::analyze(), GsfElectronMCFakeAnalyzer::analyze(), DQMAnalyzer::analyze(), GsfElectronFakeAnalyzer::analyze(), V0Monitor::analyze(), ElectronConversionRejectionValidator::analyze(), MuonRecoOneHLT::analyze(), SUSY_HLT_SingleLepton::analyze(), TestOutliers::analyze(), LepHTMonitor::analyze(), HcalRaddamMuon::analyze(), HLTMuonMatchAndPlot::analyze(), GenPurposeSkimmerData::analyze(), HcalHBHEMuonAnalyzer::analyze(), IsoTrackCalibration::analyze(), HLTExoticaSubAnalysis::analyze(), IsoTrackCalib::analyze(), IsoTrig::analyze(), IsolatedTracksHcalScale::analyze(), L1MuonRecoTreeProducer::analyze(), MuonTrackValidator::analyze(), IsolatedTracksNxN::analyze(), HLTMuonL3PreFilter::applySelection(), TwoBodyDecayVirtualMeasurement::beamSpotPosition(), PFECALSuperClusterAlgo::buildSuperCluster(), GsfElectronAlgo::createElectron(), muonisolation::PixelTrackExtractor::deposit(), muonisolation::TrackExtractor::deposit(), egammaisolation::EgammaTrackExtractor::deposit(), MultiTrackValidatorGenPs::dqmAnalyze(), MultiTrackValidator::dqmAnalyze(), reco::TrackBase::dxy(), pat::PATMuonProducer::embedHighLevel(), pat::PATElectronProducer::embedHighLevel(), AlignmentMonitorMuonVsCurvature::event(), AlignmentMonitorSegmentDifferences::event(), AlignmentMonitorMuonSystemMap1D::event(), AdHocNTupler::fill(), egHLT::OffHelper::fillHLTData(), GsfTrackProducerBase::fillMode(), ElectronMVAEstimatorRun2Fall17::fillMVAVariables(), ElectronMVAEstimatorRun2Spring15Trig::fillMVAVariables(), ElectronMVAEstimatorRun2Spring15NonTrig::fillMVAVariables(), ElectronMVAEstimatorRun2Spring16GeneralPurpose::fillMVAVariables(), ElectronMVAEstimatorRun2Spring16HZZ::fillMVAVariables(), TrackingNtuple::fillSeeds(), PrimaryVertexValidation::fillTrackHistos(), TrackingNtuple::fillTrackingParticles(), TrackingNtuple::fillTracks(), ZtoMMEventSelector::filter(), ZtoEEEventSelector::filter(), WtoLNuSelector::filter(), WMuNuValidator::filter(), WMuNuSelector::filter(), WZInterestingEventSelector::filter(), AlCaIsoTracksFilter::filter(), CSCEfficiency::filter(), pat::PATSingleVertexSelector::filter_(), ElectronSeedProducer::filterClusters(), ConversionSeedFinder::findLayers(), V0Fitter::fitAll(), PF_PU_AssoMapAlgos::GetCleanedKshort(), PF_PU_AssoMapAlgos::GetCleanedLambda(), PF_PU_AssoMapAlgos::GetCleanedNI(), MuonPFAnalyzer::getPrimaryVertex(), L1TMuonDQMOffline::getPrimaryVertex(), L1TTauOffline::getPrimaryVertex(), HLTMuonTrackMassFilter::hltFilter(), HLTMuonL3SimplePreFilter::hltFilter(), HLTMuonDimuonL2Filter::hltFilter(), HLTMuonL2FromL1TPreFilter::hltFilter(), HLTMuonL2PreFilter::hltFilter(), HLTMuonDimuonL2FromL1TFilter::hltFilter(), HLTMuonL1toL3TkPreFilter::hltFilter(), HLTMuonL1TtoL3TkPreFilter::hltFilter(), HLTPMMassFilter::hltFilter(), RecoTrackSelectorBase::init(), tnp::BaseTreeFiller::init(), cms::MuonTCMETValueMapProducer::isGoodMuon(), cms::MuonTCMETValueMapProducer::isGoodTrack(), TCMETAlgo::isGoodTrack(), L3MuonTrajectoryBuilder::makeTkCandCollection(), OutInConversionSeedFinder::makeTrackState(), DQMExample_Step1::MediumEle(), GsfEleConversionVetoCut::operator()(), HIProtoTrackFilter::operator()(), ElectronIdentifier::passID(), MultiTrackSelector::processMVA(), HIBestVertexProducer::produce(), TrackRefitter::produce(), EgammaPhotonTkIsolationProducer::produce(), EgammaPhotonTkNumIsolationProducer::produce(), ZMuMuTrackUserData::produce(), ZMuMuMuonUserData::produce(), EgammaHLTPFChargedIsolationProducer::produce(), SoftPFElectronTagInfoProducer::produce(), EgammaHLTRegionalPixelSeedGeneratorProducers::produce(), PixelVertexProducer::produce(), EgammaHLTElectronTrackIsolationProducers::produce(), EgammaHLTElectronDetaDphiProducer::produce(), ZToLLEdmNtupleDumper::produce(), pat::PATConversionProducer::produce(), cms::MuonMETValueMapProducer::produce(), AlCaGammaJetProducer::produce(), VertexFromTrackProducer::produce(), AlCaHBHEMuonProducer::produce(), MuIsolatorResultProducer< BT >::produce(), pat::PATPhotonProducer::produce(), pat::PATElectronProducer::produce(), PrimaryVertexProducer::produce(), TrackAlgoCompareUtil::produce(), EgammaHLTGsfTrackVarProducer::produce(), TriggerMatcherToHLTDebug::produce(), SelectedElectronFEDListProducer< TEle, TCand >::produce(), AlCaIsoTracksProducer::produce(), BeamFitter::readEvent(), PhotonConversionTrajectorySeedProducerFromSingleLegAlgo::rejectTrack(), CutBasedElectronID::robustSelection(), EgammaHLTPixelMatchElectronAlgo::run(), PixelUnpackingRegions::run(), MuonAlignmentFromReference::run(), SeedFilter::seeds(), ElectronSeedGenerator::seedsFromThisCluster(), CosmicTrackSelector::select(), HIProtoTrackSelector::select(), MultiTrackSelector::select(), HIMultiTrackSelector::select(), HLTMuonMatchAndPlot::selectedMuons(), GsfElectronAlgo::setAmbiguityData(), GsfElectronAlgo::setCutBasedPreselectionFlag(), EgammaCutBasedEleId::TestWP(), QcdUeDQM::trackSelection(), GsfEleConversionVetoCut::value(), BeamFitter::write2DB(), and y().

62 { return position_; }
Point position_
position
Definition: BeamSpot.h:152
const BeamSpot::Point reco::BeamSpot::position ( const double  z) const

position of the beam spot at a given z value (it takes into account the dxdz and dydz slopes)

Definition at line 42 of file BeamSpot.cc.

42  {
43 
44  Point pos(x(z),y(z),z);
45  return pos;
46 
47  }
math::XYZPoint Point
double x(const double z) const
x coordinate of the beeam spot position at a given z value (it takes into account the dxdz slope) ...
Definition: BeamSpot.h:71
double y(const double z) const
y coordinate of the beeam spot position at a given z value (it takes into account the dydz slope) ...
Definition: BeamSpot.h:73
void reco::BeamSpot::print ( std::stringstream &  ss) const

print information

Definition at line 50 of file BeamSpot.cc.

References BeamSpotFakeParameters_cfi::betaStar, BeamSpotFakeParameters_cfi::dxdz, BeamSpotFakeParameters_cfi::dydz, BeamSpotFakeParameters_cfi::emittanceX, BeamSpotFakeParameters_cfi::emittanceY, and fftjetvertexadder_cfi::sigmaZ.

Referenced by reco::operator<<(), and setbetaStar().

50  {
51 
52  ss << "-----------------------------------------------------\n"
53  << " Beam Spot Data\n\n"
54  << " Beam type = " << type() << "\n"
55  << " X0 = " << x0() << " +/- " << x0Error() << " [cm]\n"
56  << " Y0 = " << y0() << " +/- " << y0Error() << " [cm]\n"
57  << " Z0 = " << z0() << " +/- " << z0Error() << " [cm]\n"
58  << " Sigma Z0 = " << sigmaZ() << " +/- " << sigmaZ0Error() << " [cm]\n"
59  << " dxdz = " << dxdz() << " +/- " << dxdzError() << " [radians]\n"
60  << " dydz = " << dydz() << " +/- " << dydzError() << " [radians]\n"
61  << " Beam width X = " << BeamWidthX() << " +/- " << BeamWidthXError() << " [cm]\n"
62  << " Beam width Y = " << BeamWidthY() << " +/- " << BeamWidthYError() << " [cm]\n"
63  << " EmittanceX = " << emittanceX() << " [cm]\n"
64  << " EmittanceY = " << emittanceY() << " [cm]\n"
65  << " beta-star = " << betaStar() << " [cm]\n"
66  << "-----------------------------------------------------\n\n";
67 
68  }
double z0() const
z coordinate
Definition: BeamSpot.h:68
double sigmaZ0Error() const
error on sigma z
Definition: BeamSpot.h:96
double dydzError() const
error on dydz
Definition: BeamSpot.h:100
double emittanceX() const
additional information
Definition: BeamSpot.h:136
double betaStar() const
Definition: BeamSpot.h:138
double dydz() const
dydz slope
Definition: BeamSpot.h:84
double emittanceY() const
Definition: BeamSpot.h:137
double dxdzError() const
error on dxdz
Definition: BeamSpot.h:98
double BeamWidthX() const
beam width X
Definition: BeamSpot.h:86
double BeamWidthYError() const
error on beam width Y, assume error in X = Y
Definition: BeamSpot.h:105
double BeamWidthXError() const
error on beam width X, assume error in X = Y
Definition: BeamSpot.h:103
double z0Error() const
error on z
Definition: BeamSpot.h:94
double dxdz() const
dxdz slope
Definition: BeamSpot.h:82
double x0Error() const
error on x
Definition: BeamSpot.h:90
double y0Error() const
error on y
Definition: BeamSpot.h:92
double sigmaZ() const
sigma z
Definition: BeamSpot.h:80
double BeamWidthY() const
beam width Y
Definition: BeamSpot.h:88
double y0() const
y coordinate
Definition: BeamSpot.h:66
BeamType type() const
return beam type
Definition: BeamSpot.h:129
double x0() const
x coordinate
Definition: BeamSpot.h:64
BeamSpot::Covariance3DMatrix reco::BeamSpot::rotatedCovariance3D ( ) const

Definition at line 78 of file BeamSpot.cc.

References BeamSpotFakeParameters_cfi::dxdz, BeamSpotFakeParameters_cfi::dydz, makeMuonMisalignmentScenario::matrix, funct::pow(), idealTransformation::rotation, fftjetvertexadder_cfi::sigmaZ, TkRotation< T >::xx(), TkRotation< T >::xy(), TkRotation< T >::xz(), TkRotation< T >::yx(), TkRotation< T >::yy(), TkRotation< T >::yz(), TkRotation< T >::zx(), TkRotation< T >::zy(), and TkRotation< T >::zz().

Referenced by GsfConstraintAtVertex::constrainAtBeamSpot(), pat::PATMuonProducer::embedHighLevel(), V0Fitter::fitAll(), PixelVertexProducer::produce(), PrimaryVertexProducer::produce(), setType(), and TrajectoryStateClosestToBeamLine::transverseImpactParameter().

79  {
80  AlgebraicVector3 newZ(dxdz(), dydz(), 1.);
81  AlgebraicVector3 globalZ(0.,0.,1.);
82  AlgebraicVector3 rotationAxis = ROOT::Math::Cross(globalZ.Unit(), newZ.Unit());
83  float rotationAngle = -acos( ROOT::Math::Dot(globalZ.Unit(),newZ.Unit()));
84  Basic3DVector<float> aa(rotationAxis[0],rotationAxis[1],rotationAxis[2]);
85  TkRotation<float> rotation(aa ,rotationAngle);
86  AlgebraicMatrix33 rotationMatrix;
87  rotationMatrix(0,0) = rotation.xx();
88  rotationMatrix(0,1) = rotation.xy();
89  rotationMatrix(0,2) = rotation.xz();
90  rotationMatrix(1,0) = rotation.yx();
91  rotationMatrix(1,1) = rotation.yy();
92  rotationMatrix(1,2) = rotation.yz();
93  rotationMatrix(2,0) = rotation.zx();
94  rotationMatrix(2,1) = rotation.zy();
95  rotationMatrix(2,2) = rotation.zz();
96 
97  AlgebraicSymMatrix33 diagError ;
98  diagError(0,0) = pow(BeamWidthX(),2);
99  diagError(1,1) = pow(BeamWidthY(),2);
100  diagError(2,2) = pow(sigmaZ(),2);
101 
103  matrix = ROOT::Math::Similarity(rotationMatrix, diagError) + covariance3D();
104  return matrix;
105  }
Covariance3DMatrix covariance3D() const
return only 3D position covariance matrix
Definition: BeamSpot.h:118
math::Error< dim3 >::type Covariance3DMatrix
Definition: BeamSpot.h:33
double dydz() const
dydz slope
Definition: BeamSpot.h:84
ROOT::Math::SMatrix< double, 3, 3, ROOT::Math::MatRepSym< double, 3 > > AlgebraicSymMatrix33
ROOT::Math::SVector< double, 3 > AlgebraicVector3
double BeamWidthX() const
beam width X
Definition: BeamSpot.h:86
double dxdz() const
dxdz slope
Definition: BeamSpot.h:82
double sigmaZ() const
sigma z
Definition: BeamSpot.h:80
double BeamWidthY() const
beam width Y
Definition: BeamSpot.h:88
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:40
ROOT::Math::SMatrix< double, 3, 3, ROOT::Math::MatRepStd< double, 3, 3 > > AlgebraicMatrix33
void reco::BeamSpot::setBeamWidthX ( double  v)
inline

Definition at line 108 of file BeamSpot.h.

References BeamWidthX_, and findQualityFiles::v.

Referenced by PVFitter::runBXFitter(), and PVFitter::runFitter().

108 { BeamWidthX_ = v; }
Double32_t BeamWidthX_
Definition: BeamSpot.h:157
void reco::BeamSpot::setBeamWidthY ( double  v)
inline
void reco::BeamSpot::setbetaStar ( double  v)
inline

Definition at line 145 of file BeamSpot.h.

References betaStar_, print(), and findQualityFiles::v.

Referenced by AlcaBeamSpotFromDB::endLuminosityBlockProduce().

145 { betaStar_ = v; }
Double32_t betaStar_
Definition: BeamSpot.h:163
void reco::BeamSpot::setEmittanceX ( double  v)
inline

Definition at line 143 of file BeamSpot.h.

References emittanceX_, and findQualityFiles::v.

Referenced by AlcaBeamSpotFromDB::endLuminosityBlockProduce().

143 { emittanceX_ = v; }
Double32_t emittanceX_
Definition: BeamSpot.h:161
void reco::BeamSpot::setEmittanceY ( double  v)
inline

Definition at line 144 of file BeamSpot.h.

References emittanceY_, and findQualityFiles::v.

Referenced by AlcaBeamSpotFromDB::endLuminosityBlockProduce().

144 { emittanceY_ = v; }
Double32_t emittanceY_
Definition: BeamSpot.h:162
void reco::BeamSpot::setType ( BeamType  type)
inline
double reco::BeamSpot::sigmaZ ( ) const
inline

sigma z

Definition at line 80 of file BeamSpot.h.

References sigmaZ_.

Referenced by PrimaryVertexMonitor::analyze(), MuonMiniAOD::analyze(), DiMuonHistograms::analyze(), RecoMuonValidator::analyze(), MuonKinVsEtaAnalyzer::analyze(), EfficiencyAnalyzer::analyze(), MuonRecoOneHLT::analyze(), PrimaryVertexValidation::analyze(), TrackerDpgAnalysis::analyze(), BeamSpot(), BeamSpotTransientTrackingRecHit::BeamSpotTransientTrackingRecHit(), AlcaBeamSpotManager::createWeightedPayloads(), beamspot::dumpBeamSpotTxt(), BeamFitter::dumpTxtFile(), TwoBodyDecayVirtualMeasurement::extractBeamSpotError(), BeamSpotHistogramMaker::fill(), TrackingNtuple::fillBeamSpot(), BeamMonitorBx::FillTables(), BeamMonitorBx::FillTrendHistos(), BSFitter::Fit(), BeamMonitor::FitAndFill(), MuonPFAnalyzer::getPrimaryVertex(), L1TMuonDQMOffline::getPrimaryVertex(), L1TTauOffline::getPrimaryVertex(), KFBasedPixelFitter::MyBeamSpotHit::MyBeamSpotHit(), VertexBeamspotOrigins::origins(), HIBestVertexProducer::produce(), AlCaGammaJetProducer::produce(), FFTJetVertexAdder::produce(), AlCaHBHEMuonProducer::produce(), TemplatedSecondaryVertexProducer< IPTI, VTX >::produce(), MuonTrackingRegionBuilder::region(), GlobalTrackingRegionProducerFromBeamSpot::regions(), GlobalTrackingRegionWithVerticesProducer::regions(), HITrackingRegionForPrimaryVtxProducer::regions(), CandidateSeededTrackingRegionsProducer::regions(), PointSeededTrackingRegionsProducer::regions(), BeamFitter::runFitterNoTxt(), BeamFitter::runPVandTrkFitter(), SeedFilter::seeds(), ElectronSeedGenerator::seedsFromThisCluster(), MultiTrackSelector::select(), HIMultiTrackSelector::select(), BeamMonitorBx::weight(), and BeamFitter::write2DB().

80 { return sigmaZ_; }
Double32_t sigmaZ_
Definition: BeamSpot.h:156
double reco::BeamSpot::sigmaZ0Error ( ) const
inline
BeamType reco::BeamSpot::type ( ) const
inline
double reco::BeamSpot::x ( const double  z) const
inline
double reco::BeamSpot::x0 ( ) const
inline

x coordinate

Definition at line 64 of file BeamSpot.h.

References position_.

Referenced by PrimaryVertexMonitor::analyze(), TrackBuildingAnalyzer::analyze(), SiPixelTrackResidualSource::analyze(), TkConvValidator::analyze(), PrimaryVertexValidation::analyze(), HLTExoticaSubAnalysis::analyze(), BPHMonitor::analyze(), TrackerDpgAnalysis::analyze(), HLTMuonDimuonL3Filter::applyMuonSelection(), HLTMuonL3PreFilter::applySelection(), BeamSpotTransientTrackingRecHit::BeamSpotTransientTrackingRecHit(), FWBeamSpotProxyBuilder::build(), TrackProducerAlgorithm< reco::Track >::buildTrack(), TrackProducerAlgorithm< reco::GsfTrack >::buildTrack(), PhotonIsolationCalculator::calculateTrackIso(), BPHMonitor::case11_selection(), TrackerSeedCleaner::clean(), GsfConstraintAtVertex::constrainAtBeamSpot(), ReferenceTrajectory::construct(), AlcaBeamSpotManager::createWeightedPayloads(), PF_PU_AssoMapAlgos::dR(), beamspot::dumpBeamSpotTxt(), BeamFitter::dumpTxtFile(), HLTObjectMonitor::dxyFinder(), HLTObjectsMonitor::dxyFinder(), MuonVPlusJetsIDSelectionFunctor::fall10Cuts(), BeamSpotHistogramMaker::fill(), TrackingNtuple::fillBeamSpot(), BeamMonitorBx::FillTables(), PrimaryVertexValidation::fillTrackHistos(), ApeEstimator::fillTrackVariables(), BeamMonitorBx::FillTrendHistos(), JetVertexChecker::filter(), SiStripElectronSeedGenerator::findSeedsFromCluster(), BSFitter::Fit(), BeamMonitor::FitAndFill(), getVertexD0(), HLTmumutkFilter::hltFilter(), HLTmumutktkFilter::hltFilter(), HLTDisplacedmumuFilter::hltFilter(), HLTDisplacedmumumuFilter::hltFilter(), HLTDisplacedtktkFilter::hltFilter(), HLTDisplacedtktktkFilter::hltFilter(), HLTMuonL3SimplePreFilter::hltFilter(), HLTMuonTrimuonL3Filter::hltFilter(), HLTmmkkFilter::hltFilter(), HLTmmkFilter::hltFilter(), AlignmentProducerBase::initBeamSpot(), MuonVPlusJetsIDSelectionFunctor::kitQCDCuts(), VertexBeamspotOrigins::origins(), HIBestVertexProducer::produce(), L2TauPixelTrackMatch::produce(), ConeIsolation::produce(), HIProtoTrackFilterProducer::produce(), MuonSeedGenerator::produce(), PixelVertexProducer::produce(), SETMuonSeedProducer::produce(), FFTJetVertexAdder::produce(), FastPrimaryVertexWithWeightsProducer::produce(), FastPrimaryVertexProducer::produce(), SteppingHelixPropagator::propagateWithPath(), TrackClassifier::reconstructionInformation(), MuonTrackingRegionBuilder::region(), GlobalTrackingRegionProducerFromBeamSpot::regions(), TrackingRegionsFromBeamSpotAndL2Tau::regions(), GlobalTrackingRegionWithVerticesProducer::regions(), HITrackingRegionForPrimaryVtxProducer::regions(), CandidateSeededTrackingRegionsProducer::regions(), PointSeededTrackingRegionsProducer::regions(), BeamFitter::runFitterNoTxt(), BeamFitter::runPVandTrkFitter(), PFDisplacedVertexHelper::setPrimaryVertex(), PFDisplacedVertexCandidateFinder::setPrimaryVertex(), MuonVPlusJetsIDSelectionFunctor::spring10Cuts(), QcdUeDQM::trackSelection(), MuonUpdatorAtVertex::update(), CosmicParametersDefinerForTP::vertex(), ParametersDefinerForTP::vertex(), PrimaryVertexMonitor::vertexPlots(), BeamMonitorBx::weight(), BSvsPVHistogramMaker::x(), x(), and FWBeamSpot::x0().

64 { return position_.X(); }
Point position_
position
Definition: BeamSpot.h:152
double reco::BeamSpot::x0Error ( ) const
inline
double reco::BeamSpot::y ( const double  z) const
inline
double reco::BeamSpot::y0 ( ) const
inline

y coordinate

Definition at line 66 of file BeamSpot.h.

References position_.

Referenced by PrimaryVertexMonitor::analyze(), TrackBuildingAnalyzer::analyze(), SiPixelTrackResidualSource::analyze(), TkConvValidator::analyze(), PrimaryVertexValidation::analyze(), HLTExoticaSubAnalysis::analyze(), BPHMonitor::analyze(), TrackerDpgAnalysis::analyze(), HLTMuonDimuonL3Filter::applyMuonSelection(), HLTMuonL3PreFilter::applySelection(), BeamSpotTransientTrackingRecHit::BeamSpotTransientTrackingRecHit(), FWBeamSpotProxyBuilder::build(), TrackProducerAlgorithm< reco::Track >::buildTrack(), TrackProducerAlgorithm< reco::GsfTrack >::buildTrack(), PhotonIsolationCalculator::calculateTrackIso(), BPHMonitor::case11_selection(), TrackerSeedCleaner::clean(), GsfConstraintAtVertex::constrainAtBeamSpot(), ReferenceTrajectory::construct(), AlcaBeamSpotManager::createWeightedPayloads(), PF_PU_AssoMapAlgos::dR(), beamspot::dumpBeamSpotTxt(), BeamFitter::dumpTxtFile(), HLTObjectMonitor::dxyFinder(), HLTObjectsMonitor::dxyFinder(), MuonVPlusJetsIDSelectionFunctor::fall10Cuts(), BeamSpotHistogramMaker::fill(), TrackingNtuple::fillBeamSpot(), BeamMonitorBx::FillTables(), PrimaryVertexValidation::fillTrackHistos(), ApeEstimator::fillTrackVariables(), BeamMonitorBx::FillTrendHistos(), JetVertexChecker::filter(), SiStripElectronSeedGenerator::findSeedsFromCluster(), BSFitter::Fit(), BeamMonitor::FitAndFill(), getVertexD0(), HLTmumutkFilter::hltFilter(), HLTmumutktkFilter::hltFilter(), HLTDisplacedmumuFilter::hltFilter(), HLTDisplacedmumumuFilter::hltFilter(), HLTDisplacedtktkFilter::hltFilter(), HLTDisplacedtktktkFilter::hltFilter(), HLTMuonL3SimplePreFilter::hltFilter(), HLTMuonTrimuonL3Filter::hltFilter(), HLTmmkkFilter::hltFilter(), HLTmmkFilter::hltFilter(), AlignmentProducerBase::initBeamSpot(), MuonVPlusJetsIDSelectionFunctor::kitQCDCuts(), VertexBeamspotOrigins::origins(), HIBestVertexProducer::produce(), L2TauPixelTrackMatch::produce(), ConeIsolation::produce(), HIProtoTrackFilterProducer::produce(), MuonSeedGenerator::produce(), PixelVertexProducer::produce(), SETMuonSeedProducer::produce(), FFTJetVertexAdder::produce(), FastPrimaryVertexWithWeightsProducer::produce(), FastPrimaryVertexProducer::produce(), SteppingHelixPropagator::propagateWithPath(), TrackClassifier::reconstructionInformation(), MuonTrackingRegionBuilder::region(), GlobalTrackingRegionProducerFromBeamSpot::regions(), TrackingRegionsFromBeamSpotAndL2Tau::regions(), GlobalTrackingRegionWithVerticesProducer::regions(), HITrackingRegionForPrimaryVtxProducer::regions(), CandidateSeededTrackingRegionsProducer::regions(), PointSeededTrackingRegionsProducer::regions(), BeamFitter::runFitterNoTxt(), BeamFitter::runPVandTrkFitter(), PFDisplacedVertexHelper::setPrimaryVertex(), PFDisplacedVertexCandidateFinder::setPrimaryVertex(), MuonVPlusJetsIDSelectionFunctor::spring10Cuts(), QcdUeDQM::trackSelection(), MuonUpdatorAtVertex::update(), CosmicParametersDefinerForTP::vertex(), ParametersDefinerForTP::vertex(), PrimaryVertexMonitor::vertexPlots(), BeamMonitorBx::weight(), BSvsPVHistogramMaker::y(), y(), and FWBeamSpot::y0().

66 { return position_.Y(); }
Point position_
position
Definition: BeamSpot.h:152
double reco::BeamSpot::y0Error ( ) const
inline
double reco::BeamSpot::z0 ( ) const
inline

z coordinate

Definition at line 68 of file BeamSpot.h.

References position_.

Referenced by PrimaryVertexMonitor::analyze(), TrackBuildingAnalyzer::analyze(), SiPixelTrackResidualSource::analyze(), PrimaryVertexValidation::analyze(), BPHMonitor::analyze(), TrackerDpgAnalysis::analyze(), HLTMuonDimuonL3Filter::applyMuonSelection(), HLTMuonL3PreFilter::applySelection(), BeamSpotTransientTrackingRecHit::BeamSpotTransientTrackingRecHit(), FWBeamSpotProxyBuilder::build(), TrackProducerAlgorithm< reco::GsfTrack >::buildTrack(), TrackProducerAlgorithm< reco::Track >::buildTrack(), PhotonIsolationCalculator::calculateTrackIso(), BPHMonitor::case11_selection(), TrackerSeedCleaner::clean(), GsfConstraintAtVertex::constrainAtBeamSpot(), ReferenceTrajectory::construct(), AlcaBeamSpotManager::createWeightedPayloads(), PF_PU_AssoMapAlgos::dR(), beamspot::dumpBeamSpotTxt(), BeamFitter::dumpTxtFile(), MuonVPlusJetsIDSelectionFunctor::fall10Cuts(), BeamSpotHistogramMaker::fill(), BSvsPVHistogramMaker::fill(), BeamMonitorBx::FillTables(), ApeEstimator::fillTrackVariables(), BeamMonitorBx::FillTrendHistos(), QcdUeDQM::fillVtxPlots(), JetVertexChecker::filter(), SiStripElectronSeedGenerator::findSeedsFromCluster(), BSFitter::Fit(), BeamMonitor::FitAndFill(), HLTmumutkFilter::hltFilter(), HLTmumutktkFilter::hltFilter(), HLTDisplacedmumuFilter::hltFilter(), HLTDisplacedmumumuFilter::hltFilter(), HLTDisplacedtktkFilter::hltFilter(), HLTDisplacedtktktkFilter::hltFilter(), HLTMuonL3SimplePreFilter::hltFilter(), HLTMuonTrimuonL3Filter::hltFilter(), HLTmmkkFilter::hltFilter(), HLTmmkFilter::hltFilter(), AlignmentProducerBase::initBeamSpot(), MuonVPlusJetsIDSelectionFunctor::kitQCDCuts(), VertexBeamspotOrigins::origins(), TSGFromPropagation::passSelection(), FastTSGFromPropagation::passSelection(), L2TauPixelTrackMatch::produce(), HIProtoTrackFilterProducer::produce(), MuonSeedGenerator::produce(), PixelVertexProducer::produce(), SETMuonSeedProducer::produce(), FFTJetVertexAdder::produce(), SteppingHelixPropagator::propagateWithPath(), TrackClassifier::reconstructionInformation(), MuonTrackingRegionBuilder::region(), GlobalTrackingRegionProducerFromBeamSpot::regions(), TrackingRegionsFromBeamSpotAndL2Tau::regions(), GlobalTrackingRegionWithVerticesProducer::regions(), HITrackingRegionForPrimaryVtxProducer::regions(), CandidateSeededTrackingRegionsProducer::regions(), PointSeededTrackingRegionsProducer::regions(), BeamFitter::runFitterNoTxt(), BeamFitter::runPVandTrkFitter(), PFDisplacedVertexHelper::setPrimaryVertex(), PFDisplacedVertexCandidateFinder::setPrimaryVertex(), MuonVPlusJetsIDSelectionFunctor::spring10Cuts(), QcdUeDQM::trackSelection(), MuonUpdatorAtVertex::update(), CosmicParametersDefinerForTP::vertex(), ParametersDefinerForTP::vertex(), PrimaryVertexMonitor::vertexPlots(), BeamMonitorBx::weight(), BSvsPVHistogramMaker::x(), x(), BSvsPVHistogramMaker::y(), y(), and FWBeamSpot::z0().

68 { return position_.Z(); }
Point position_
position
Definition: BeamSpot.h:152
double reco::BeamSpot::z0Error ( ) const
inline

Member Data Documentation

Double32_t reco::BeamSpot::BeamWidthX_
private

Definition at line 157 of file BeamSpot.h.

Referenced by BeamSpot(), BeamWidthX(), and setBeamWidthX().

Double32_t reco::BeamSpot::BeamWidthY_
private

Definition at line 158 of file BeamSpot.h.

Referenced by BeamSpot(), BeamWidthY(), and setBeamWidthY().

Double32_t reco::BeamSpot::betaStar_
private

Definition at line 163 of file BeamSpot.h.

Referenced by BeamSpot(), beamWidthFromBeta(), betaStar(), and setbetaStar().

Double32_t reco::BeamSpot::dxdz_
private

Definition at line 159 of file BeamSpot.h.

Referenced by BeamSpot(), and dxdz().

Double32_t reco::BeamSpot::dydz_
private

Definition at line 160 of file BeamSpot.h.

Referenced by BeamSpot(), and dydz().

Double32_t reco::BeamSpot::emittanceX_
private

Definition at line 161 of file BeamSpot.h.

Referenced by BeamSpot(), emittanceX(), and setEmittanceX().

Double32_t reco::BeamSpot::emittanceY_
private

Definition at line 162 of file BeamSpot.h.

Referenced by BeamSpot(), emittanceY(), and setEmittanceY().

CovarianceMatrix reco::BeamSpot::error_
private
Point reco::BeamSpot::position_
private

position

Definition at line 152 of file BeamSpot.h.

Referenced by BeamSpot(), beamWidthFromBeta(), position(), x0(), y0(), and z0().

Double32_t reco::BeamSpot::sigmaZ_
private

Definition at line 156 of file BeamSpot.h.

Referenced by BeamSpot(), and sigmaZ().

BeamType reco::BeamSpot::type_
private