LifeV
|
Implementation of Brent's method for root finding. More...
Go to the source code of this file.
Namespaces | |
LifeV | |
Default Physical Solver. | |
Functions | |
template<class Function > | |
Real | NonLinearBrent (const Function &f, const Real &leftExtremeBase, const Real &rightExtremeBase, const Real &toll, const UInt &maxIter) |
Implementation of Brent's method for root finding. More... | |
Implementation of Brent's method for root finding.
Brent's method is a root-finding algorithm combining the bisection method, the secant method and inverse quadratic interpolation. It has the reliability of bisection but it can be as quick as some of the less reliable methods. The idea is to use the secant method or inverse quadratic interpolation if possible, because they converge faster, but to fall back to the more robust bisection method if necessary.
Definition in file NonLinearBrent.hpp.