Julia JuMP Infeasible problem - How to get insight into which constraints render the problem infeasible?
Asked Answered
P

0

6
using JuMP, Cbc

model = Model(with_optimizer(Cbc.Optimizer, seconds= (20 * 60), ratioGap = 0.10));

@variable(model, x[1:5], Bin);

@constraint(model, c1[i in 1:4], x[i] == 0 )
@constraint(model, c2[i in 4:5], x[i] == 1 )

@objective(model, Min, sum(x[i] for i in 1:5))

JuMP.optimize!(model)
# Problem is infeasible - 0.00 seconds

How could I get the information that constraints c1[4] and c2[4] render the problem infeasible?

c1[4] : x[4] = 0.0
c2[4] : x[4] = 1.0

Palladous answered 16/12, 2019 at 17:29 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.