demopt1

Purpose

Demonstrate different optimisers on Rosenbrock's function.

Synopsis

demopt1
demopt1(xinit)

Description

The four general optimisers (quasi-Newton, conjugate gradients, scaled conjugate gradients, and gradient descent) are applied to the minimisation of Rosenbrock's well known `banana' function. Each optimiser is run for at most 100 cycles, and a stopping criterion of 1.0e-4 is used for both position and function value. At the end, the trajectory of each algorithm is shown on a contour plot of the function.

demopt1(xinit) allows the user to specify a row vector with two columns as the starting point. The default is the point [-1 1]. Note that the contour plot has an x range of [-1.5, 1.5] and a y range of [-0.5, 2.1], so it is best to choose a starting point in the same region.

See Also

conjgrad, graddesc, quasinew, scg, rosen, rosegrad
Pages: Index

Copyright (c) Ian T Nabney (1996-9)