Mercurial > octave
comparison scripts/optimization/fminunc.m @ 21578:683a1beee538
maint: Use "FIXME:" for all code blocks needing further attention.
* files-dock-widget.cc, file-editor-tab.cc, file-editor-tab.h,
file-editor.cc, octave-qscintilla.cc, octave-qt-link.cc, __ilu__.cc, debug.h,
oct-stream.cc, pt-jit.cc, __magick_read__.cc, ov-classdef.cc, pt-stmt.cc,
oct-sort.cc, inputParser.m, validateattributes.m, fminunc.m, fsolve.m, fzero.m,
__scatter__.m, print.m:
Use "FIXME:" for all code blocks needing further attention.
author | Rik <rik@octave.org> |
---|---|
date | Fri, 01 Apr 2016 14:55:13 -0700 |
parents | f7f97d7e9294 |
children | b571fc85953f |
comparison
equal
deleted
inserted
replaced
21577:31823239207e | 21578:683a1beee538 |
---|---|
431 | 431 |
432 ## Solve the double dogleg trust-region minimization problem: | 432 ## Solve the double dogleg trust-region minimization problem: |
433 ## Minimize 1/2*norm(r*x)^2 subject to the constraint norm(d.*x) <= delta, | 433 ## Minimize 1/2*norm(r*x)^2 subject to the constraint norm(d.*x) <= delta, |
434 ## x being a convex combination of the gauss-newton and scaled gradient. | 434 ## x being a convex combination of the gauss-newton and scaled gradient. |
435 | 435 |
436 ## TODO: error checks | 436 ## FIXME: error checks |
437 ## TODO: handle singularity, or leave it up to mldivide? | 437 ## FIXME: handle singularity, or leave it up to mldivide? |
438 | 438 |
439 function x = __doglegm__ (r, g, d, delta) | 439 function x = __doglegm__ (r, g, d, delta) |
440 ## Get Gauss-Newton direction. | 440 ## Get Gauss-Newton direction. |
441 b = r' \ g; | 441 b = r' \ g; |
442 x = r \ b; | 442 x = r \ b; |