1 #ifndef NPSTAT_ABSDIFFERENCE_HH_
2 #define NPSTAT_ABSDIFFERENCE_HH_
18 #include "geners/IOIsUnsigned.hh"
53 template <
typename T,
int Un
signed=0>
56 typedef typename Private::AbsReturnType<T>::type return_type;
58 inline static return_type delta(
const T& v1,
const T& v2)
59 {
return std::abs(v1 - v2);}
61 inline static return_type value(
const T& v1)
62 {
return std::abs(v1);}
69 typedef typename Private::AbsReturnType<T>::type return_type;
71 inline static return_type delta(
const T& v1,
const T& v2)
72 {
return v1 > v2 ? v1 - v2 : v2 - v1;}
74 inline static return_type value(
const T& v1)
84 inline typename Private::AbsReturnType<T>::type
95 inline typename Private::AbsReturnType<T>::type
Definition: AbsArrayProjector.hh:14
Private::AbsReturnType< T >::type absValue(const T &v1)
Definition: absDifference.hh:96
Private::AbsReturnType< T >::type absDifference(const T &v1, const T &v2)
Definition: absDifference.hh:85
Definition: absDifference.hh:55
Definition: absDifference.hh:24