[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-glpk] Minimizing an array sum

From: glpk xypron
Subject: Re: [Help-glpk] Minimizing an array sum
Date: Wed, 13 Oct 2010 20:23:17 +0200

Hello Dirso,

your problem description can be formulated in GMPL as:

# year, measure, res
set A, dimen 3;

param d{A};

var a;
var b;
var c;

minimize obj :
  sum{(year, measure, res) in A} res - c - b * measure - a * year;

Your problem is unbounded.

For appropriate a, b, c in {-infinity, +infinity}
sum{d[i]} = -infinity.

Best regards


-------- Original-Nachricht --------
> Datum: Wed, 13 Oct 2010 11:36:59 -0300
> Betreff: [Help-glpk] Minimizing an array sum

> Hi,
> I'm using GLPK C API and I'm having problems to express my objective.
> I have about 40 conditions: a*year[i] + b*measure[i] + c + d[i] = res[i]
> I have to find the tuple {a,b,c}, where sum{d[i]} in minimum
> Data I have: arrays year[], measurem[], res[]. This is NOT LPI
> Any ideas?
> Thanks,
> Dirso

GMX DSL Doppel-Flat ab 19,99 €/mtl.! Jetzt auch mit 
gratis Notebook-Flat!

reply via email to

[Prev in Thread] Current Thread [Next in Thread]