Error using *
Disciplined convex programming error:
Invalid quadratic form: product is complex.
Error in Jan12_SumRate (line 138)
2*real(((v_0*H_hat+H_Direct_WET(i,:))*a_k(:,i)).'*((v0*H_hat+H_Direct_WET(:,i))*ak(:,i))) -abs(((v_0*H_hat+H_Direct_WET(:,i))*a_k(:,i)))^2 >= b_k-(log(z(i)))/q_k;
% v0 and ak optimal, used this for next iterations
I have checked the expression and it is correct as per my understanding. I am running for loop, i=1:K. and defined following variables in cvx
((v_0*H_hat+H_Direct_WET(i,:))*a_k(:,i))
has multiplicatio0n of v_0 and a_k, both of which are variables. That should be sufficient to cause the error message. i don’t know how many other errors your program contains.
It would appear that you have not done SCA correctly, given that you have this non-convex item.