Commit abfe25d1 authored by Rémi's avatar Rémi
Browse files

Loop on NA

parent ae77840b
......@@ -147,7 +147,7 @@ function mcm_ilp_odd_increment!(model::Model,
solved_once = false
timelimit = time_limit_sec(model)
total_solve_time = 0.0
while (!solved_once || (termination_status(model) in [MOI.INFEASIBLE, MOI.INFEASIBLE_OR_UNBOUNDED]) && timelimit > 0 && nb_total_adders_ub >= NA+1)
while (!solved_once) || (termination_status(model) in [MOI.INFEASIBLE, MOI.INFEASIBLE_OR_UNBOUNDED] && timelimit > 0 && nb_total_adders_ub >= NA+1)
NA += 1
empty!(model)
model[:scaling] = scaling
......@@ -164,9 +164,9 @@ function mcm_ilp_odd_increment!(model::Model,
set_time_limit_sec(model, timelimit)
optimize!(model)
solved_once = true
current_solve_time = solve_time(model)
total_solve_time += current_solve_time
timelimit -= current_solve_time
verbose && println("$(termination_status(model)) for NA=$(NA)")
end
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment