-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Priority in variable bridge #165
Comments
That's a messed up way to write the model! I don't know that I condone this approach. I would have done: model = Model(() -> POI.Optimizer(Mosek.Optimizer()))
@variable(model, x)
@variable(model, Q[1:1, 1:1] in PSDCone())
@variable(model, p in Parameter(1.0))
@constraint(model, Q[1, 1] == p)
@constraint(model, p * x == 0)
optimize!(model) |
I would write as @odow did. For me it is not surprising that Maybe the user-proof solution is that the Parameter set should only be used in I still think that a |
@odow The way you write it is exactly the model after bridging Thinking more about it, I think the behavior makes sense. There could also be only part of the matrices that are set to parameters in which case what is done currently is definitely right. |
In the following model,
Q
is added as a constrained variable in the copy and it is then set as a parameter after. Because of this, it goes through the slack bridge which create a new variable that is a parameter and that is equal toQ[]
. Then it fails saying that Mosek does not support quadratic constraints because it does not seeQ[]
as a parameter anymore.During a copy,
Parameter
should have higher priority to be added as variable-wise constraint.The text was updated successfully, but these errors were encountered: