Hi, i face this problem which i try find the solutions in cvx. But i failed.

Could anyone see this before?

problems:

```
argmin_A(sum(hinge_loss(theta(x,y)'*A*theta(x,y) - theta(u,v)'*A*theta(u,v)))+miu*nuclear_norm(A))
```

where (x,y) in positive sets, (u,v) in negative sets, miu is the trad_off parameter.

And the variable is A, theta(z) is the distance, ie, Hamming distance or Euclidean distance;

hinge_loss(z) = max(z,100), nuclear_norm(z) = ||z||_* = trace(Z).

A is positive semi-definitive, because of A is w’*w. Then A is convex, hinge loss function is convex, and nuclear norm is convex. So it may be solved by cvx.

I try cvx code:

```
miu = logspace(-2,2,10);
z = 10000;
I=eye(100,100);
for k =1 : length(miu)
fprintf(1,'%8.4e',miu(k));
cvx_begin
variable A(30,30) hermitian semidefinite
minimize(sum(max(thetaX'*A*thetaX - thetaU'*A*thetaU + z*I,0) + miu(k)*trace(A)*I))
cvx_end
l1 = thetaX'*A*thetaX - thetaU'*A*thetaU;
l2 = trace(A);
fprintf(1,' %8.4e %8.4e\n',l1(k),l2(k));
end
```

It is wrong. Somebody can help me? and it shows:

**Error using cvx/max (line 88)
Disciplined convex programming error:
Cannot perform the operation max( {complex
affine}, {constant} )**