This is documentation for Mathematica 6, which was
based on an earlier version of the Wolfram Language.
 Mathematica Tutorial Functions »|Tutorials »| More About »

# Plotting Search Data

The utility functions FindMinimumPlot and FindRootPlot show search data for FindMinimum and FindRoot for one- and two-dimensional functions. They work with the essentially same arguments as FindMinimum and FindRoot except that they additionally take options, which affect the graphics functions they call to provide the plots, and they do not have the HoldAll attribute as do FindMinimum and FindRoot.
 FindMinimumPlot[f, {x, xst}, opts] plot the steps and the points at which the function f and any of its derivatives that were evaluated in FindMinimum[f, {x, xst}] superimposed on a plot of f versus x; opts may include options from both FindMinimum and Plot FindMinimumPlot[f, {{x, xst}, {y, yst}}, opts] plot the steps and the points at which the function f and any of its derivatives that were evaluated in FindMinimum[f, {{x, xst}, {y, yst}}] superimposed on a contour plot of f as a function of x and y; opts may include options from both FindMinimum and ContourPlot FindRootPlot[f, {x, xst}, opts] plot the steps and the points at which the function f and any of its derivatives which were evaluated in FindRoot[f, {x, xst}] superimposed on a plot of f versus x; opts may include options from both FindRoot and Plot FindRootPlot[f, {{x, xst}, {y, yst}}, opts] plot the steps and the points at which the function f and any of its derivatives that were evaluated in FindRoot[f, {{x, xst}, {y, yst}}] superimposed on a contour plot of the merit function f.f as a function of x and y; opts may include options from both FindRoot and ContourPlot

Plotting search data.

Note that to simplify processing and reduce possible confusion about the function f, FindRootPlot does not accept equations; it finds a root f = 0.
Steps and evaluation points are color coded for easy detection as follows:
Steps are shown with blue lines and blue points.
Function evaluations are shown with green points.
Gradient evaluations are shown with red points.
Hessian evaluations are shown with cyan points.
Residual function evaluations are shown with yellow points.
Jacobian evaluations are shown with purple points.
The search termination is shown with a large black point.
FindMinimumPlot and FindRootPlot return a list containing {result, summary, plot}, where
result is the result of FindMinimum or FindRoot.
summary is a list of rules showing the numbers of steps and evaluations of the function and its derivatives.
plot is the graphics object shown.