#include "../Mat.h"
#include "FunctionTable.h"
#include <cmath>
Go to the source code of this file.
Namespaces | |
| namespace | exmat |
| namespace | exmat::Math |
Numerical constants | |
| static double | exmat::Math::CPi () |
| Pi is the ratio of the circumference of a circle to its diameter. | |
| static double | exmat::Math::C2Pi () |
| 2 * Pi | |
| static double | exmat::Math::CPi_2 () |
| Pi / 2. | |
| static double | exmat::Math::CPi_4 () |
| Pi / 4. | |
| static double | exmat::Math::C1_Pi () |
| 1 / Pi | |
| static double | exmat::Math::C2_Pi () |
| 2 / Pi | |
| static double | exmat::Math::CE () |
| E is the base of the natural logarithms. | |
| static double | exmat::Math::CSqrt2 () |
| sqrt(2) | |
| static double | exmat::Math::C1_Sqrt2 () |
| 1 / sqrt(2) | |
Utility functions | |
| static int | exmat::Math::abs (int x) |
| Absolute value of x. | |
| static float | exmat::Math::abs (float x) |
| Absolute value of x. | |
| static double | exmat::Math::abs (double x) |
| Absolute value of x. | |
| static bool | exmat::Math::isEqual (double s1, double s2, double eps=1e-6) |
| isEqual test for 2 numbers are equal or not within a torrence | |
| static float | exmat::Math::sqrt (float x) |
| Square root value. | |
| static double | exmat::Math::sqrt (double x) |
| Square root value. | |
| static void | exmat::Math::sqrt (const float *in, float *out, size_t N) |
| Square root value. | |
| static float | exmat::Math::rsqrt (float x) |
| 1/sqrt(x) | |
| static double | exmat::Math::rsqrt (double x) |
| 1/sqrt(x) | |
| static void | exmat::Math::rsqrt (const float *in, float *out, size_t N) |
| 1/sqrt(x) | |
| static float | exmat::Math::exp (float x) |
| Exponential value of base e. | |
| static double | exmat::Math::exp (double x) |
| Exponential value of base e. | |
| static void | exmat::Math::exp (const float *in, float *out, size_t N) |
| Exponential value of base e. | |
| static float | exmat::Math::log (float x) |
| Logarithms value of x (base e). | |
| static double | exmat::Math::log (double x) |
| Logarithms value of x (base e). | |
| static void | exmat::Math::log (const float *in, float *out, size_t N) |
| Logarithms value of x (base e). | |
| static float | exmat::Math::pow (float x, float y) |
| Calculate x raises to the power y. | |
| static double | exmat::Math::pow (double x, double y) |
| Calculate x raises to the power y. | |
Trigonometrical functions | |
| static float | exmat::Math::sin (float x) |
| Sine value of x (in radian). | |
| static double | exmat::Math::sin (double x) |
| Sine value of x (in radian). | |
| static void | exmat::Math::sin (const float *in, float *out, size_t N) |
| Sine value of x (in radian). | |
| static float | exmat::Math::cos (float x) |
| Cosine value of x (in radian). | |
| static double | exmat::Math::cos (double x) |
| Sine value of x (in radian). | |
| static void | exmat::Math::cos (const float *in, float *out, size_t N) |
| Sine value of x (in radian). | |
| static void | exmat::Math::sincos (float x, float &s, float &c) |
| Sine and cosine value of x (in radian). | |
| static void | exmat::Math::sincos (double x, double &s, double &c) |
| Sine and cosine value of x (in radian). | |
| static float | exmat::Math::tan (float x) |
| Tangent value of x (in radian). | |
| static double | exmat::Math::tan (double x) |
| Sine value of x (in radian). | |
| static void | exmat::Math::tan (const float *in, float *out, size_t N) |
| Sine value of x (in radian). | |
| static float | exmat::Math::asin (float x) |
| Arc sine value (in radian) of x. | |
| static double | exmat::Math::asin (double x) |
| Sine value of x (in radian). | |
| static void | exmat::Math::asin (const float *in, float *out, size_t N) |
| Sine value of x (in radian). | |
| static float | exmat::Math::acos (float x) |
| Arc cosine value (in radian) of x. | |
| static double | exmat::Math::acos (double x) |
| Sine value of x (in radian). | |
| static void | exmat::Math::acos (const float *in, float *out, size_t N) |
| Sine value of x (in radian). | |
| static float | exmat::Math::atan (float x) |
| Arc tangent value (in radian) of x. | |
| static double | exmat::Math::atan (double x) |
| Sine value of x (in radian). | |
| static void | exmat::Math::atan (const float *in, float *out, size_t N) |
| Sine value of x (in radian). | |
Functions | |
| template<typename T> | |
| static T | exmat::Math::min (const T &x1, const T &x2) |
| Minimum of 2 value. | |
| template<typename T> | |
| static T | exmat::Math::min (const T &x1, const T &x2, const T &x3) |
| Minimum of 3 value. | |
| template<typename T> | |
| static T | exmat::Math::min (const T &x1, const T &x2, const T &x3, const T &x4) |
| Minimum of 4 value. | |
| template<typename T> | |
| static T | exmat::Math::min (const T &x1, const T &x2, const T &x3, const T &x4, const T &x5) |
| Minimum of 5 value. | |
| static float | exmat::Math::min (const float *in, size_t N) |
| Minimum value. | |
| template<typename T> | |
| static T | exmat::Math::max (const T &x1, const T &x2) |
| Maximum of 2 value. | |
| template<typename T> | |
| static T | exmat::Math::max (const T &x1, const T &x2, const T &x3) |
| Maximum of 3 value. | |
| template<typename T> | |
| static T | exmat::Math::max (const T &x1, const T &x2, const T &x3, const T &x4) |
| Maximum of 4 value. | |
| template<typename T> | |
| static T | exmat::Math::max (const T &x1, const T &x2, const T &x3, const T &x4, const T &x5) |
| Maximum of 5 value. | |
| static float | exmat::Math::max (const float *in, size_t N) |
| Maximum value. | |
| static float | exmat::Math::sum (const float *in, size_t N) |
| Summation. | |
| static float | exmat::Math::rcp (float x) |
| 1/x | |
1.4.6-NO