I am solving a model that sets a numeraire based on the previous solution values (or starting values for the first solve). I am running into an issue where I fix a variable, but the value is still the old value.
Here is a small example:
using JuMP
using PATHSolver
M = direct_model(PATHSolver.Optimizer())
@variable(M, x>=0, start = 1)
@variable(M, y>=0, start = 1)
fix(y,2; force=true)
@constraint(M, (x-y) ⟂ x)
optimize!(M)
This code works and the value of x is 2, as expected.
Before the next solve I need to do the following
fix(y, 20; force=true)
value(x*y)
and would like to get 40, but get 4. Even though y is fixed to 20, the value is still 2.
Is there a way to do this? Any help would be greatly appreciated.