Mercurial > hg > octave-avbm
changeset 11763:8e6dc8dd94e7 release-3-0-x
__qp__.cc: avoid bounds error when removing constraint from active set
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Wed, 23 Apr 2008 16:51:55 -0400 |
parents | 6a8fd365eebd |
children | 41ae2c287e3a |
files | src/ChangeLog src/DLD-FUNCTIONS/__qp__.cc |
diffstat | 2 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-04-23 John W. Eaton <jwe@octave.org> + + * DLD-FUNCTIONS/__qp__.cc (qp): Avoid bounds error when removing + constraint from active set. + 2008-04-21 John W. Eaton <jwe@octave.org> Version 3.0.1 released.
--- a/src/DLD-FUNCTIONS/__qp__.cc +++ b/src/DLD-FUNCTIONS/__qp__.cc @@ -355,6 +355,7 @@ // At least one multiplier is negative, we // remove it from the set. + n_act--; for (octave_idx_type i = which_eig; i < n_act - n_eq; i++) { Wact(i) = Wact(i+1); @@ -362,7 +363,6 @@ Aact(n_eq+i,j) = Aact(n_eq+i+1,j); bact(n_eq+i) = bact(n_eq+i+1); } - n_act--; // Resizing the active set. Wact.resize (n_act-n_eq);