numerical-collection-cpp 0.10.0
A collection of algorithms in numerical analysis implemented in C++
|
Definition of abs function. More...
#include <cmath>
#include <complex>
#include "num_collect/base/concepts/real_scalar.h"
#include "num_collect/base/concepts/signed_integral.h"
#include "num_collect/base/concepts/unsigned_integral.h"
Go to the source code of this file.
Namespaces | |
namespace | num_collect |
Namespace of num_collect source codes. | |
namespace | num_collect::base |
Namespace of definitions common in this project. |
Functions | |
template<concepts::real_scalar T> | |
auto | num_collect::base::abs (const std::complex< T > &val) -> T |
Calculate the absolute value of a complex number. | |
template<concepts::real_scalar T> | |
auto | num_collect::base::abs (const T &val) -> T |
Calculate the absolute value of a number. | |
template<concepts::signed_integral T> | |
auto | num_collect::base::abs (const T &val) -> T |
Calculate the absolute value of a number. | |
template<concepts::unsigned_integral T> | |
auto | num_collect::base::abs (const T &val) -> T |
Calculate the absolute value of a number. |
Definition of abs function.
Definition in file abs.h.