[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
octave-3.0.1_forge.gcc-dw2 (Bug of glpk.was fixed.)
From: |
Tatsuro MATSUOKA |
Subject: |
octave-3.0.1_forge.gcc-dw2 (Bug of glpk.was fixed.) |
Date: |
Tue, 19 Aug 2008 14:28:24 +0900 (JST) |
Hello
Jiri Peinlich pointed out the Bug of glpk in my distrubution
octave-3.0.1_forge.gcc-dw2.
Jaroslav Hajek kindly made the fixing the bug.
I have re-update octave-3.0.1_forge.gcc-dw2 at
http://www.tatsuromatsuoka.com/octave/Eng/Cygwin/
Note:
Because cygwin suppots some dependencies of octave 3.0.1, I used it as
posssible.
Therefore you should also install glpk, fftw, qhull and gmp through cygwin
setup.
Regards
Tatsuro
--- Tatsuro MATSUOKA <address@hidden> wrote:
> Hello Jaroslav Hajek
>
> Thanks!!
>
> $ ./run-octave
> GNU Octave, version 3.0.1
> Copyright (C) 2008 John W. Eaton and others.
> This is free software; see the source code for copying conditions.
> There is ABSOLUTELY NO WARRANTY; not even for MERCHANTIBILITY or
> FITNESS FOR A PARTICULAR PURPOSE. For details, type `warranty'.
>
> Octave was configured for "i686-pc-cygwin".
> :
> :
> octave:1> c = [-22,-25]; a = a = [2,1;1,1;1,2]; b = [26,14,22];
> octave:2> glpk(c, a, b, [], [], 'UUU')
> ans =
>
> 6
> 8
>
> Your changeset seemed to work well.
> Please apply it to the octave-3.0.2.
>
> Anyway I will repackage current octave-3.0.1 on cygwin (by gcc-dw2) and
> upload soon.
>
> Thanks again.
>
> Regards
>
> Tatsuro
>
>
> --- Tatsuro MATSUOKA <address@hidden> wrote:
>
> > Hello Jaroslav Hajek
> >
> > Thanks!!
> >
> > I have just patched the source files using your changeset and no buiding
> > octave on cygwin.
> >
> > I will report the results later.
> >
> > Rergards
> >
> > Tatsuro
> >
> >
> > --- Jaroslav Hajek <address@hidden> wrote:
> >
> > > Hello,
> > >
> > > I think I may have located the problem. Certain matrix sizes seem to
> > > be assumed in the __glpk__ DLD function but one is passed incorrectly
> > > due to a typo in glpk.m.
> > > Attached is a fix. I've also added proper size checks to __glpk__.cc
> > > Tatsuro, Jiri, can you verify this indeed fixes the problem?
> > >
> > > regards,
> > >
> > >
> > >
> > > --
> > > RNDr. Jaroslav Hajek
> > > computing expert
> > > Aeronautical Research and Test Institute (VZLU)
> > > Prague, Czech Republic
> > > url: www.highegg.matfyz.cz
> > > > # HG changeset patch
> > > # User Jaroslav Hajek <address@hidden>
> > > # Date 1219067310 -7200
> > > # Node ID 13f64ee5c1e94ccdd26d4e0689a6889b28df1f86
> > > # Parent 2fd4a5ef6b593a531f248d25341e7e25d4d979e3
> > > fix invalid memory read in glpk
> > >
> > > diff --git a/scripts/ChangeLog b/scripts/ChangeLog
> > > --- a/scripts/ChangeLog
> > > +++ b/scripts/ChangeLog
> > > @@ -1,3 +1,7 @@
> > > +2008-08-18 Jaroslav Hajek <address@hidden>
> > > +
> > > + * optimization/glpk.m: Fix invalid call to zeros.
> > > +
> > > 2008-08-08 John W. Eaton <address@hidden>
> > >
> > > * general/Makefile.in (SOURCES): Add cellidx.m to the list.
> > > diff --git a/scripts/optimization/glpk.m b/scripts/optimization/glpk.m
> > > --- a/scripts/optimization/glpk.m
> > > +++ b/scripts/optimization/glpk.m
> > > @@ -470,7 +470,7 @@
> > >
> > > if (nargin > 3)
> > > if (isempty (lb))
> > > - lb = zeros (0, nx, 1);
> > > + lb = zeros (nx, 1);
> > > elseif (! isreal (lb) || all (size (lb) > 1) || length (lb) != nx)
> > > error ("LB must be a real valued %d by 1 column vector", nx);
> > > return;
> > > diff --git a/src/ChangeLog b/src/ChangeLog
> > > --- a/src/ChangeLog
> > > +++ b/src/ChangeLog
> > > @@ -1,3 +1,8 @@
> > > +2008-08-18 Jaroslav Hajek <address@hidden>
> > > +
> > > + * DLD-FUNCTIONS/__glpk__.cc (F__glpk__): Checks whether LB and UB are
> > > + of proper size.
> > > +
> > > 2008-08-12 John W. Eaton <address@hidden>
> > >
> > > * pt-fcn-handle.cc (tree_anon_fcn_handle::rvalue):
> > > diff --git a/src/DLD-FUNCTIONS/__glpk__.cc b/src/DLD-FUNCTIONS/__glpk__.cc
> > > --- a/src/DLD-FUNCTIONS/__glpk__.cc
> > > +++ b/src/DLD-FUNCTIONS/__glpk__.cc
> > > @@ -575,7 +575,7 @@
> > > //-- bound on each of the variables.
> > > Matrix LB (args(3).matrix_value ());
> > >
> > > - if (error_state)
> > > + if (error_state || LB.length () < mrowsc)
> > > {
> > > error ("__glpk__: invalid value of lb");
> > > return retval;
> > > @@ -600,7 +600,7 @@
> > > //-- bound on each of the variables.
> > > Matrix UB (args(4).matrix_value ());
> > >
> > > - if (error_state)
> > > + if (error_state || UB.length () < mrowsc)
> > > {
> > > error ("__glpk__: invalid value of ub");
> > > return retval;
> > >
> >
> >
> > --------------------------------------
> > For All Sports Lovers! SPORTS OHEN PROJECT 2008
> > http://pr.mail.yahoo.co.jp/yells/
> > _______________________________________________
> > Bug-octave mailing list
> > address@hidden
> > https://www-old.cae.wisc.edu/mailman/listinfo/bug-octave
> >
>
>
> --------------------------------------
> For All Sports Lovers! SPORTS OHEN PROJECT 2008
> http://pr.mail.yahoo.co.jp/yells/
>
--------------------------------------
For All Sports Lovers! SPORTS OHEN PROJECT 2008
http://pr.mail.yahoo.co.jp/yells/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- octave-3.0.1_forge.gcc-dw2 (Bug of glpk.was fixed.),
Tatsuro MATSUOKA <=