         T absx = x>0 ? x : -x;
         T absy = y>0 ? y : -y;
         return absx > absy ? absx : absy;
+    }
+};
+/**
+ * @brief Functor for the absolute maximum
+ *
+ * @tparam T value-type
+ */
+template <class T>
+struct AbsMin
+{
+    /**
+     * @brief Return the asbolute minimum
+     *
+     * @param x left value
+     * @param y right value
+     *
+     * @return absolute minimum
+     */
+    __host__ __device__
+    T operator() (const T& x, const T& y)
+    {
+        T absx = x<0 ? -x : x;
+        T absy = y<0 ? -y : y;
+        return absx < absy ? absx : -absy;
     }
 };
 

    double g_[3];
    double kz_;
};
/**
 * @brief Exponential
 *

        T operator()(const T& x){ return fabs(x);}
};

///@}
} //namespace dg

