I am trying to be familiar with
MathOptInterface, in order to revise a package that has been written with
When I tried to add a variable into the Clp model, I got the following error.
julia> using MathOptInterface, Clp julia> optimizer = Clp.Optimizer() Clp.Optimizer julia> x = MOI.add_variable(optimizer) ERROR: MathOptInterface.AddVariableNotAllowed: Adding variables cannot be performed. You may want to use a `CachingOptimizer` in `AUTOMATIC` mode or you may need to call `reset_optimizer` before doing this operation if the `CachingOptimizer` is in `MANUAL` mode. Stacktrace:  add_variable(model::Clp.Optimizer) @ MathOptInterface ~\.julia\packages\MathOptInterface\5WwpK\src\variables.jl:37  top-level scope @ none:1 julia>
Could anyone explain why I got this error? There is no problem with the GLPK solver.
Thank you for reading my question