help-glpk
[Top][All Lists]
Advanced

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

[Help-glpk] [Fwd: No mod or round function available for variables]


From: Andrew Makhorin
Subject: [Help-glpk] [Fwd: No mod or round function available for variables]
Date: Wed, 06 Mar 2013 20:26:02 +0400

-------- Forwarded Message --------
From: Guest276 <address@hidden>
To: address@hidden
Subject: [Help-glpk] No mod or round function available for variables
Date: Wed, 6 Mar 2013 07:05:05 -0800 (PST)

Hi,

I am trying to solve the following problem:
I have an LP with a max objective function and some constraints. It is a
logistical problem. x is my variable that tells me how many pallets I should
ship on a certain route. 11 pallets can go in one 20-foot-container. I want
to add a restriction that forces the minimum number of pallets in a
container to be 6 or that the container should be 50% full. 
I tried to do this like that:
(x mod 11)/11 >= 0.5
This did not work, since mod is only available for parameters or numbers but
not for variables.
I tried the following:
x/11 - round(x/11) >= 0.5.
The same problem.

Has anyone an idea how I can model this without using mod or round?

Please help!!
Guest 276
-- 
View this message in context: 
http://old.nabble.com/No-mod-or-round-function-available-for-variables-tp35143735p35143735.html
Sent from the Gnu - GLPK - Help mailing list archive at Nabble.com.







reply via email to

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