6 #ifndef THEORETICA_AUTODIFF_TYPES_H
7 #define THEORETICA_AUTODIFF_TYPES_H
19 template<
typename Type>
29 template<
typename Function>
33 typename _internal::return_type_or_void<Function, dual>::type
35 std::true_type, std::false_type
41 template<
typename Function,
typename T =
bool>
43 typename std::enable_if<is_dual_func<Function>::value, T>::type;
47 template<
typename Type>
57 template<
typename Function>
61 typename _internal::return_type_or_void<Function, dual2>::type
63 std::true_type, std::false_type
69 template<
typename Function,
typename T =
bool>
71 typename std::enable_if<is_dual2_func<Function>::value, T>::type;
75 template<
typename Type>
79 template<
unsigned int N>
84 template<
typename Type,
typename T =
bool>
86 typename std::enable_if<is_multidual_type<Type>::value, T>::type;
93 template<
typename Function,
typename T =
bool>
103 template<
typename Function,
typename T =
bool>
116 template<
unsigned int N = 0>
121 template<
unsigned int N = 0>
Second order dual number class.
Definition: dual2.h:29
Dual number class.
Definition: dual.h:28
Multidual number algebra for functions of the form .
Definition: multidual.h:26
A statically allocated N-dimensional vector with elements of the given type.
Definition: vec.h:88
typename std::enable_if< is_dual_func< Function >::value, T >::type enable_dual_func
Enable a certain function overload if the given type is a function taking as first argument a dual nu...
Definition: autodiff_types.h:43
typename std::enable_if< is_dual2_func< Function >::value, T >::type enable_dual2_func
Enable a certain function overload if the given type is a function taking as first argument a dual2 n...
Definition: autodiff_types.h:71
typename std::enable_if< is_multidual_type< return_type_t< Function > >::value, T >::type enable_scalar_field
Enable a certain function overload if the given type is a Callable object corresponding to a multidua...
Definition: autodiff_types.h:96
std::conditional_t< is_dual_type< typename _internal::return_type_or_void< Function, dual >::type >::value, std::true_type, std::false_type > is_dual_func
Type trait to check whether the given function takes a dual number as its first argument.
Definition: autodiff_types.h:36
typename std::enable_if< is_multidual_type< vector_element_t< return_type_t< Function > > >::value, T >::type enable_vector_field
Enable a certain function overload if the given type is a Callable object corresponding to a multidua...
Definition: autodiff_types.h:108
typename std::enable_if< is_multidual_type< Type >::value, T >::type enable_multidual
Enable a certain function overload if the given type is an instantiation of the multidual template cl...
Definition: autodiff_types.h:86
std::conditional_t< is_dual2_type< typename _internal::return_type_or_void< Function, dual2 >::type >::value, std::true_type, std::false_type > is_dual2_func
Type trait to check whether the given function takes a dual2 number as its first argument.
Definition: autodiff_types.h:64
Main namespace of the library which contains all functions and objects.
Definition: algebra.h:27
std::remove_reference_t< decltype(std::declval< Structure >()[0])> vector_element_t
Extract the type of a vector (or any indexable container) from its operator[].
Definition: core_traits.h:134
Type trait to check whether the given type is a multidual number.
Definition: autodiff_types.h:48
Type trait to check whether the given type is a multidual number.
Definition: autodiff_types.h:20
Type trait to check whether the given type is a multidual number.
Definition: autodiff_types.h:76