[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Help-glpk] MathProg
From: |
address@hidden |
Subject: |
[Help-glpk] MathProg |
Date: |
Thu, 23 Sep 2004 20:12:50 -0700 |
Hello
I have a couple of questions about MathProg:
Is it possible to have a constraint generated
conditional on the value of a parameter? I am
aware of the conditional expression, but this
doesn't seem to do quite what I want, which is
to have a whole statement processed
conditionally. I want to do something like:
param p;
set S := 0..9;
var x{s in S};
param y{s in S};
var z;
if p = 1
my_constraint{s in S}: x[s] + z <= y[s];
Secondly, is it possible to include another file
in a model? I ask this because I need to create
several similar models with only a few different
constraints, and it would be easier to maintain
if all the common code was in one file included
by the others. Something similar to #include in
C/C++ would be ideal, but I can find no mention
of anything like this in the documentation.
Andrew
- [Help-glpk] MathProg,
address@hidden <=