You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The PPL backend sets up a new PPL problem and re-solves it from scratch every time that get_variable_value or get_objective_value is called.
sage: p = MixedIntegerLinearProgram(solver='ppl', maximization=True)
sage: x = p.new_variable()
sage: p.set_objective(p.sum((i+20)*x[i] for i in range(1000)))
sage: p.add_constraint(p.sum((i+15)*x[i] for i in range(1000)), max=20000)
sage: x.set_max(1)
sage: p.solve() # takes a few seconds
11438750/507
sage: p.get_objective_value() # takes a few seconds, should be instant
11438750/507
sage: p.get_values(x) # takes forever, should be instant