qp() in Octave 3.0.0 returns result egregiously violating input constraints

Dmitri A. Sergatskov dasergatskov at gmail.com
Sat Apr 5 01:06:58 CDT 2008


On Fri, Apr 4, 2008 at 8:24 PM, Joshua Redstone <redstone at gmail.com> wrote:
> Hi John,
> I've attached a data file created with (on OSX):
>     save -binary -z "./example.dat" x0 H Q A B LB UB A_LB A_IN A_UB
>
> The following should reproduce the problem for you:
>    load "example.dat"
>    [X, OBJ, INFO, LAMBDA] = qp(x0, H, Q, A, B, LB, UB, A_LB, A_IN, A_UB)
>
> With my qp.m that I modified so the last arguement is maxiter, I get the
> follow first few lines of output:
> octave-3.0.0:5> [X, OBJ, INFO, LAMBDA] = qp(x0, H, Q, A, B, LB, UB, A_LB,
> A_IN, A_UB, 187)
>  X =
>
>    0.17954
>     0.00000
>    0.01742
>     0.00304
>    0.16220
>     [... output truncated.... ]

I cannot reproduce the problem you were describing:

octave:11> X
X =

   1.8652e-01
  -1.6807e-18
   1.1024e-02
   2.4571e-03
   1.5873e-01
   4.5925e-18
   3.0011e-17
....

octave:12> max(X)
ans =  0.18652

   2.2584e-18
octave:13> sum(X)
ans =  1.00000

I suspect that some of your library is broken.
(BLAS/LAPACK is a popular candidate.)
Just for kicks what do you get for:

zzz=randn(1000); max(max(zzz*inv(zzz)))

?

Sincerely,

Dmitri.
--


More information about the Bug-octave mailing list