26 using namespace mkfit;
29 float getTheta(
float r,
float z) {
return std::atan2(r, z); }
40 class CylCowWLidsCreator {
43 static constexpr float m_det_half_thickness = 0.005;
47 void add_barrel(
int lid,
float r,
float z,
float eta) {
54 li.
set_limits(r - m_det_half_thickness, r + m_det_half_thickness, -z, z);
60 void add_barrel_r_eta(
int lid,
float r,
float eta) {
61 float z =
r / getTgTheta(
eta);
63 add_barrel(lid, r, z,
eta);
66 void add_barrel_r_z(
int lid,
float r,
float z) {
69 add_barrel(lid, r, z,
eta);
72 void add_endcap(
int lid,
float r,
float z,
float eta) {
73 float r_end =
z * getTgTheta(
eta);
82 li.
set_limits(r_end, r, z - m_det_half_thickness, z + m_det_half_thickness);
93 li.
set_limits(r_end, r, -z - m_det_half_thickness, -z + m_det_half_thickness);
103 CylCowWLidsCreator(
TrackerInfo& ti) : m_trkinfo(ti) {}
105 void FillTrackerInfo() {
109 float full_eta = 2.5;
110 float full_eta_pix_0 = 2.55;
111 float full_eta_ec_in[] = {0, 2.525, 2.515, 2.505};
113 float pix_0 = 4, pix_sep = 6;
114 float pix_z0 = 24, pix_zgrow = 6;
117 float sct_0 = pix_0 + 2 * pix_sep + sct_sep;
118 float sct_zgrow = 10;
119 float sct_z0 = pix_z0 + 2 * pix_zgrow + sct_zgrow;
121 float pix_ec_zgap = 2;
122 float pix_ec_rextra = 2;
124 float sct_ec_zgap = 4;
125 float sct_ec_rextra = 4;
127 add_barrel_r_eta(0, pix_0, full_eta_pix_0);
129 add_barrel_r_z(1, pix_0 + 1 * pix_sep, pix_z0 + 1 * pix_zgrow);
130 add_barrel_r_z(2, pix_0 + 2 * pix_sep, pix_z0 + 2 * pix_zgrow);
131 add_barrel_r_z(3, pix_0 + 3 * pix_sep, pix_z0 + 3 * pix_zgrow);
133 for (
int i = 0;
i < 6; ++
i) {
134 add_barrel_r_z(4 +
i, sct_0 +
i * sct_sep, sct_z0 +
i * sct_zgrow);
137 for (
int i = 1;
i < 4; ++
i) {
138 add_endcap(9 +
i, pix_0 +
i * pix_sep + pix_ec_rextra, pix_z0 +
i * pix_zgrow + pix_ec_zgap, full_eta_ec_in[
i]);
140 for (
int i = 0;
i < 6; ++
i) {
141 add_endcap(13 +
i, sct_0 +
i * sct_sep + sct_ec_rextra, sct_z0 +
i * sct_zgrow + sct_ec_zgap, full_eta);
161 CylCowWLidsCreator creator(ti);
163 creator.FillTrackerInfo();
166 printf(
"==========================================================================================\n");
168 printf(
"Create_CylCowWLids -- creation complete\n");
171 printf(
"==========================================================================================\n");
174 printf(
"==========================================================================================\n");
PropagationFlags forward_fit_pflags
PropagationFlags backward_fit_pflags
PropagationConfig & prop_config_nc()
float getTheta(float r, float z)
float getEta(float r, float z)
LayerInfo & layer_nc(int l)
PropagationFlags finding_inter_layer_pflags
void set_limits(float r1, float r2, float z1, float z2)
void set_layer_type(LayerType_e t)
Tan< T >::type tan(const T &t)
PropagationFlags seed_fit_pflags
void create_layers(int n_brl, int n_ec_pos, int n_ec_neg)
void * TrackerInfoCreator_ptr
PropagationFlags pca_prop_pflags
bool finding_requires_propagation_to_hit_pos
const LayerInfo & layer(int l) const
void apply_tracker_info(const TrackerInfo *ti)
void set_propagate_to(float pto)
PropagationFlags finding_intra_layer_pflags