Helloooooooooooooooooo !!!

> ok -- from here, what is the easiest way to add csts to p ?

Does this help ? It uses the fact that when you have any hashable object x
in Sage you can create an "associated" LP variable by writing p[x] :

sage: p = MixedIntegerLinearProgram()
sage: (x<= 5).rhs()
5
sage: int((x<= 5).rhs())
5
sage: (x<=5).lhs()
x
sage: p[(x<=5).lhs()] <= (x<= 5).rhs()
x_0 <= 5
sage: p.add_constraint(p[(x<=5).lhs()] <= (x<= 5).rhs())

Nathann

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-support?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to