Loading...
Searching...
No Matches
9 #define STR_TO_DECIMAL(x) std::stof(x)
11 typedef double decimal;
12 #define STR_TO_DECIMAL(x) std::stod(x)
21#define DECIMAL(x) (static_cast<decimal>(x))
24#define DECIMAL_M_E (static_cast<decimal>(M_E))
25#define DECIMAL_M_LOG2E (static_cast<decimal>(M_LOG2E))
26#define DECIMAL_M_LOG10E (static_cast<decimal>(M_LOG10E))
27#define DECIMAL_M_LN2 (static_cast<decimal>(M_LN2))
28#define DECIMAL_M_LN10 (static_cast<decimal>(M_LN10))
29#define DECIMAL_M_PI (static_cast<decimal>(M_PI))
30#define DECIMAL_M_PI_2 (static_cast<decimal>(M_PI_2))
31#define DECIMAL_M_PI_4 (static_cast<decimal>(M_PI_4))
32#define DECIMAL_M_1_PI (static_cast<decimal>(M_1_PI))
33#define DECIMAL_M_2_PI (static_cast<decimal>(M_2_PI))
34#define DECIMAL_M_2_SQRTPI (static_cast<decimal>(M_2_SQRTPI))
35#define DECIMAL_M_SQRT2 (static_cast<decimal>(M_SQRT2))
36#define DECIMAL_M_SQRT1_2 (static_cast<decimal>(M_SQRT1_2))
39#define DECIMAL_POW(base,power) (static_cast<decimal>(std::pow(base), power))
40#define DECIMAL_SQRT(x) (static_cast<decimal>(std::sqrt(x)))
41#define DECIMAL_LOG(x) (static_cast<decimal>(std::log(x)))
42#define DECIMAL_EXP(x) (static_cast<decimal>(std::exp(x)))
43#define DECIMAL_ERF(x) (static_cast<decimal>(std::erf(x)))
46#define DECIMAL_ROUND(x) (static_cast<decimal>(std::round(x)))
47#define DECIMAL_CEIL(x) (static_cast<decimal>(std::ceil(x)))
48#define DECIMAL_FLOOR(x) (static_cast<decimal>(std::floor(x)))
49#define DECIMAL_ABS(x) (static_cast<decimal>(std::abs(x)))
52#define DECIMAL_SIN(x) (static_cast<decimal>(std::sin(x)))
53#define DECIMAL_COS(x) (static_cast<decimal>(std::cos(x)))
54#define DECIMAL_TAN(x) (static_cast<decimal>(std::tan(x)))
55#define DECIMAL_ASIN(x) (static_cast<decimal>(std::asin(x)))
56#define DECIMAL_ACOS(x) (static_cast<decimal>(std::acos(x)))
57#define DECIMAL_ATAN(x) (static_cast<decimal>(std::atan(x)))
58#define DECIMAL_ATAN2(x,y) (static_cast<decimal>(std::atan2(x),y))
61#define DECIMAL_FMA(x,y,z) (static_cast<decimal>(std::fma(x),y,z))
62#define DECIMAL_HYPOT(x,y) (static_cast<decimal>(std::hypot(x),y))