2 #ifndef GAUDIKERNEL_CBRT_H
3 #define GAUDIKERNEL_CBRT_H
22 inline double cbrt(
double __x ){
23 return ::pow( __x, static_cast<double>(1.0/3.0) );
28 inline float cbrt(
float __x ) {
30 return ::cbrtf( __x );
32 return ::pow( __x, static_cast<float>(1.0/3.0) );
37 inline long double cbrt(
long double __x ) {
39 return ::cbrtl( __x );
41 return ::pow( __x, static_cast<long double>(1.0/3.0) );
45 #ifdef __INTEL_COMPILER // Disable ICC remark
47 #pragma warning(disable:2259) // non-pointer conversion may lose significant bits
51 #define cbrt_for_int_type(t) \
52 inline double cbrt( t __x ) { return cbrt ( static_cast<double>(__x) ); }
61 #ifdef __INTEL_COMPILER // End disable ICC remark
65 #undef cbrt_for_int_type
#define cbrt_for_int_type(t)