Looking at one of the 2 by 2 diagonal blocks of your Hessian, determinant is `4.5680*6.3110 - 5.3794^2 = -0.109`

, so not psd, and indeed, indefinite.

My Maple code:

`f:=p11/(x-a*p11-b*p21)+p21/(x-a*p11-b*p21)+p12/(x-a*p12-b*p22)+p22/(x-a*p12-b*p22);`

`evalf(Eigenvalues(subs(x=1,a=0.5,b=0.4,p11=.5,p12=.5,p21=.5,p22=.5,Hessian(f,[p11,p12,p21,p22]))));`

Result is two eigenvalues equal to -0.01003594586 and two eigenvalues equal to 10.88907426.

As for the question in the 2nd to last paragraph, I’ve lost the bubble on what this problem is, what are the optimization variables as opposed to input data. What constraint are you trying to formulate? If your first form is what you want, and complies with CVX’s rules, then why do you want to change it? If you have a constraint you can;'t figure out how to enter in CVX, then first, present the constraint very clearly, including what the optimization variables are and what the input data is, and second, prove it is a convex constraint.