An error during solving a high-dimensional SDP using MOSEK with YALMIP

24 views
Skip to first unread message

Shabnam Khodakaramzadeh

unread,
Nov 21, 2025, 9:47:18 AMNov 21
to YALMIP

Dear Johan Löfberg,

I face a problem when solving the following SDP using MOSEK 9.3 with YALMIP in MATLAB R2024a on Windows 64-bit.

\begin{align}
\begin{array}{rcl}
& \min\limits_{L, D } & \Tr{L} \\
&\textrm{s.t.} & L \in \mathbb{S}_{+} , D \in \mathbb{D}_{+} , \\
            && \| L + D - \hat{\Sigma} \|_F \leq \epsilon
\end{array}
\end{align}

The set \mathbb{S}_{+} is the set of PSD symmetric matrices, and \mathbb{D}_{+} is the set of PSD diagonal matrices.
Tr(L) is the trace of matrix L.

For the dimensions of the matrices less than or equal to 150 the problem is solved perfectly. However, for the dimensions equal to 200 and higher, I receive the following error:

'Unknown problem in solver', which corresponds to 'YALMIP error code' equal to 9.

Would you please inform me about the reason for which this error occurs?

Thank you in advance,

Kind regards,
Shabnam


Johan Löfberg

unread,
Nov 21, 2025, 10:22:12 AMNov 21
to YALMIP
if you turn on 'debug' it will probably show that you are running out of memory

Shabnam Khodakaramzadeh

unread,
Nov 22, 2025, 5:23:50 PM (14 days ago) Nov 22
to YALMIP
Dear Johan,

Thank you for your kind help and the information.

It would be appreciated if you could help me with the following questions.

1. By changing the 'verbose' option, related to display-level, I saw the following information:
Mosek error: MSK_RES_ERR_SPACE (Out of space.)
Would you inform me if this is same as 'out of memory'?

2. Would you please inform me when in the third constraint, we use another metric for distance, like Gelbrich distance, G( L + D , \hat{\Sigma} ) or Kullback Leibler divergence, \KL( L + D || \hat{\Sigma} ), does the aforementioned error (Unknown problem in solver', which corresponds to 'YALMIP error code' equal to 9) occur also because of running out of memory?
 
Kind regards,
Shabnam

Johan Löfberg

unread,
Nov 23, 2025, 3:04:59 AM (14 days ago) Nov 23
to YALMIP
Yes, out of memory.

Already the existence of L>=0 poses a problem. To do this effiiciently for large problems you will have to come up with a way to dualize the problem or something similar, as L on its own introduces O(n^2) variables which will lead to at least O(n^4) hessian size etc
Reply all
Reply to author
Forward
0 new messages