Antkeeper
0.0.1
|
Numerical integration functions. More...
Functions | |
template<class UnaryOp , class InputIt > | |
std::invoke_result< UnaryOp, typename std::iterator_traits< InputIt >::value_type >::type | simpson (UnaryOp f, InputIt first, InputIt last) |
Approximates the definite integral of a function using Simpson's 1/3 rule. More... | |
template<class UnaryOp , class InputIt > | |
std::invoke_result< UnaryOp, typename std::iterator_traits< InputIt >::value_type >::type | trapezoid (UnaryOp f, InputIt first, InputIt last) |
Approximates the definite integral of a function using the trapezoidal rule. More... | |
Numerical integration functions.
std::invoke_result<UnaryOp, typename std::iterator_traits<InputIt>::value_type>::type math::quadrature::simpson | ( | UnaryOp | f, |
InputIt | first, | ||
InputIt | last | ||
) |
Approximates the definite integral of a function using Simpson's 1/3 rule.
f | Unary function object to integrate. |
first,last | Range of sample points on [first, last) . |
f
.Definition at line 43 of file quadrature.hpp.
std::invoke_result<UnaryOp, typename std::iterator_traits<InputIt>::value_type>::type math::quadrature::trapezoid | ( | UnaryOp | f, |
InputIt | first, | ||
InputIt | last | ||
) |
Approximates the definite integral of a function using the trapezoidal rule.
f | Unary function object to integrate. |
first,last | Range of sample points on [first, last) . |
f
.Definition at line 92 of file quadrature.hpp.