OpenKalman
triangular_matrix.hpp
Go to the documentation of this file.
1 /* This file is part of OpenKalman, a header-only C++ library for
2  * Kalman filters and other recursive filters.
3  *
4  * Copyright (c) 2019-2025 Christopher Lee Ogden <ogden@gatech.edu>
5  *
6  * This Source Code Form is subject to the terms of the Mozilla Public
7  * License, v. 2.0. If a copy of the MPL was not distributed with this
8  * file, You can obtain one at https://mozilla.org/MPL/2.0/.
9  */
10 
16 #ifndef OPENKALMAN_TRIANGULAR_MATRIX_HPP
17 #define OPENKALMAN_TRIANGULAR_MATRIX_HPP
18 
21 
22 namespace OpenKalman
23 {
32  template<typename T, triangle_type t = triangle_type::any>
33 #ifdef __cpp_concepts
34  concept triangular_matrix =
35 #else
36  constexpr bool triangular_matrix =
37 #endif
38  indexible<T> and
39  (t == triangle_type_of_v<T> or
40  (t == triangle_type::any and triangle_type_of_v<T> != triangle_type::none) or
41  ((t == triangle_type::upper or t == triangle_type::lower) and triangle_type_of_v<T> == triangle_type::diagonal));
42 
43 
44 }
45 
46 #endif
A lower-left triangular matrix.
A diagonal matrix (both a lower-left and an upper-right triangular matrix).
constexpr bool triangular_matrix
Specifies that an argument is an indexible object having a given triangle_type (e.g., upper, lower, or diagonal).
Definition: triangular_matrix.hpp:36
Lower, upper, or diagonal matrix.
The root namespace for OpenKalman.
Definition: basics.hpp:34
An upper-right triangular matrix.
Definition for indexible.
Definition for triangle_type_of.