#ifndef __AMSCUMATH_IMPL_HPP__
#define __AMSCUMATH_IMPL_HPP__

namespace amscuda
{

template<typename T> __host__ __device__ T min(const T &a, const T &b)
{
    if(a>b)
    {
        return b;
    }
    else
    {
        return a;
    }
    return a;
}

template<typename T> __host__ __device__ T max(const T &a, const T &b)
{
    if(a>b)
    {
        return a;
    }
    else
    {
        return b;
    }
    return a;
}

template<> __host__ __device__ double min(const double &a, const double &b);
template<> __host__ __device__ float min(const float &a, const float &b);
template<> __host__ __device__ double max(const double &a, const double &b);
template<> __host__ __device__ float max(const float &a, const float &b);


}; //end namespace amscuda

#endif

