Mercurial > hg > octave-nkf
diff scripts/optimization/glpk.m @ 10541:e9d1a974a517
Eliminate repmat (Inf, x , y) and simply use Inf (x,y)
author | Rik <code@nomad.inbox5.com> |
---|---|
date | Thu, 22 Apr 2010 14:38:58 -0700 |
parents | 09da0bd91412 |
children | 95c3e38098bf |
line wrap: on
line diff
--- a/scripts/optimization/glpk.m +++ b/scripts/optimization/glpk.m @@ -475,13 +475,13 @@ if (nargin > 4) if (isempty (ub)) - ub = repmat (Inf, nx, 1); + ub = Inf (nx, 1); elseif (! isreal (ub) || all (size (ub) > 1) || length (ub) != nx) error ("UB must be a real valued %d by 1 column vector", nx); return; endif else - ub = repmat (Inf, nx, 1); + ub = Inf (nx, 1); endif ## 6) Sense of each constraint