Heavy ion Analysis Libriares
Loading...
Searching...
No Matches
V0CandidateHelix.cxx
1/*
2 * V0CandidateHelix.cpp
3 *
4 * Created on: 26 mar 2020
5 * Author: Daniel Wielanek
6 * E-mail: daniel.wielanek@gmail.com
7 * Warsaw University of Technology, Faculty of Physics
8 */
9#include "V0CandidateHelix.h"
10
11#include "ExpEvent.h"
12#include "ExpTrack.h"
13#include "Helix.h"
14
15namespace Hal {
16 V0CandidateHelix::V0CandidateHelix() {}
17
18 void V0CandidateHelix::MakeV0(Double_t /*mPos*/, Double_t /*mNeg*/, Int_t pidThis, Int_t pidPos, Int_t pidNeg) {
19 fV0Track.SetPosId(GetTrack1()->GetThisID());
20 fV0Track.SetNegId(GetTrack2()->GetThisID());
21 const Helix& helix1 = static_cast<ExpTrackHelix*>(GetTrack1())->GetHelix();
22 const Helix& helix2 = static_cast<ExpTrackHelix*>(GetTrack2())->GetHelix();
23 fV0Track.SetPdg(pidThis);
24 fV0Track.SetPdgDaughters(pidPos, pidNeg);
25 Double_t s1, s2;
26 helix1.PathLengths(helix2, s1, s2);
27 fV0Track.SetS(s1, s2);
28 TVector3 pPos, pNeg, poz1, poz2;
29 helix1.EvaluateFull(s1, pPos, poz1);
30 helix2.EvaluateFull(s2, pNeg, poz2);
31
32 fV0Track.SetMomPos(pPos.Px(), pPos.Py(), pPos.Pz());
33 fV0Track.SetMomNeg(pNeg.Px(), pNeg.Py(), pNeg.Pz());
34
35 TVector3 pozV0 = (poz1 + poz2) * 0.5;
36 fV0Track.SetDauDist((poz1 - poz2).Mag());
37 fV0Track.SetDecayPos(pozV0.X(), pozV0.Y(), pozV0.Z());
38 TVector3 vertex = static_cast<ExpEvent*>(GetTrack1()->GetEvent())->GetVertex()->Vect();
39 fDCA = fV0Track.Recalc(*GetTrack1());
40 }
41
42 V0CandidateHelix::~V0CandidateHelix() {}
43} // namespace Hal
void PathLengths(const HelixBase &h, Double_t &s1, Double_t &s2) const
void EvaluateFull(Double_t s, TVector3 &mom, TVector3 &pos) const
Definition Helix.h:68
Event * GetEvent() const
Definition Track.h:315
Track * GetTrack1() const
Definition TwoTrack.h:75
Track * GetTrack2() const
Definition TwoTrack.h:80
void MakeV0(Double_t mPos, Double_t mNeg, Int_t pidThis, Int_t pidPos, Int_t pidNeg)
void SetMomPos(Double_t px, Double_t py, Double_t pz)
Definition V0Track.cxx:66
void SetDauDist(Double_t dauDist)
Definition V0Track.h:239
void SetPosId(Int_t posId)
Definition V0Track.h:141
void SetNegId(Int_t negId)
Definition V0Track.h:136
void SetMomNeg(Double_t px, Double_t py, Double_t pz)
Definition V0Track.cxx:68
void SetPdg(Int_t pid)
Definition V0Track.h:131
void SetPdgDaughters(Int_t pos, Int_t neg)
Definition V0Track.h:123
void SetDecayPos(Double_t x, Double_t y, Double_t z)
Definition V0Track.cxx:42
TVector3 Recalc(const Track &track)
Definition V0Track.cxx:44
void SetS(Double_t s1, Double_t s2)
Definition V0Track.h:114