annotate toolboxes/FullBNT-1.0.7/nethelp3.3/minbrack.htm @ 0:e9a9cd732c1e tip

first hg version after svn
author wolffd
date Tue, 10 Feb 2015 15:05:51 +0000
parents
children
rev   line source
wolffd@0 1 <html>
wolffd@0 2 <head>
wolffd@0 3 <title>
wolffd@0 4 Netlab Reference Manual minbrack
wolffd@0 5 </title>
wolffd@0 6 </head>
wolffd@0 7 <body>
wolffd@0 8 <H1> minbrack
wolffd@0 9 </H1>
wolffd@0 10 <h2>
wolffd@0 11 Purpose
wolffd@0 12 </h2>
wolffd@0 13 Bracket a minimum of a function of one variable.
wolffd@0 14
wolffd@0 15 <p><h2>
wolffd@0 16 Description
wolffd@0 17 </h2>
wolffd@0 18 <CODE>brmin, brmid, brmax, numevals] = minbrack(f, a, b, fa)</CODE>
wolffd@0 19 finds a bracket of three points around a local minimum of
wolffd@0 20 <CODE>f</CODE>. The function <CODE>f</CODE> must have a one dimensional domain.
wolffd@0 21 <CODE>a < b</CODE> is an initial guess at the minimum and maximum points
wolffd@0 22 of a bracket, but <CODE>minbrack</CODE> will search outside this interval if
wolffd@0 23 necessary. The bracket consists of three points (in increasing order)
wolffd@0 24 such that <CODE>f(brmid) < f(brmin)</CODE> and <CODE>f(brmid) < f(brmax)</CODE>.
wolffd@0 25 <CODE>fa</CODE> is the value of the function at <CODE>a</CODE>: it is included to
wolffd@0 26 avoid unnecessary function evaluations in the optimization routines.
wolffd@0 27 The return value <CODE>numevals</CODE> is the number of function evaluations
wolffd@0 28 in <CODE>minbrack</CODE>.
wolffd@0 29
wolffd@0 30 <p><CODE>minbrack(f, a, b, fa, p1, p2, ...)</CODE> allows additional
wolffd@0 31 arguments to be passed to <CODE>f</CODE>
wolffd@0 32
wolffd@0 33 <p><h2>
wolffd@0 34 Examples
wolffd@0 35 </h2>
wolffd@0 36 An example of the use of this function to bracket the minimum of a function
wolffd@0 37 <CODE>f</CODE> in the direction <CODE>sd</CODE> can be found in <CODE>linemin</CODE>
wolffd@0 38 <PRE>
wolffd@0 39
wolffd@0 40 [min, mid, max, nevals]] = minbrack('linef', 0.0, 1.0, fa, f, pt, dir);
wolffd@0 41 </PRE>
wolffd@0 42
wolffd@0 43 where the function <CODE>linef</CODE> is used to turn a general function <CODE>f</CODE>
wolffd@0 44 into a one dimensional one.
wolffd@0 45
wolffd@0 46 <p><h2>
wolffd@0 47 Algorithm
wolffd@0 48 </h2>
wolffd@0 49
wolffd@0 50 Quadratic extrapolation with a limit to the maximum step size is
wolffd@0 51 used to find the outside points of the bracket. This implementation
wolffd@0 52 is based on that in Numerical Recipes.
wolffd@0 53
wolffd@0 54 <p><h2>
wolffd@0 55 See Also
wolffd@0 56 </h2>
wolffd@0 57 <CODE><a href="linemin.htm">linemin</a></CODE>, <CODE><a href="linef.htm">linef</a></CODE><hr>
wolffd@0 58 <b>Pages:</b>
wolffd@0 59 <a href="index.htm">Index</a>
wolffd@0 60 <hr>
wolffd@0 61 <p>Copyright (c) Ian T Nabney (1996-9)
wolffd@0 62
wolffd@0 63
wolffd@0 64 </body>
wolffd@0 65 </html>