numerical-collection-cpp 0.10.0
A collection of algorithms in numerical analysis implemented in C++
|
Namespace of internal implementations. More...
Functions | |
template<typename T > | |
constexpr auto | exp_maclaurin (T x) -> T |
Calculate exponential function with Maclaurin series. | |
template<typename T > | |
constexpr auto | expm1_maclaurin (T x) -> T |
Calculate exponential function minus one with Maclaurin series. | |
template<typename T > | |
constexpr auto | log1m_maclaurin (T x) -> T |
Calculate logarithm of 1 - x. | |
template<typename T , typename I > | |
constexpr auto | pow_pos_int (T base, I exp) -> T |
Calculate the value of base raised to the power exp. | |
Namespace of internal implementations.
|
constexpr |
Calculate exponential function with Maclaurin series.
This calculates the following series:
\[ e^x = \sum_{k=0}^\infty \frac{x^k}{k!} \]
T | Number type (assumed as floating-point number types). |
[in] | x | Number. |
Definition at line 41 of file exp_maclaurin.h.
|
constexpr |
Calculate exponential function minus one with Maclaurin series.
This calculates the following series:
\[ e^x - 1 = \sum_{k=1}^\infty \frac{x^k}{k!} \]
T | Number type (assumed as floating-point number types). |
[in] | x | Number. |
Definition at line 42 of file expm1_maclaurin.h.
|
constexpr |
Calculate logarithm of 1 - x.
This calculates the following series:
\[ log(1 - x) = -\sum_{k=1}^\infty \frac{x^k}{k} \]
T | Number type. |
[in] | x | Number. |
Definition at line 42 of file log1m_maclaurin.h.
|
constexpr |
Calculate the value of base raised to the power exp.
T | Base type. |
I | Integer type for exponent. |
[in] | base | Base. |
[in] | exp | Exponent. |
Definition at line 40 of file pow_pos_int.h.