I know K (16x16) and s_i =SMP(:,ii) where SMP is (4x16) . Both of these variables are non-complex. W is the optimum precoding matrix. I wrote this problem as below

cvx_begin
variable t nonnegative
variable W(4,4) nonnegative diagonal
maximize t
subject to
t <= transpose(vec(W))*K*vec(W)
for ii=1:16
W*SMP(:,ii)>=zeros(4,1)
W*SMP(:,ii)<=ones(4,1)
end
cvx_end

It appears that K should really be indexed by i and j, and that you need a constraint for every i \ne j, yet you only have a single constraint involving K, and you do not show us what that K is.

You declared W as diagonal, yet the image has W' as well as W, which would seem strange if W is diagonal (which isn’t mentioned in the image).

There may be more wrong as well, but perhaps get started on this.

In the paper, it is stated that “The diagonal precoder can be obtained by solving the optimization problem in (12) with an additional constraint w_kl = 0 when k ̸= l.
”
The diagonal precoder
WD obtained by solving (12) is given by WD = diag{0.2154, 0.4290, 0.3568, 0.5}

I hope these info are useful to describe my problem.

Have you proven this is a convex optimization problem? Per the rules of the forum, a statement in a book or paper asserting convexity or solvability by CVX doesn’t count.