Added source of algorithm.
This commit is contained in:
parent
a1ea853da4
commit
6914ec912d
2 changed files with 4 additions and 0 deletions
|
|
@ -1,3 +1,5 @@
|
||||||
TOMS748
|
TOMS748
|
||||||
=======
|
=======
|
||||||
Implementation in C++ and python of the very efficient TOMS748 root-finding algorithm. (Yes, there is already a version in boost).
|
Implementation in C++ and python of the very efficient TOMS748 root-finding algorithm. (Yes, there is already a version in boost).
|
||||||
|
|
||||||
|
Source : https://na.math.kit.edu/alefeld/download/1995_Algorithm_748_Enclosing_Zeros_of_Continuous_Functions.pdf
|
||||||
|
|
|
||||||
|
|
@ -134,6 +134,8 @@ namespace TOMS748
|
||||||
/// Algorithm 4.1 from TOMS748 of robust root-solving.
|
/// Algorithm 4.1 from TOMS748 of robust root-solving.
|
||||||
/// Use this version if f(a) and f(b) have already been computed.
|
/// Use this version if f(a) and f(b) have already been computed.
|
||||||
/// Returns x, f(x), and a boolean indicating if the function converged or not (true if converged).
|
/// Returns x, f(x), and a boolean indicating if the function converged or not (true if converged).
|
||||||
|
///
|
||||||
|
/// Source : https://na.math.kit.edu/alefeld/download/1995_Algorithm_748_Enclosing_Zeros_of_Continuous_Functions.pdf
|
||||||
template<typename Func, typename T>
|
template<typename Func, typename T>
|
||||||
std::tuple<T,T,bool> TOMS748_solve1(Func f, T a, T b, T fa, T fb, T tol, unsigned int Nmax = 1000)
|
std::tuple<T,T,bool> TOMS748_solve1(Func f, T a, T b, T fa, T fb, T tol, unsigned int Nmax = 1000)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue