x = fminbnd(fun, x1, x2)
[x, fval, exitflag, output] = fminbnd(fun, x1, x2, options)
x = fminbnd(problem)
| Parameter | Description |
|---|---|
| fun | scalar objective function. |
| x1, x2 | finite interval endpoints. |
| options | solver options. |
| Parameter | Description |
|---|---|
| x | estimated minimizer in the interval. |
| fval | objective value. |
| exitflag | termination indicator. |
| output | diagnostics. |
fminbnd applies Brent's bounded minimization method, combining golden-section steps with parabolic interpolation. A problem structure can contain objective, x1, x2 and options fields.
[x, fval] = fminbnd(@(x) (x - 1.5)^2, -2, 4)
| Version | Description |
|---|---|
| 2.0.0 | initial version |