Hello
I’m trying to use the solver Mosek to solve a SDP problem via the “Powermodels.jl” library. My code is very simple:
using powermodels
using MosekTools
solver4 = Mosek.Optimizer;
SDP_relax=run_opf(“pglib_opf_case3_lmbd__sad.m”, SDPWRMPowerModel, solver4);
I get the following output:
[info | PowerModels]: removing 3 cost terms from generator 3: Float64
Problem
Name :
Objective sense : min
Type : CONIC (conic optimization problem)
Constraints : 84
Cones : 8
Scalar variables : 59
Matrix variables : 1
Integer variables : 0
Optimizer started.
Presolve started.
Linear dependency checker started.
Linear dependency checker terminated.
Eliminator started.
Freed constraints in eliminator : 3
Eliminator terminated.
Eliminator - tries : 1 time : 0.00
Lin. dep. - tries : 1 time : 0.00
Lin. dep. - number : 0
Presolve terminated. Time: 0.01
Problem
Name :
Objective sense : min
Type : CONIC (conic optimization problem)
Constraints : 84
Cones : 8
Scalar variables : 59
Matrix variables : 1
Integer variables : 0
Optimizer - threads : 4
Optimizer - solved problem : the primal
Optimizer - Constraints : 48
Optimizer - Cones : 8
Optimizer - Scalar variables : 45 conic : 24
Optimizer - Semi-definite variables: 1 scalarized : 21
Factor - setup time : 0.02 dense det. time : 0.00
Factor - ML order time : 0.00 GP order time : 0.00
Factor - nonzeros before factor : 534 after factor : 702
Factor - dense dim. : 0 flops : 1.58e+04
ITE PFEAS DFEAS GFEAS PRSTATUS POBJ DOBJ MU TIME
0 4.0e+02 1.1e+03 1.7e+03 0.00e+00 1.378858223e+03 -3.617071068e+02 1.0e+00 0.05
1 1.4e+02 3.8e+02 1.0e+03 -9.95e-01 4.074408662e+02 -1.320859425e+03 3.4e-01 0.06
2 3.8e+01 1.0e+02 5.2e+02 -9.74e-01 1.056225490e+03 -5.947841219e+02 9.5e-02 0.06
3 6.7e+00 1.9e+01 1.8e+02 -8.88e-01 7.953694902e+02 -4.625306879e+02 1.7e-02 0.06
4 3.3e+00 9.0e+00 8.8e+01 -3.48e-01 1.255338214e+03 3.559185005e+02 8.2e-03 0.06
5 2.0e+00 5.4e+00 5.5e+01 -1.10e-01 1.829408782e+03 1.077950342e+03 4.9e-03 0.06
6 7.3e-01 2.0e+00 1.7e+01 1.18e-01 3.259299899e+03 2.876855600e+03 1.8e-03 0.06
7 3.4e-01 9.3e-01 7.1e+00 4.03e-01 4.076878723e+03 3.838159851e+03 8.5e-04 0.06
8 1.3e-01 3.5e-01 1.7e+00 6.91e-01 5.024709577e+03 4.926966765e+03 3.1e-04 0.06
9 4.4e-02 1.2e-01 4.6e-01 6.57e-01 5.484760280e+03 5.443657139e+03 1.1e-04 0.06
10 1.6e-02 4.3e-02 1.1e-01 7.96e-01 5.731290680e+03 5.715191898e+03 3.9e-05 0.06
11 5.3e-03 1.5e-02 2.5e-02 8.19e-01 5.846258047e+03 5.840346953e+03 1.3e-05 0.08
12 7.1e-04 2.0e-03 1.2e-03 9.74e-01 5.911128044e+03 5.910324672e+03 1.8e-06 0.08
13 6.0e-05 1.7e-04 3.0e-05 9.98e-01 5.921172672e+03 5.921104873e+03 1.5e-07 0.08
14 3.3e-06 9.1e-06 3.9e-07 1.00e+00 5.922085568e+03 5.922081871e+03 8.2e-09 0.08
15 1.0e-07 2.8e-07 2.2e-09 1.00e+00 5.922136664e+03 5.922136547e+03 2.6e-10 0.08
16 4.9e-09 1.4e-08 2.2e-11 1.00e+00 5.922138254e+03 5.922138249e+03 1.2e-11 0.08
Optimizer terminated. Time: 0.09
MOSEK error 3915: There is no barx available for the solution type 2.
ERROR: Mosek.MosekError(3915, “There is no barx available for the solution type 2.”)
Stacktrace:
[1] getbarxj(task_::Mosek.Task, whichsol_::Mosek.Soltype, j_::Int32)
@ Mosek ~.julia\packages\Mosek\6LuE3\src\msk_functions.jl:2087
[2] getbarxj
@ ~.julia\packages\Mosek\6LuE3\src\msk_functions.jl:2077 [inlined]
[3] matrix_solution(m::MosekModel, sol::Mosek.Soltype)
@ MosekTools ~.julia\packages\MosekTools\sppJY\src\MosekTools.jl:268
[4] optimize!(m::MosekModel)
@ MosekTools ~.julia\packages\MosekTools\sppJY\src\MosekTools.jl:275
[5] optimize!(b::MathOptInterface.Bridges.LazyBridgeOptimizer{MosekModel})
@ MathOptInterface.Bridges ~.julia\packages\MathOptInterface\5WwpK\src\Bridges\bridge_optimizer.jl:293
[6] optimize!(m::MathOptInterface.Utilities.CachingOptimizer{MathOptInterface.AbstractOptimizer, MathOptInterface.Utilities.UniversalFallback{MathOptInterface.Utilities.Model{Float64}}})
@ MathOptInterface.Utilities ~.julia\packages\MathOptInterface\5WwpK\src\Utilities\cachingoptimizer.jl:237
[7] optimize!(model::Model, optimizer_factory::Nothing; bridge_constraints::Bool, ignore_optimize_hook::Bool, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ JuMP ~.julia\packages\JuMP\b3hGi\src\optimizer_interface.jl:185
[8] optimize! (repeats 2 times)
@ ~.julia\packages\JuMP\b3hGi\src\optimizer_interface.jl:157 [inlined]
[9] macro expansion
@ .\timing.jl:368 [inlined]
[10] optimize_model!(aim::SDPWRMPowerModel; relax_integrality::Bool, optimizer::Function, solution_processors::Vector{Any})
@ InfrastructureModels ~.julia\packages\InfrastructureModels\ts81X\src\core\base.jl:397
[11] run_model(data::Dict{String, Any}, model_type::Type, optimizer::typeof(Mosek.Optimizer), build_method::typeof(build_opf); ref_extensions::Vector{Any}, solution_processors::Vector{Any}, relax_integrality::Bool, multinetwork::Bool, multiconductor::Bool, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ PowerModels ~.julia\packages\PowerModels\bsxAD\src\core\base.jl:52
[12] run_model(data::Dict{String, Any}, model_type::Type, optimizer::Function, build_method::Function)
@ PowerModels ~.julia\packages\PowerModels\bsxAD\src\core\base.jl:35
[13] run_model(file::String, model_type::Type, optimizer::Function, build_method::Function; kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ PowerModels ~.julia\packages\PowerModels\bsxAD\src\core\base.jl:27
[14] run_model
@ ~.julia\packages\PowerModels\bsxAD\src\core\base.jl:26 [inlined]
[15] #run_opf#1077
@ ~.julia\packages\PowerModels\bsxAD\src\prob\opf.jl:13 [inlined]
[16] run_opf(file::String, model_type::Type, optimizer::Function)
@ PowerModels ~.julia\packages\PowerModels\bsxAD\src\prob\opf.jl:13
[17] top-level scope
@ none:1
I would appreciate your help in this regard.