You have a strict inequality constraint on the northeast entry of the Gram matrix Q := W.T * W
, which is symmetric and positive semidefinite. Hence, do work with Gram matrix Q
instead and then introduce the strict inequality constraint Q[0,2] > 1
.
For example, here's a semidefinite program (SDP) with zero objective:
>>> from cvxpy import *
>>> Q = Semidef(3)
>>> objective = Minimize(0)
>>> constraints = [ Q[0,2] > 1 ]
>>> prob = Problem(objective,constraints)
>>> prob.solve()
0.0
>>> Q.value
matrix([[ 2.33101529e+00, 2.57980002e-30, 1.76709537e+00],
[ 2.57980002e-30, 2.57740598e-15, -2.00304682e-30],
[ 1.76709537e+00, -2.00304682e-30, 2.33101529e+00]])
Note that the northeast entry is 1.76709537e+00 > 1
. To recover matrix W
from Gram matrix Q
, use the Cholesky decomposition and append a row of zeros to obtain a 4 x 3 matrix, as follows:
>>> import numpy as np
>>> L = np.linalg.cholesky(Q.value)
>>> W = (np.insert(L, 3, np.array([0,0,0]), axis=1)).T
>>> W
matrix([[ 1.52676628e+00, 1.68971508e-30, 1.15741053e+00],
[ 0.00000000e+00, 5.07681591e-08, -7.79768444e-23],
[ 0.00000000e+00, 0.00000000e+00, 9.95698832e-01],
[ 0.00000000e+00, 0.00000000e+00, 0.00000000e+00]])
Let us verify:
>>> W.T * W - Q.value
matrix([[ 0.00000000e+00, 0.00000000e+00, 0.00000000e+00],
[ 0.00000000e+00, 0.00000000e+00, 7.00649232e-46],
[ 0.00000000e+00, 7.00649232e-46, 0.00000000e+00]])