Hi everyone,

I want to use the sign function in the body of CVX. The problem is that SIGN is not permitted in CVX:

Undefined function ‘sign’ for input arguments of type ‘cvx’.

Error in algo2_complex (line 134)

F = sign(F) * norm(F);

When I use others way, it doesn’t work too:

Disciplined convex programming error:

Cannot perform the operation: {complex affine} ./ {convex}

Error in ./ (line 19)

z = times( x, y, ‘./’ );

Error in algo2_complex (line 135)

F = F./abs(F)*norm(F);

Disciplined convex programming error:

Cannot perform the operation: {convex} .* {convex}

Error in * (line 36)

z = feval( oper, x, y );

Error in algo2_complex (line 136)

F = norm(F)*norm(F)/F;

Here is the expression of F :

F = log(2)/pk(k)

Rk(k) - 2real((Uk_mmse(:,k)’ * H((k-1)N+1 : kN,:)*Wk(:,j)));

Please help me to solve this problem. Thank you so much !