Functions to decide whether two values are close (to zero) More...
#include <type_traits>#include <cmath>#include "inc/util/types.h"#include "inc/util/thresholds.h"#include "inc/util/isnan.h"#include "inc/util/abs_real_imag_conj.h"
Include dependency graph for closeness.h:
This graph shows which files directly or indirectly include this file:Namespaces | |
| namespace | syten |
| Syten namespace. | |
Functions | |
| template<typename Scalar , typename ThresholdType , typename std::enable_if< std::is_same< Scalar, typename ScalarBase< Scalar >::type >::value, int >::type = 0> | |
| bool | syten::closeThreshold (Scalar const &x, typename IdentityType< Scalar >::type const &y, ThresholdType const &threshold) |
| Returns true if the two arguments are within threshold distance to each other relative to their magnitude. More... | |
| template<typename Scalar , typename ThresholdType > | |
| void | syten::eliminate_to_zero (Scalar &n, ThresholdType const &t) |
Checks if n is over the threshold t · SYTEN_EZERO_THRESHOLD. More... | |
| template<typename Scalar , typename ThresholdType > | |
| void | syten::eliminate_to_zero (std::complex< Scalar > &n, ThresholdType const &t) |
Checks if n is over the threshold t · SYTEN_EZERO_THRESHOLD. More... | |
| template<typename Scalar , typename ThresholdType , typename std::enable_if< std::is_same< Scalar, typename ScalarBase< Scalar >::type >::value, int >::type = 0> | |
| bool | syten::overThreshold (Scalar const &x, ThresholdType const &threshold) |
| Returns true if the absolute value of the argument is larger than the threshold. More... | |
| template<typename Scalar , typename ThresholdType > | |
| bool | syten::underThreshold (Scalar const &x, ThresholdType const &threshold) |
| Returns true if the argument is not over the threshold. More... | |
Functions to decide whether two values are close (to zero)