semidefinite cone docs
@@ -37,7 +37,7 @@ orthants, then SOCs, etc.
- :code:`q, qsize`, array of SOC sizes of len :code:`qsize`
* - Positive semidefinite cone
- :math:`\{ S \in \mathbf{R}^{n \times n} \mid \min_i \lambda_i(S) \geq 0, S = S^\top \}`
- - :code:`s, ssize`
+ - :code:`s, ssize` see note below
* - Exponential cone
- :math:`\{ (x,y,z) \in \mathbf{R}^3 \mid y e^{x/y} \leq z, y>0 \}`
- :code:`ep`, number of cone triples
@@ -51,6 +51,38 @@ orthants, then SOCs, etc.
- :math:`\{ (u,v,w)\in \mathbf{R}^3 \mid (u/p)^p (v/(1-p))^{1-p} \geq |w|, u\geq 0, v\geq 0 \}`
- :code:`p, psize`
+Semidefinite cone
+^^^^^^^^^^^^^^^^^^^^^^^^
+
+SCS assumes that the matrix variables and the input data corresponding to
+semidefinite cones have been vectorized by scaling the off-diagonal entries by
+:math:`\sqrt{2}` and stacking the lower triangular elements column-wise. For a :math:`k \times k`
+matrix variable (or data matrix) this operation would create a vector of length
+:math:`k(k+1)/2`. Scaling by :math:`\sqrt{2}` is required to preserve the inner-product.
+
+To recover the matrix solution this operation must be inverted on the components
+of the vector returned by SCS corresponding to semidefinite cones. That is, the
+off-diagonal entries must be scaled by :math:`1/\sqrt{2}` and the upper triangular
+entries are filled in by copying the values of lower triangular entries.
+
+More explicitly, we want to express :math:`Tr(C X)` as :math:`\text{vec}(C)^\top \text{vec}(X)`,
+where the :math:`\text{vec}` operation takes the :math:`k \times k` matrix
+
+.. math::
+
+ X = \begin{bmatrix}
+ X_{11} & X_{12} & \ldots & X_{1k} \\
+ X_{21} & X_{22} & \ldots & X_{2k} \\
+ \vdots & \vdots & \ddots & \vdots \\
+ X_{k1} & X_{k2} & \ldots & X_{kk} \\
+ \end{bmatrix}
+
+and produces a vector consisting of the lower triangular elements scaled and arranged as
+
+.. math::
+
+ \text{vec}(X) = (X_{11}, \sqrt{2} X_{21}, ..., \sqrt{2} X_{k1}, X_{22}, \sqrt{2}X_{32}, ..., \sqrt{2}X_{k(k-1)}, X_{kk}).
+
Settings
--------
