Hello dear all,

I’ve come across this error :

Error using .* (line 173)

Disciplined convex programming error:

Cannot perform the operation: {positive constant} ./ {concave}

Error in ./ (line 19)

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

Error in Scenario_one (line 177)

minimize((1-thau/T)*sum(log2(1+ denum./(term1*(x^2) + term2*x + constant))))

and my problem is:

and this is my code:

coef=sum(beta)+1/Pd;

coef1=(betajam*Q*T)/thau;

coef2=(betajam*Q*T)/((T-thau)*Pd);

term1=-3*coef2.**coef1;*

term2=coef.*coef1+3*coef2.*coef1-coef2*thauPt.*beta-coef2;*

constant=coefthauPt.*beta+coef+coef2*thau*Pt.**beta+coef2+(thau*Pt(beta.^2));

denum=thau*Pt*(beta.^2);

cvx_begin

variable x

minimize((1-thau/T)*sum(log2(1+ denum./(term1*(x^2) + term2*x + constant))))

subject to

0 <= x <= 1

cvx_end

I have actually tried to make the function which goes into the Log, I mean Log(1+1/func) like:

constant*x^2 + constant*x + constant

and as it is indicated “func” is concave

Log(1+1/x) is convex

so we can say that the final function is Convex but CVX doesn’t work!

I don’t know whether this is a special case of your function. But consider

`log(1+1/(x^2+x+1))`

.

The 2nd derivative evaluated at x = 0.1 is negative, and at x= 0.2 is positive. So that function is neither convex nor concave for 0 <= x <= 1.

Also, even if the function is convex, the fact that CVX rejects a program which violates its rules does not mean “CVX doesn’t work”, at least as some people would interpret it. CVX can’t handle all convex optimization problems, even aided by the best conic reformulators.

Thank you very much for your answer.

I would be grateful if you could help me with the way I should simulate my problem.

I have not reached a solution yet.

I think you would have to use a non-convex solver, for instance under YALMIP.