PandaRoot
FTSCATarget.h
Go to the documentation of this file.
1 //****************************************************************************
2 //* This file is part of PandaRoot. *
3 //* *
4 //* PandaRoot is distributed under the terms of the *
5 //* GNU General Public License (GPL) version 3, *
6 //* copied verbatim in the file "LICENSE". *
7 //* *
8 //* Copyright (C) 2006 - 2024 FAIR GmbH and copyright holders of PandaRoot *
9 //* The copyright holders are listed in the file "COPYRIGHTHOLDERS". *
10 //* The authors are listed in the file "AUTHORS". *
11 //****************************************************************************
12 
13 //-*- Mode: C++ -*-
14 // *****************************************************************************
15 // *
16 // @Autors: I.Kulakov; M.Pugach; M.Zyzak; I.Kisel *
17 // @e-mail: I.Kulakov@gsi.de; M.Pugach@gsi.de; M.Zyzak@gsi.de; I.Kisel@compeng.uni-frankfurt.de *
18 // *
19 // *****************************************************************************
20 
21 #ifndef FTSCATARGET_H
22 #define FTSCATARGET_H
23 
24 #include "PndFTSCATrackParam.h"
25 #include "PndFTSCAParam.h"
26 #include "CAFieldValue.h"
27 
28 class FTSCATarget {
29 
36  public:
37  FTSCATarget() : fX0(0), fX1(0), fX2(0), fDX1(-1), fDX2(-1), fDQMom(-1), fB(), fNDF(-1){};
38  FTSCATarget(const float &x0, const float &x1, const float &x2, const float &dx1, const float &dx2, const float &dqmom, const PndFTSCAParam &param, const int &ndf)
39  : fX0(x0), fX1(x1), fX2(x2), fDX1(dx1), fDX2(dx2), fDQMom(dqmom), fNDF(ndf)
40  {
41  fB[0] = param.VtxFieldValue(0);
42  fZB[0] = param.ZVtxFieldValue(0);
43  fB[1] = param.VtxFieldValue(1);
44  fZB[1] = param.ZVtxFieldValue(1);
45  };
46 
47  float SetErrQMom(float v) { return fDQMom = v; }
48 
49  float X0() const { return fX0; }
50  float X1() const { return fX1; }
51  float X2() const { return fX2; }
52 
53  float Err2X1() const { return fDX1 * fDX1; }
54  float Err2X2() const { return fDX2 * fDX2; }
55  float Err2QMom() const { return fDQMom * fDQMom; }
56  float DQMom() const { return fDQMom * fDQMom; }
57  const CAFieldValue &B(int i = 0) const { return fB[i]; }
58  const float_v &ZB(int i) const { return fZB[i]; }
59  int NDF() const { return fNDF; }
60 
61  private:
62  float fX0, fX1, fX2, fDX1, fDX2, fDQMom;
63 
64  CAFieldValue fB[2];
65  float_v fZB[2]; // fZ position of the field point
66 
67  int fNDF; // 0 or 2, depends whether we consider target as a measurement
68 };
69 
70 #endif
float DQMom() const
Definition: FTSCATarget.h:56
const float_v & ZB(int i) const
Definition: FTSCATarget.h:58
float X0() const
Definition: FTSCATarget.h:49
float SetErrQMom(float v)
Definition: FTSCATarget.h:47
float Err2QMom() const
Definition: FTSCATarget.h:55
__m128 v
Definition: P4_F32vec4.h:15
unsigned int i
Definition: P4_F32vec4.h:33
float X1() const
Definition: FTSCATarget.h:50
const CAFieldValue & VtxFieldValue(int i=0) const
float Err2X1() const
Definition: FTSCATarget.h:53
int NDF() const
Definition: FTSCATarget.h:59
const float_v & ZVtxFieldValue(int i) const
float X2() const
Definition: FTSCATarget.h:51
const CAFieldValue & B(int i=0) const
Definition: FTSCATarget.h:57
FTSCATarget(const float &x0, const float &x1, const float &x2, const float &dx1, const float &dx2, const float &dqmom, const PndFTSCAParam &param, const int &ndf)
Definition: FTSCATarget.h:38
float Err2X2() const
Definition: FTSCATarget.h:54