help-glpk
[Top][All Lists]
Advanced

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

[Help-glpk] "multiplication of linear forms not allowed"


From: Reginald Beardsley
Subject: [Help-glpk] "multiplication of linear forms not allowed"
Date: Sun, 21 Oct 2012 07:45:52 -0700 (PDT)

I'm trying to apply the following constraint following a suggestion by xypron:

var M{J} ,binary;
var B{J,K} ,>= 0;

s.t. a{j}: -M[j]*sum{k in  K}B[j,k] <= A[j] <= M[j]*sum{k in K}B[j,k];

The goal being to force A[j] = 0 if the sum over k of B[j,k] = 0;

glpsol 4.47 exits w/ the message in the subject line.  I found Steglich's post 
of last month, but am having trouble w/ translating the notation in the CMPL 
1.7.0 manual to GMPL.

>From context, I'm guessing that overbar indicates the maximum and underbar the 
>minimum, but I can find nothing to confirm that. The first equation in section 
>8.3.1 appears to have a typo as there is no underbar in the range 
>specification.  Even if I assume the typo, and explicitly specify the 
>additional variables and  constraints, I still get the subject line message.  
>Just at a different point.

Is it possible to do this in GMPL?  If so, how?
At the moment, the only option I can see would be to make an initial solution 
w/o the constraint and then recast the problem and solve again.

Thanks,
Reg



reply via email to

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