CMS 3D CMS Logo

KinematicParticleFactoryFromTransientTrack.cc
Go to the documentation of this file.
2 
5 }
6 
8  if (pr != nullptr) {
9  propagator = pr->clone();
10  } else {
12  }
13 }
14 
16  const reco::TransientTrack& initialTrack,
17  const ParticleMass& massGuess,
18  float chiSquared,
19  float degreesOfFr,
20  float& m_sigma) const {
21  // cout<<"calling the state builder"<<endl;
22  KinematicState initState = builder(initialTrack, massGuess, m_sigma);
23  const reco::TransientTrack* track = &initialTrack;
24  KinematicConstraint* lastConstraint = nullptr;
25  ReferenceCountingPointer<KinematicParticle> previousParticle = nullptr;
27  initState, chiSquared, degreesOfFr, lastConstraint, previousParticle, propagator, track));
28 }
29 
31  const reco::TransientTrack& initialTrack,
32  const ParticleMass& massGuess,
33  float chiSquared,
34  float degreesOfFr,
35  float& m_sigma,
36  const FreeTrajectoryState& freestate) const {
37  // cout<<"calling the state builder"<<endl;
38  KinematicState initState = builder(freestate, massGuess, m_sigma);
39  const reco::TransientTrack* track = &initialTrack;
40  KinematicConstraint* lastConstraint = nullptr;
41  ReferenceCountingPointer<KinematicParticle> previousParticle = nullptr;
43  initState, chiSquared, degreesOfFr, lastConstraint, previousParticle, propagator, track));
44 }
45 
47  const reco::TransientTrack& initialTrack,
48  const ParticleMass& massGuess,
49  float chiSquared,
50  float degreesOfFr,
51  const GlobalPoint& expPoint,
52  float m_sigma) const {
53  // FreeTrajectoryState st(initialTrack.impactPointTSCP().theState());
54  KinematicState initState = builder(initialTrack.impactPointTSCP().theState(), massGuess, m_sigma, expPoint);
55  const reco::TransientTrack* track = &initialTrack;
56  KinematicConstraint* lastConstraint = nullptr;
57  ReferenceCountingPointer<KinematicParticle> previousParticle = nullptr;
59  initState, chiSquared, degreesOfFr, lastConstraint, previousParticle, propagator, track));
60 }
61 
63  const KinematicState& kineState,
64  float& chiSquared,
65  float& degreesOfFr,
67  KinematicConstraint* lastConstraint) const {
69  KinematicParticle* prp = &(*previousParticle);
70  // FIXME
71  // if(previousParticle.isValid()){
73  if (pr == nullptr) {
74  throw VertexException(
75  "KinematicParticleFactoryFromTransientTrack::Previous particle passed is not TransientTrack based!");
76  } else {
77  track = pr->initialTransientTrack();
78  }
79  // }else{track = 0;}
81  kineState, chiSquared, degreesOfFr, lastConstraint, previousParticle, propagator, track));
82 }
Common base class.
double ParticleMass
Definition: ParticleMass.h:4
TrajectoryStateClosestToPoint impactPointTSCP() const
RefCountedKinematicParticle particle(const reco::TransientTrack &initialTrack, const ParticleMass &massGuess, float chiSquared, float degreesOfFr, float &m_sigma) const
const FreeTrajectoryState & theState() const