OpenKalman
real_type_of.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) 2024-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_VALUES_REAL_TYPE_OF_HPP
17 #define OPENKALMAN_VALUES_REAL_TYPE_OF_HPP
18 
21 #include "values/math/real.hpp"
22 
23 namespace OpenKalman::values
24 {
32 #ifdef __cpp_concepts
33  template<typename T>
34 #else
35  template<typename T, typename = void>
36 #endif
37  struct real_type_of {};
38 
39 
41 #ifdef __cpp_concepts
42  template<value T>
43  struct real_type_of<T>
44 #else
45  template<typename T>
46  struct real_type_of<T, std::enable_if_t<value<T>>>
47 #endif
48  : value_type_of<decltype(values::real(std::declval<T>()))> {};
49 
50 
54  template<typename T>
56 
57 
58 }
59 
60 #endif
typename real_type_of< T >::type real_type_of_t
Helper template for real_type_of.
Definition: real_type_of.hpp:55
Obtain the underlying value type associated with a value.
Definition: value_type_of.hpp:32
Obtain the real type associated with a value (typically a complex number).
Definition: real_type_of.hpp:37
Definition for value:value_type_of and value:value_type_of_t.
Definition for values::abs.
Definition: fixed-constants.hpp:23
Definition for values::real.
Definition for values::value.