I got this message for my optimization problem can anybody help me how to resolve this?
"Result index of attribute MathOptInterface.ObjectiveValue(1) out of bounds. There are currently 0 solution(s) in the model.
check_result_index_bounds at attributes.jl:170 [inlined]
get(model::Gurobi.Optimizer, attr::MathOptInterface.ObjectiveValue) at MOI_wrapper.jl:3126
_moi_get_result(model::Gurobi.Optimizer, args::MathOptInterface.ObjectiveValue) at JuMP.jl:1126
get(model::Model, attr::MathOptInterface.ObjectiveValue) at JuMP.jl:1154
objective_value(model::Model; result::Int64) at objective.jl:42
objective_value(model::Model) at objective.jl:42
top-level scope at ETMODEL Stochastic3.jl:206
eval at boot.jl:373 [inlined] "
How can I do that?
I was doing a Stochastic optimization problem with one uncertain variable, that works perfectly. Then I incorporate a second uncertain variable with a different number of scenarios. then I get the message.
Take another read of the “Please read” post. It describes how to format your code blocks.
The problem seems to be that the termination status was INFEASIBLE_OR_UNBOUNDED, which means that your problem doesn’t have a solution to query. You can also see that with the primal status of NO_SOLUTION.
If you expected your problem to have a finite optimal solution, then you should double check your formulation for mistakes.