#include <TrkTrackState.h>
◆ TrkTrackState() [1/3]
| TrkTrackState::TrkTrackState |
( |
| ) |
|
Definition at line 28 of file TrkTrackState.cxx.
35}
TrkPlanarSurface * m_pSurface
TrkTrackState * m_pPrevState
◆ TrkTrackState() [2/3]
| TrkTrackState::TrkTrackState |
( |
const double | Rk[5] | ) |
|
◆ TrkTrackState() [3/3]
Definition at line 61 of file TrkTrackState.cxx.
61 {
62 for (
int i = 0;
i < 5;
i++) {
64 }
65 for (
int i = 0;
i < 5;
i++)
66 for (
int j = 0; j < 5; j++)
m_Gk[i][j] = pTS->
m_Gk[i][j];
71 }
◆ ~TrkTrackState()
| Trk::TrkTrackState::~TrkTrackState |
( |
| ) |
|
|
inline |
◆ applyEnergyLoss()
| void TrkTrackState::applyEnergyLoss |
( |
int | dir | ) |
|
Definition at line 186 of file TrkTrackState.cxx.
186 {
187 double lenCorr, effLength, lV[3], gV[3];
189
190 if (pS == nullptr) return;
191
196 lenCorr = 1.0 / fabs(lV[2]);
197 effLength =
m_pSurface->getRadLength() * lenCorr;
198
199 if (abs(dir) == 1) {
200 m_Re[4] +=
dir * (
m_Re[4] * effLength * (1.0 - 0.5 * effLength));
201 m_Ge[4][4] +=
m_Re[4] *
m_Re[4] * effLength * (0.415 - 0.744 * effLength);
204 } else if (abs(dir) == 2) {
208 }
209 }
void rotateVectorToLocal(double *, double *)
◆ applyMaterialEffects()
| void TrkTrackState::applyMaterialEffects |
( |
| ) |
|
Definition at line 211 of file TrkTrackState.cxx.
211 {
217 }
218 }
void applyMultipleScattering()
void applyEnergyLoss(int)
◆ applyMultipleScattering()
| void TrkTrackState::applyMultipleScattering |
( |
| ) |
|
Definition at line 160 of file TrkTrackState.cxx.
160 {
161 double lenCorr, sigmaMS,
s2, a2, radLength, lV[3], gV[3],
a;
163
164 if (pS == nullptr) return;
165
170 lenCorr = 1.0 / fabs(lV[2]);
171 radLength =
m_pSurface->getRadLength() * lenCorr;
172 sigmaMS = 13.6 * fabs(
m_Re[4]) * sqrt(radLength) * (1.0 + 0.038 *
log(radLength));
173 s2 = sigmaMS * sigmaMS;
184 }
◆ attachToSurface()
◆ getScatteringMode()
| int TrkTrackState::getScatteringMode |
( |
| ) |
const |
◆ getStateSize()
| int Trk::TrkTrackState::getStateSize |
( |
| ) |
|
|
inline |
◆ getSurface()
◆ getTrackCovariance()
| double Trk::TrkTrackState::getTrackCovariance |
( |
int | i, |
|
|
int | j ) |
|
inline |
◆ getTrackState()
| double Trk::TrkTrackState::getTrackState |
( |
int | i | ) |
|
|
inline |
◆ report()
| void TrkTrackState::report |
( |
| ) |
|
Definition at line 91 of file TrkTrackState.cxx.
91 {
92 printf("STATE x0=%f y0=%f phi=%f theta=%f qOverP=%f pT=%f\n",
94 printf("COVARIANCE \n");
95 for (
auto & i :
m_Gk) {
96 for (double j : i) {
97 printf("%E ", j);
98 }
99 printf("\n");
100 }
101 }
◆ resetCovariance()
| void TrkTrackState::resetCovariance |
( |
| ) |
|
◆ runSmoother()
| void TrkTrackState::runSmoother |
( |
| ) |
|
Definition at line 220 of file TrkTrackState.cxx.
220 {
221 double dR[5], dG[5][5],
B[5][5];
223
225
226 for (i = 0;
i < 5;
i++) {
228 for (j = 0; j < 5; j++) dG[i][j] =
m_Gk[i][j] -
m_Ge[i][j];
229 }
230
231 if (dR[2] >
M_PI) dR[2] -= 2 *
M_PI;
232 if (dR[2] < -
M_PI) dR[2] += 2 *
M_PI;
233 for (i = 0;
i < 5;
i++) {
235 }
236
241 for (i = 0;
i < 5;
i++)
242 for (j = 0; j < 5; j++) {
244 for (m = 0;
m < 5;
m++) B[i][j] +=
m_A[i][m] * dG[m][j];
245 }
246 for (i = 0;
i < 5;
i++)
247 for (j = 0; j < 5; j++) {
248 for (m = 0;
m < 5;
m++)
250 }
251 }
◆ serialize()
| void TrkTrackState::serialize |
( |
char | fileName[] | ) |
|
Definition at line 73 of file TrkTrackState.cxx.
73 {
74 FILE* pFile = fopen(fileName, "a");
75 if (!pFile) {
76 std::cerr <<
"Cannot open file " <<
fileName <<
" for write.\n";
77 std::abort();
78 }
79 fprintf(pFile, "%f %f %f %f %f\n",
81 for (
int i = 0;
i < 5;
i++) {
82 for (int j = 0; j < 5; j++) {
83 if (j < i) fprintf(pFile, " ");
85 }
86 fprintf(pFile, "\n");
87 }
88 fclose(pFile);
89 }
double getTrackCovariance(int i, int j)
◆ setPreviousState()
◆ setScatteringMode()
| void TrkTrackState::setScatteringMode |
( |
int | mode | ) |
|
◆ setSmootherGain()
| void TrkTrackState::setSmootherGain |
( |
double | A[5][5] | ) |
|
Definition at line 154 of file TrkTrackState.cxx.
154 {
155 for (
int i = 0;
i < 5;
i++)
156 for (int j = 0; j < 5; j++)
158 }
◆ setTrackCovariance()
| void TrkTrackState::setTrackCovariance |
( |
double | A[5][5] | ) |
|
Definition at line 144 of file TrkTrackState.cxx.
144 {
145 for (
int i = 0;
i < 5;
i++)
146 for (int j = 0; j < 5; j++)
148 }
◆ setTrackState()
| void TrkTrackState::setTrackState |
( |
const double | A[5] | ) |
|
◆ updateTrackCovariance()
| void TrkTrackState::updateTrackCovariance |
( |
const double * | pUpd | ) |
|
Definition at line 120 of file TrkTrackState.cxx.
120 {
122
123 for (
int i = 0;
i < 5;
i++) {
124 for (int j = i; j < 5; j++) {
128 }
129 }
130 }
◆ updateTrackState()
| void TrkTrackState::updateTrackState |
( |
const double * | pUpd | ) |
|
◆ m_A
| double Trk::TrkTrackState::m_A[5][5] {} |
|
protected |
◆ m_Ge
| double Trk::TrkTrackState::m_Ge[5][5] {} |
|
protected |
◆ m_Gk
| double Trk::TrkTrackState::m_Gk[5][5] {} |
|
protected |
◆ m_isScattered
| bool Trk::TrkTrackState::m_isScattered |
|
protected |
◆ m_pPrevState
◆ m_pSurface
◆ m_Re
| double Trk::TrkTrackState::m_Re[5] {} |
|
protected |
◆ m_Rk
| double Trk::TrkTrackState::m_Rk[5] {} |
|
protected |
◆ m_scattMode
| int Trk::TrkTrackState::m_scattMode |
|
protected |
The documentation for this class was generated from the following files: