Hey there,

I have to implement one optimization problem from the communication domain. The issue I have is that cvx gets me the message

Error using .* (line 173)

Disciplined convex programming error:

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

Error in * (line 36)

z = feval( oper, x, y );

Error in algo (line 17)

SINR = p(k) * (f(:,j)’ * R(:,:,j) * f(:,j));

Here is the original part of the problem formulation:

The problem seems to be the p(k) (part which is affine?), and as far as I understood it the total problem is therefore not necessarily convex. The cvx algorithm was defined by me like this:

```
N = 5; % Number of antennas
L = 10; % Codebook size
K = 20; % Number of single antenna users
P_max = 50;
cvx_begin
variable C
variable f(N, K) complex
variable p(K) nonnegative
maximize C
subject to
for k = 1:K
SINR = 1; % the +1 part in the SINR denominator
for j = 1:K
if k == j
continue
end
SINR = p(k) * (f(:,j)' * R(:,:,j) * f(:,j));
end
% SINR is the denominator of eq (3b)
real(p(k) * ( f(:,k)' * R(:,:,k) * f(:,k))) * inv_pos(SINR) >= C;
norm(f(:, k)) == 1;
end
sum(p) <= P_max;
cvx_end
```

The TA of the course gave the impression that the problem should be trivially solved in cvx so am I missing here something?

I have read that I should make sure that the problem is convex but my problem is that the TA told me to “just do it in CVX” so I would assume that it is. The examples in cvx from my lecture were trivial and i got stuck now.

I appreciate any advice.

Kind regards