- bisect
Tuple!(T, "xTrue", T, "xFalse", R, "fTrue", R, "fFalse") bisect(F f, bool delegate(T, R) predicate, T xTrue, T xFalse, T xTolerance, int maxIterations)
Tuple!(T, "xTrue", T, "xFalse", R, "fTrue", R, "fFalse") bisect(F f, bool delegate(T, R) predicate, T xTrue, T xFalse, R fTrue, R fFalse, T xTolerance, int maxIterations)
Use bisection to find the point where the given predicate goes from
returning false to returning true.
- bracketRoot
RootBracket!(T, ReturnType!F) bracketRoot(F f, T x0, T scale, T xMin, T xMax)
Bracket a root of the function f.
- bracketRoots
RootBracket!(T, ReturnType!Func)[] bracketRoots(Func f, T a, T b, uint nIntervals, RootBracket!(T, ReturnType!Func)[] buffer)
Divides the interval [a,b] into the given number of equal-sized
subintervals,
checks whether any of the subintervals bracket a root, and returns
the ones that do, together with the function values at those points.
- findRoot
Real[] findRoot(Func f, Real[] guess, Real epsRel, int maxFuncEvals, Real[] buffer)
Searches for a root of N functions of N variables using a variant
of the Powell Hybrid Method (the HYBRD routine from MINPACK).
- findRoot
T findRoot(F f, T x0, T scale, T xMin, T xMax, int precision)
T findRoot(F f, T x0, T scale, int precision)
T findRoot(F f, T x0, T scale, T xMin, T xMax)
Find a root of the function f.
- findRoots
T[] findRoots(Func f, T a, T b, uint nIntervals, T[] buffer)
Uses bracketRoots() to divide the interval [a,b] into subintervals
and check which ones bracket roots. Then, findRoot() is applied
to each bracketing interval, and an array containing the roots
is returned.
Functions related to the solving of nonlinear equations, i.e. finding roots of nonlinear functions.