next up previous

1.4 Numerical Example and Programming Notes     continued...

Figure 3: Contours of the Two-Dimensional Rosenbrock Function.

In minimization applications, the user is often required to write subroutines that compute the target function and its first and second derivatives (the latter optional) at each given point. For Rosenbrock's function, for example, this code will compute these quantities.

Note that the Hessian is stored in two one-dimensional arrays that reside in a COMMON block. A storage format is often not imposed on the Hessian for large-scale problems so that the user can exploit problem structure (e.g., sparsity) to save storage space.