test_zero, a FORTRAN90 code which defines nonlinear functions that may be used to test zero finders.
Zero finders are programs that seek a (scalar) root of a scalar equation F(X) = 0. Some zero finders require that an initial "change-of-sign" interval [A,B] be supplied, with the function having opposite sign at the two endpoints, thus guaranteeing that there is some value C between A and B for which F(C) = 0 (assuming that the function F is continuous). In other cases, a particular zero finder may want information about the first or second derivative of the function. And some zero finders can handle situations where the function has a multiple root, or where the function is a polynomial.
The code supplies a set of nonlinear functions, along with change of sign interval, first and second derivatives, suggested starting points, so that the behavior of any zero finder can be analyzed.
The code also includes implementations of some simple zero finders, as a demonstration of how the package might be used.
The functions, which are accessible by number, are
The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.
test_zero is available in a C version and a C++ version and a FORTRAN90 version and a MATLAB version and an Octave version and a Python version.
BISECTION_INTEGER, a FORTRAN90 code which seeks an integer solution to the equation F(X)=0, using bisection within a user-supplied change of sign interval [A,B].
BISECTION_RC, a FORTRAN90 code which seeks a solution to the equation F(X)=0 using bisection within a user-supplied change of sign interval [A,B]. The procedure is written using reverse communication.
BRENT, a FORTRAN90 code which contains Richard Brent's routines for finding the zero, local minimizer, or global minimizer of a scalar function of a scalar argument, without the use of derivative information.
NMS, a FORTRAN90 code which includes the zero finder FZERO.
ZERO_RC, a FORTRAN90 code which seeks solutions of a scalar nonlinear equation f(x) = 0, or a system of nonlinear equations, using reverse communication.
ZOOMIN, a FORTRAN90 code which includes various zero finder routines.