|
template<typename Scalar > |
Scalar | cube_root (const Scalar &x) |
| The real solution to a cube root. More...
|
|
template<typename T > |
T | euclidean_norm (const T &x1, const T &x2) |
| Function for euclidean norms of dimension 2. More...
|
|
template<typename T > |
T | euclidean_norm (const T &x1, const T &x2, const T &x3) |
| Function for euclidean norms of dimension 3. More...
|
|
bool | is_big_endian () |
|
bool | is_char_signed () |
|
template<typename Scalar , typename OtherScalar > |
bool | isApprox (const Scalar &x, const OtherScalar &y, typename numeric_limits< Scalar >::Precision precision=numeric_limits< Scalar >::dummy_precision) |
| Checks if two values are approximate. More...
|
|
template<typename Scalar , typename OtherScalar > |
bool | isApproxOrLessThan (const Scalar &x, const OtherScalar &y, typename numeric_limits< Scalar >::Precision precision=numeric_limits< Scalar >::dummy_precision) |
| Checks if the first value is less than or approximate to the second. More...
|
|
template<typename Scalar > |
int | nsign (const Scalar &x) |
| A sign function for numerical values (negative return if arg is zero). More...
|
|
template<typename Scalar > |
int | psign (const Scalar &x) |
| A sign function for numerical values (positive return if arg is zero). More...
|
|
template<typename Scalar > |
int | sign (const Scalar &x) |
| A sign function for numerical values. More...
|
|
Embedded control libraries.
Various core libraries useful for embedded control systems.
template<typename Scalar , typename OtherScalar >
bool ecl::isApprox |
( |
const Scalar & |
x, |
|
|
const OtherScalar & |
y, |
|
|
typename numeric_limits< Scalar >::Precision |
precision = numeric_limits<Scalar>::dummy_precision |
|
) |
| |
|
inline |
Checks if two values are approximate.
Note that this does not use the usual direct epsilon bound check, instead, it uses the magnitudes of the values and supplied precision to determine the epsilon bounds before carrying out the operation.
- Parameters
-
x | - first input argument |
y | - second input argument |
precision | - precision to use (default is defined by the type). |
- Returns
- bool : true or false of the operation.
Definition at line 154 of file fuzzy.hpp.
template<typename Scalar , typename OtherScalar >
bool ecl::isApproxOrLessThan |
( |
const Scalar & |
x, |
|
|
const OtherScalar & |
y, |
|
|
typename numeric_limits< Scalar >::Precision |
precision = numeric_limits<Scalar>::dummy_precision |
|
) |
| |
|
inline |
Checks if the first value is less than or approximate to the second.
Note that this does not use the usual direct epsilon bound check, instead, it uses the magnitudes of the values and supplied precision to determine the epsilon bounds before carrying out the operation.
- Parameters
-
x | - first input argument |
y | - second input argument |
precision | - precision to use (default is defined by the type). |
- Returns
- bool : true or false of the operation.
Definition at line 172 of file fuzzy.hpp.
template<typename Scalar >
int ecl::nsign |
( |
const Scalar & |
x | ) |
|
|
inline |
A sign function for numerical values (negative return if arg is zero).
Note that zero will return -1, positive numbers +1, and negative numbers -1.
- Parameters
-
- Template Parameters
-
Scalar | : some numerical quantity satisfying a comparison with >= 0 |
- Returns
- bool : true if x is >= 0.
Definition at line 80 of file simple.hpp.
template<typename Scalar >
int ecl::psign |
( |
const Scalar & |
x | ) |
|
|
inline |
A sign function for numerical values (positive return if arg is zero).
Note that zero will return +1, positive numbers +1, and negative numbers -1.
- Parameters
-
- Template Parameters
-
Scalar | : some numerical quantity satisfying a comparison with >= 0 |
- Returns
- bool : true if x is >= 0.
Definition at line 61 of file simple.hpp.
template<typename Scalar >
int ecl::sign |
( |
const Scalar & |
x | ) |
|
|
inline |
A sign function for numerical values.
Note that zero will return zero, positive numbers +1, and negative numbers -1.
- Parameters
-
- Template Parameters
-
Scalar | : some numerical quantity satisfying a comparison with >= 0 |
- Returns
- bool : true if x is >= 0.
Definition at line 38 of file simple.hpp.