Square Root of Squared Norms


I’m getting a DCP error (i.e., “Disciplined convex programming error: Illegal operation: sqrt( {convex} )”) when entering the following constraint in my optimization problem:

\sqrt{\lVert \mathbf C ( -\mathbf W_1- \mathbf W_2) \mathbf C \rVert^2_F + 2\lVert \mathbf C (-\mathbf W_1 - \mathbf W_2) \mathbf h \rVert^2 } \leq

\frac{1}{\sqrt{2\delta}} \times ( trace[\mathbf C ( -\mathbf W_1 - \mathbf W_2)\mathbf C] + \mathbf h^H(-\mathbf W_1 - \mathbf W_2) \mathbf h - \delta x -\sigma^2 )

where the variables are \mathbf W_1,\mathbf W_2\in\mathbb{C}^{n\times n},x\in\mathbb{C} and everything else is a constant (note: \mathbf h\in\mathbb{C}^{n\times 1}, \mathbf C\in\mathbb{C}^{n\times n} and \delta,\sigma^2 are real scalars).

Could you please help me out?


I fixed the issue by rewriting the expression on the LHS as
[ \lVert {vec}({C(-W_1-W_2)C}); ~~ \sqrt{2}{vec}({C(-W_1-W_2)C}) \rVert ]