16 #ifndef dealii_complex_overloads_h
17 #define dealii_complex_overloads_h
27 template <
typename T,
typename U>
31 #ifndef DEAL_II_HAVE_COMPLEX_OPERATOR_OVERLOADS
39 template <
typename T,
typename U>
40 inline typename std::enable_if<
41 std::is_floating_point<T>::value && std::is_floating_point<U>::value,
43 operator*(
const std::complex<T> &left,
const std::complex<U> &right)
47 return static_cast<result_type
>(left) *
static_cast<result_type
>(right);
57 template <
typename T,
typename U>
58 inline typename std::enable_if<
59 std::is_floating_point<T>::value && std::is_floating_point<U>::value,
61 operator/(
const std::complex<T> &left,
const std::complex<U> &right)
65 return static_cast<result_type
>(left) /
static_cast<result_type
>(right);
75 template <
typename T,
typename U>
77 typename std::enable_if<std::is_floating_point<T>::value &&
78 std::is_floating_point<U>::value,
83 return static_cast<result_type
>(left) *
static_cast<result_type
>(right);
93 template <
typename T,
typename U>
95 typename std::enable_if<std::is_floating_point<T>::value &&
96 std::is_floating_point<U>::value,
101 return static_cast<result_type
>(left) /
static_cast<result_type
>(right);
111 template <
typename T,
typename U>
114 std::enable_if<std::is_floating_point<T>::value &&
115 std::is_floating_point<U>::value,
120 return static_cast<result_type
>(left) *
static_cast<result_type
>(right);
130 template <
typename T,
typename U>
132 typename std::enable_if<std::is_floating_point<T>::value &&
133 std::is_floating_point<U>::value,
138 return static_cast<result_type
>(left) /
static_cast<result_type
>(right);
#define DEAL_II_NAMESPACE_OPEN
#define DEAL_II_NAMESPACE_CLOSE
std::enable_if< std::is_floating_point< T >::value &&std::is_floating_point< U >::value, typename ProductType< std::complex< T >, U >::type >::type operator/(const std::complex< T > &left, const U &right)
std::enable_if< std::is_floating_point< T >::value &&std::is_floating_point< U >::value, typename ProductType< std::complex< T >, std::complex< U > >::type >::type operator*(const std::complex< T > &left, const std::complex< U > &right)
std::enable_if< std::is_floating_point< T >::value &&std::is_floating_point< U >::value, typename ProductType< T, std::complex< U > >::type >::type operator*(const T &left, const std::complex< U > &right)
std::enable_if< std::is_floating_point< T >::value &&std::is_floating_point< U >::value, typename ProductType< std::complex< T >, std::complex< U > >::type >::type operator/(const std::complex< T > &left, const std::complex< U > &right)
std::enable_if< std::is_floating_point< T >::value &&std::is_floating_point< U >::value, typename ProductType< std::complex< T >, U >::type >::type operator*(const std::complex< T > &left, const U &right)
typename internal::ProductTypeImpl< typename std::decay< T >::type, typename std::decay< U >::type >::type type
std::enable_if< std::is_floating_point< T >::value &&std::is_floating_point< U >::value, typename ProductType< T, std::complex< U > >::type >::type operator/(const T &left, const std::complex< U > &right)