[FlopCpp] index in computation
Michael Chen
vancouver.michael at gmail.com
Tue Mar 3 00:05:40 EST 2009
Dear there,
I am wondering how to express this constraint in flopcpp:
const int L = 3;
MP_set K(L);
MP_variable z(K);
Mp_variable x(K);
MP_constraint balance(K);
and here is the constraint in question:
for k=1,...,K, balance(k):
z(k) = sum_{i=1}^k ( k - i ) * x(i);
The problem is that FlopC++ doesn't seem to allow MP_set in direct
computation (k - i).
Sincerely Yours,
Michael
--
Best regards,
Michael Chen
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://list.coin-or.org/pipermail/flopcpp/attachments/20090303/517a1157/attachment.html
More information about the FlopCpp
mailing list