Presuming inv(R) and inv(Qx) are symmetric, the constraint in YALMIP is an LMI (SDP).
However, you have specified an elementwise nonnegativity constraint in CVX.
Square matrix variables in YALMIP are symmetric by default. They are not in CVX.
FIx: variable X(n,n) symmetric
YALMIP is essentially always in what is called sdp mode in CVX. But CVX by default is not.:
FIx: cvx_begin sdp
or instead of sdp mode, use LHS == semidefinite(matrix dimension being constrained)
Thank you Mark, I haven’t paid attention about these details.
one more thing: Assume I want to find a sequence of X and L (so to solve finite horizon problems and find K(k) over k in 0,…N-1, where N is my time horizon). Are iterations supported in cvx?
I’m not sure exactly what your model is, but you can declare 3D arrays in which the first two dimensions are symmetric. variable X(n,n,N) symmetric
declares that X(:,:,k) is symmetric for each value of k.
Then use constraints or expression assignments to capture (constrain) the evolution over time.