[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-glpk] [feature] defining sets of dynamic dimensions?
From: |
Yingjie Lan |
Subject: |
Re: [Help-glpk] [feature] defining sets of dynamic dimensions? |
Date: |
Sat, 17 Jul 2004 08:47:05 -0700 (PDT) |
One interesting application of LP is the
Markov Decision Process (MDP). To formulate
such a problem, one need to define the
state space as index to decision variables
as well as to parameters, which would often be
multidimensional and dimension-dynamic.
For example, let (s1, s2) denote jobs due
on tomorrow and on the day after tomorrow,
but the factory can only finish 'cap' each day.
so the feasible pairs of (s1,s2) would be:
#################################
set ss := {
(s1,s2) :
s1 in 0..cap and
s2+s1 in 0..2*cap
};
#################################
This state space would enable us to plan
for two days into the future. If the new
feature has been implemented, we can do:
###################################
set ss:={
s{i in 1..2}:
sum{j in 1..i}s[j]<i*cap
};
###################################
The cool part for the second approach is that
it can be easily extended to any days:
#########################################
param horizon >0 integer;
set ss:={
s{i in 1..horizon}:
sum{j in 1..i}s[j] < i*cap
};
#########################################
I hope this can serve as an example, and I
hope there are other situations where such
feature can be convenient (I don't want to
be selfish :).
Thanks,
Lan
--- Andrew Makhorin <address@hidden> wrote:
> >It seems to me very challenging to have this
> >feature integerated into the language, isn't it?
> >And it would certainly increase the power of
> >the modeling language. I would appreciate any
> >feed back from you. Thanks!
>
> Thank you for your suggestion. Can you give a more
> meaningful example
> where such feature is needed?
>
>
>
__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - 100MB free storage!
http://promotions.yahoo.com/new_mail
- [Help-glpk] [feature] defining sets of dynamic dimensions?, Yingjie Lan, 2004/07/16
- Re: [Help-glpk] [feature] defining sets of dynamic dimensions?, Yingjie Lan, 2004/07/17
- Re: [Help-glpk] [feature] defining sets of dynamic dimensions?, Yingjie Lan, 2004/07/20
- RE: [Help-glpk] [feature] defining sets of dynamic dimensions?, Sebastien . deMentendeHorne, 2004/07/20
- Re: [Help-glpk] [feature] defining sets of dynamic dimensions?, Yingjie Lan, 2004/07/20
- Re[2]: [Help-glpk] [feature] defining sets of dynamic dimensions?, Yingjie Lan, 2004/07/22