1 #ifndef __LIBCPROJECT_MATHEMATICS__
2 #define __LIBCPROJECT_MATHEMATICS__
4 #define MATHEMATICS_DOUBLE_PRECISION 0.0000000001
int64_t mathematics_max(int64_t number1, int64_t number2)
Returns the largest number between 2 numbers.
bool mathematics_equals(const float64_t number1, const float64_t number2)
Verify that 2 numbers are equal.
uint64_t mathematics_factorial(uint64_t number)
Calculates the factorial of a number.
int64_t mathematics_opposite(int64_t number)
Calulcates the opposite number (additive inverse).
int64_t mathematics_min(int64_t number1, int64_t number2)
Returns the smallest number between 2 numbers.
int64_t mathematics_min_values(int64_t *values, size_t values_length)
Returns the smallest number between multiple numbers. If the array is empty, returns 0.
int64_t mathematics_max_values(int64_t *values, size_t values_length)
Returns the largest number between multiple numbers. If the array is empty, returns 0.
uint64_t mathematics_absolute_value(const int64_t number)
Get the absolute value of a number.
float64_t mathematics_square_root(float64_t number)
Calculates the square root of a number using Heron's method.
float64_t mathematics_root(float64_t number, uint64_t nth_root)
Calculates the nth root of a number.
uint64_t mathematics_pow(uint64_t base, uint64_t exponent)
Calculates the power of a number.