File indexing completed on 2024-04-06 12:29:07
0001 #ifndef MultiRefittedTS_H
0002 #define MultiRefittedTS_H
0003
0004 #include "RecoVertex/VertexPrimitives/interface/RefittedTrackState.h"
0005 #include "DataFormats/GeometrySurface/interface/ReferenceCounted.h"
0006 #include "RecoVertex/VertexPrimitives/interface/LinearizedTrackState.h"
0007 #include "DataFormats/GeometrySurface/interface/Surface.h"
0008
0009
0010
0011
0012
0013
0014
0015 class Surface;
0016
0017 class MultiRefittedTS : public RefittedTrackState<5> {
0018 public:
0019 typedef ReferenceCountingPointer<RefittedTrackState<5> > RefCountedRefittedTrackState;
0020 typedef ReferenceCountingPointer<LinearizedTrackState<5> > RefCountedLinearizedTrackState;
0021
0022
0023
0024
0025
0026 MultiRefittedTS(const std::vector<RefCountedRefittedTrackState>& prtsComp, const Surface& referenceSurface);
0027
0028
0029
0030
0031
0032
0033 MultiRefittedTS(const std::vector<RefCountedRefittedTrackState>& prtsComp, const GlobalPoint& referencePosition);
0034
0035 ~MultiRefittedTS() override {}
0036
0037
0038
0039
0040
0041
0042 FreeTrajectoryState freeTrajectoryState() const override;
0043
0044
0045
0046
0047 TrajectoryStateOnSurface trajectoryStateOnSurface(const Surface& surface) const override;
0048
0049
0050
0051
0052
0053 TrajectoryStateOnSurface trajectoryStateOnSurface(const Surface& surface,
0054 const Propagator& propagator) const override;
0055
0056
0057
0058
0059
0060
0061 reco::TransientTrack transientTrack() const override;
0062
0063
0064
0065
0066
0067
0068 AlgebraicVectorN parameters() const override;
0069
0070
0071
0072
0073
0074
0075 AlgebraicSymMatrixNN covariance() const override;
0076
0077
0078
0079
0080
0081
0082 GlobalPoint position() const override;
0083
0084
0085
0086
0087
0088
0089
0090 AlgebraicVectorM momentumVector() const override;
0091
0092 double weight() const override;
0093
0094 std::vector<ReferenceCountingPointer<RefittedTrackState<5> > > components() const override { return theComponents; }
0095
0096
0097
0098
0099
0100
0101
0102
0103
0104 ReferenceCountingPointer<RefittedTrackState<5> > stateWithNewWeight(const double newWeight) const override;
0105
0106 private:
0107 void computeFreeTrajectoryState() const;
0108
0109 typedef std::vector<RefCountedRefittedTrackState> RTSvector;
0110
0111 mutable RTSvector theComponents;
0112 mutable bool totalWeightAvailable, ftsAvailable;
0113 mutable double totalWeight;
0114 mutable FreeTrajectoryState fts;
0115 const GlobalPoint refPosition;
0116 ConstReferenceCountingPointer<Surface> refSurface;
0117 const bool surf;
0118 };
0119 #endif