CbmRoot
Loading...
Searching...
No Matches
HalCbmHbtTrack.cxx
Go to the documentation of this file.
1
/* Copyright (C) 2023-2023 Warsaw University of Technology, Warsaw
2
SPDX-License-Identifier: GPL-3.0-only
3
Authors: Daniel Wielanek [committer] */
4
#include "
HalCbmHbtTrack.h
"
5
6
#include "
HalCbmHbtEvent.h
"
7
#include "
HalCbmTrack.h
"
8
9
#include <Hal/Event.h>
10
11
12
HalCbmHbtTrack::HalCbmHbtTrack
() :
Hal
::ExpTrack(), fHelix(
CbmHelix
()), fR(-1) {}
13
14
HalCbmHbtTrack::~HalCbmHbtTrack
() {}
15
16
HalCbmHbtTrack::HalCbmHbtTrack
(
const
HalCbmHbtTrack
& other) :
Hal
::ExpTrack(other)
17
{
18
fHelix
= other.
fHelix
;
19
fR
= other.
fR
;
20
for
(
int
i = 0; i < 9; i++) {
21
fPosAt
[i] = other.
fPosAt
[i];
22
fMomAt
[i] = other.
fMomAt
[i];
23
}
24
fPosAtCustom
= other.
fPosAtCustom
;
25
fMomAtCustom
= other.
fMomAtCustom
;
26
}
27
28
HalCbmHbtTrack
&
HalCbmHbtTrack::operator=
(
const
HalCbmHbtTrack
& other)
29
{
30
if
(
this
== &other)
return
*
this
;
31
Hal::ExpTrack::operator=(other);
32
fHelix
= other.
fHelix
;
33
fR
= other.
fR
;
34
for
(
int
i = 0; i < 9; i++) {
35
fPosAt
[i] = other.
fPosAt
[i];
36
fMomAt
[i] = other.
fMomAt
[i];
37
}
38
fPosAtCustom
= other.
fPosAtCustom
;
39
fMomAtCustom
= other.
fMomAtCustom
;
40
return
*
this
;
41
}
42
43
void
HalCbmHbtTrack::CopyData
(Hal::Track* other)
44
{
45
Hal::ExpTrack::CopyData(other);
46
fHelix
= ((
HalCbmTrack
*) other)->GetHelix();
47
Double_t
x
= GetEvent()->GetVertex()->
X
();
48
Double_t
y
= GetEvent()->GetVertex()->Y();
49
Double_t z = GetEvent()->GetVertex()->Z();
50
const
Double_t R[9] = {20, 30, 40, 50, 60, 70, 80, 90, 100};
51
for
(
int
i = 0; i < 9; i++) {
52
fPosAt
[i] =
fHelix
.
Eval
(R[i] + z,
fMomAt
[i]);
53
fPosAt
[i] -= TVector3(
x
,
y
, z);
54
}
55
fR
= -1;
56
}
57
58
void
HalCbmHbtTrack::CalculateAtR
(Double_t R)
59
{
60
if
(
fR
== R)
return
;
61
Double_t
x
= GetEvent()->GetVertex()->X();
62
Double_t
y
= GetEvent()->GetVertex()->Y();
63
Double_t z = GetEvent()->GetVertex()->Z();
64
fPosAtCustom
=
GetHelix
().
Eval
(z + R,
fMomAtCustom
);
65
fPosAtCustom
-= TVector3(
x
,
y
, z);
66
fR
= R;
67
}
y
Double_t y
Definition
CbmMvdSensorDigiToHitTask.cxx:64
x
Double_t x
Definition
CbmMvdSensorDigiToHitTask.cxx:64
HalCbmHbtEvent.h
HalCbmHbtTrack.h
HalCbmTrack.h
CbmHelix
Definition
CbmHelix.h:22
CbmHelix::X
Double_t X() const
Definition
CbmHelix.h:27
CbmHelix::Eval
TVector3 Eval(Double_t z)
Definition
CbmHelix.cxx:31
HalCbmHbtTrack
Definition
HalCbmHbtTrack.h:18
HalCbmHbtTrack::fPosAt
TVector3 fPosAt[9]
Definition
HalCbmHbtTrack.h:19
HalCbmHbtTrack::GetHelix
CbmHelix & GetHelix()
Definition
HalCbmHbtTrack.h:39
HalCbmHbtTrack::fMomAtCustom
TVector3 fMomAtCustom
Definition
HalCbmHbtTrack.h:22
HalCbmHbtTrack::~HalCbmHbtTrack
virtual ~HalCbmHbtTrack()
Definition
HalCbmHbtTrack.cxx:14
HalCbmHbtTrack::fMomAt
TVector3 fMomAt[9]
Definition
HalCbmHbtTrack.h:20
HalCbmHbtTrack::fR
Double_t fR
Definition
HalCbmHbtTrack.h:24
HalCbmHbtTrack::fHelix
CbmHelix fHelix
Definition
HalCbmHbtTrack.h:23
HalCbmHbtTrack::fPosAtCustom
TVector3 fPosAtCustom
Definition
HalCbmHbtTrack.h:21
HalCbmHbtTrack::HalCbmHbtTrack
HalCbmHbtTrack()
Definition
HalCbmHbtTrack.cxx:12
HalCbmHbtTrack::operator=
HalCbmHbtTrack & operator=(const HalCbmHbtTrack &other)
Definition
HalCbmHbtTrack.cxx:28
HalCbmHbtTrack::CalculateAtR
void CalculateAtR(Double_t R)
Definition
HalCbmHbtTrack.cxx:58
HalCbmHbtTrack::CopyData
virtual void CopyData(Hal::Track *other)
Definition
HalCbmHbtTrack.cxx:43
HalCbmTrack
Definition
HalCbmTrack.h:25
Hal
Definition
HalCbmPairSeparationCut2D.h:11
analysis
PWGC2F
femtoscopy
hal
format
anatree
femto
HalCbmHbtTrack.cxx
Generated on Sun Dec 22 2024 23:04:05 for CbmRoot by
1.12.0