ATLAS Offline Software
HGTD_ClusterMakerTool.cxx
Go to the documentation of this file.
1 
11 #include "HGTD_ClusterMakerTool.h"
12 
14 
15 // usable in the current file only
16 namespace {
17 inline double square(const double x) { return x * x; }
18 
19 constexpr double g_one_over_twelve = 1. / 12.;
20 } // namespace
21 
23  const std::string& n,
24  const IInterface* p)
25  : AthAlgTool(t, n, p) {}
26 
28  const Identifier& rdo_id,
29  const Amg::Vector2D& loc_pos,
30  std::vector<Identifier>&& rdo_list,
31  const InDet::SiWidth& width,
33  const float time_of_arrival,
34  std::vector<int>&& time_over_threshold) const {
35 
36  Amg::MatrixX loc_err_matx = Amg::MatrixX(2, 2);
37  loc_err_matx.setIdentity();
38  // HGTD pixels are 1.3x1.3 mm2, using phiR and z methods for
39  // consistency with other code
40  loc_err_matx.fillSymmetric(0, 0, square(width.phiR()) * g_one_over_twelve);
41  loc_err_matx.fillSymmetric(1, 1, square(width.z()) * g_one_over_twelve);
42 
43  // time_of_arrival_err
44  // FIXME: to define the expected time resolution, I should have a service that
45  // tells me which resolution I expect, depending on the radius and after
46  // the current integrated luminosity
47  float time_of_arrival_err =
48  0.035; // 35 pico second resolution at start of operation, given in nano
49  // seconds in ATHENA
50 
51  return {rdo_id,
52  loc_pos,
53  std::move(rdo_list),
54  width,
55  det_el,
56  std::move(loc_err_matx),
57  time_of_arrival,
58  time_of_arrival_err,
59  std::move(time_over_threshold)};
60 }
Amg::MatrixX
Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > MatrixX
Dynamic Matrix - dynamic allocation.
Definition: EventPrimitives.h:29
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
HGTD_ClusterMakerTool.h
Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration.
InDetDD::SolidStateDetectorElementBase
Definition: SolidStateDetectorElementBase.h:132
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
x
#define x
HGTD_Cluster.h
Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration.
HGTD_Cluster
Definition: HGTD_Cluster.h:35
HGTD_ClusterMakerTool::HGTD_ClusterMakerTool
HGTD_ClusterMakerTool(const std::string &, const std::string &, const IInterface *)
Definition: HGTD_ClusterMakerTool.cxx:22
Identifier
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:32
beamspotman.n
n
Definition: beamspotman.py:731
Base_Fragment.width
width
Definition: Sherpa_i/share/common/Base_Fragment.py:59
InDet::SiWidth
Definition: SiWidth.h:25
HGTD_ClusterMakerTool::createCluster
HGTD_Cluster createCluster(const Identifier &rdo_id, const Amg::Vector2D &loc_pos, std::vector< Identifier > &&rdo_list, const InDet::SiWidth &width, const InDetDD::SolidStateDetectorElementBase *det_el, const float time_of_arrival, std::vector< int > &&time_over_threshold) const
Builds a HGTD_Cluster.
Definition: HGTD_ClusterMakerTool.cxx:27
AthAlgTool
Definition: AthAlgTool.h:26