ACTS
Experiment-independent tracking
Loading...
Searching...
No Matches
smatrix.hpp
1// This file is part of the ACTS project.
2//
3// Copyright (C) 2016 CERN for the benefit of the ACTS project
4//
5// This Source Code Form is subject to the terms of the Mozilla Public
6// License, v. 2.0. If a copy of the MPL was not distributed with this
7// file, You can obtain one at https://mozilla.org/MPL/2.0/.
8
9#pragma once
10
11// Project include(s).
12#include "algebra/impl/smatrix_getter.hpp"
13#include "algebra/impl/smatrix_matrix.hpp"
14#include "algebra/impl/smatrix_types.hpp"
15#include "algebra/impl/smatrix_vector.hpp"
16#include "detray/algebra/common/boolean.hpp"
17#include "detray/algebra/generic/generic.hpp"
18
19namespace detray {
20
23template <concepts::value V>
24struct smatrix {
26 using value_type = V;
27
29 template <concepts::element T>
30 using simd = T;
31
33 using boolean = bool;
37 using index_type = algebra::smatrix::index_type;
39 using transform3D = algebra::smatrix::transform3<value_type>;
41 using point2D = algebra::smatrix::point2<value_type>;
43 using point3D = algebra::smatrix::point3<value_type>;
45 using vector2D = algebra::smatrix::vector2<value_type>;
47 using vector3D = algebra::smatrix::vector3<value_type>;
48
50 template <std::size_t ROWS, std::size_t COLS>
52 using matrix = algebra::smatrix::matrix_type<value_type, ROWS, COLS>;
53};
54
55
56namespace getter {
57
60
61using algebra::smatrix::storage::block;
62using algebra::smatrix::storage::element;
63using algebra::smatrix::storage::set_block;
64using algebra::smatrix::storage::vector;
65
67
68} // namespace getter
69
70namespace vector {
71
74
75using algebra::smatrix::math::cross;
76using algebra::smatrix::math::dot;
77using algebra::smatrix::math::eta;
78using algebra::smatrix::math::norm;
79using algebra::smatrix::math::normalize;
80using algebra::smatrix::math::perp;
81using algebra::smatrix::math::phi;
82using algebra::smatrix::math::theta;
83
85
86} // namespace vector
87
88namespace matrix {
89
92
93using algebra::smatrix::math::cholesky_decomposition;
94using algebra::smatrix::math::column_wise_cross;
95using algebra::smatrix::math::column_wise_multiply;
96using algebra::smatrix::math::determinant;
97using algebra::smatrix::math::identity;
98using algebra::smatrix::math::inverse;
99using algebra::smatrix::math::outer_product;
100using algebra::smatrix::math::set_identity;
101using algebra::smatrix::math::set_zero;
102using algebra::smatrix::math::transpose;
103using algebra::smatrix::math::zero;
104
105using algebra::generic::math::cross_matrix;
106using algebra::generic::math::set_inplace_product_left;
107using algebra::generic::math::set_inplace_product_left_transpose;
108using algebra::generic::math::set_inplace_product_right;
109using algebra::generic::math::set_inplace_product_right_transpose;
110using algebra::generic::math::set_product;
111using algebra::generic::math::set_product_left_transpose;
112using algebra::generic::math::set_product_right_transpose;
113using algebra::generic::math::transposed_product;
114
116
117} // namespace matrix
118
119} // namespace detray
Detray include(s).
Definition array_operators.hpp:18
Define the plugin types.
Definition smatrix.hpp:24
bool boolean
Boolean type used for element-wise predicates.
Definition smatrix.hpp:33
V value_type
Define scalar type.
Definition smatrix.hpp:26
algebra::smatrix::point2< value_type > point2D
Two-dimensional point type.
Definition smatrix.hpp:41
algebra::smatrix::transform3< value_type > transform3D
Three-dimensional transform type.
Definition smatrix.hpp:39
value_type scalar
Scalar type represented by this backend.
Definition smatrix.hpp:35
algebra::smatrix::index_type index_type
Index type used for matrix and vector access.
Definition smatrix.hpp:37
algebra::smatrix::matrix_type< value_type, ROWS, COLS > matrix
Fixed-size matrix type with the requested dimensions.
Definition smatrix.hpp:52
algebra::smatrix::vector3< value_type > vector3D
Three-dimensional vector type.
Definition smatrix.hpp:47
algebra::smatrix::point3< value_type > point3D
Three-dimensional point type.
Definition smatrix.hpp:43
T simd
Backend vectorized representation of an element type.
Definition smatrix.hpp:30
algebra::smatrix::vector2< value_type > vector2D
Two-dimensional vector type.
Definition smatrix.hpp:45