A Quadratic Programming problem (QP) in the form of

where , can be transformed to a Second-Order Cone Programming (SOCP) problem in the form of

Consider , and

As is non-negative, minimizing is equivalent to minimizing , and hence is equivalent to minimizing .

If we have and , then the objective function in QP can be written as . We can thus minimize .

Thus, the QP problem can now be written as

As , by definition of QP, is symmetric, a symmetric can be found such that . If the QP is assumed to be a convex QP, is positive semidefinite, applying Cholesky factorization gives (or ). In this case, (or ).

Next, as is always non-negative, the equality constraint can be written as

Finally, each row in the inequality constraint can be written as

where is the i-th row of , and is the i-th element of .

Therefore, a QP problem can be transformed to an equivalent SOCP problem in the following way. We need to introduce a few variables first.

The sub-vector with the first elements in the solution of the transformed SOCP problem is the solution of the original QP problem.

SuanShu has implementations to solve both SOCP and QP problems.