![]() |
OpenSWMM Engine
6.0.0-alpha.4
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.4)
|
Newton-Raphson and Ridder root finders. More...
#include <functional>Go to the source code of this file.
Namespaces | |
| namespace | openswmm |
| namespace | openswmm::findroot |
Typedefs | |
| using | openswmm::findroot::NewtonFunc = std::function<void(double x, double* f, double* df)> |
| Synchronous function and derivative evaluator for newton(). | |
| using | openswmm::findroot::RidderFunc = std::function<double(double x)> |
| Synchronous scalar function evaluator for ridder(). | |
Functions | |
| int | openswmm::findroot::newton (double x1, double x2, double *rts, double xacc, const NewtonFunc &func) |
| Find a root with Newton steps and a bisection fallback. | |
| double | openswmm::findroot::ridder (double x1, double x2, double xacc, const RidderFunc &func) |
| Estimate a bracketed root with derivative-free Ridder iterations. | |
Variables | |
| constexpr int | openswmm::findroot::MAXIT = 60 |
| Maximum iterations. | |
Newton-Raphson and Ridder root finders.
Numerically identical to legacy findroot.c. Used by: