CVX solves my problem, but I am hesitating whether it is a convex problem or not

I have problem in the following form:

\max_{x_{1,i},x_{2,i},m_{i},n_{i},R_{i}}~~\sum_{i=1}^{K}a_{i}\mathcal{R}_{i}\notag\\ \text{s.t.}~~ m_{i}\dfrac{a_{i}}{2}\leq b_{i},~ \forall i, \notag\\ ~\mathcal{R}_{i}\leq x_{1,i}+x_{2,i},\notag\\ ~\mathcal{R}_{i}\leq \log\big(1+\dfrac{c_{i}m_{i}+d_{i}}{C}\big),\notag\\ ~x_{1,i}\leq D_{i}\\ ~x_{1,i}\leq \log\big(1+n_{i}\big)\\ ~x_{2,i}\leq \log\big(1+2c_{i}m_{i}\big)\\ ~x_{2,i}\leq \log\big(1+d_{i}n_{i}\big)\\ ~\mathcal{R}_{i}, x_{1,i},x_{2,i},m_{i},n_{i}\geq 0~\forall i,

CVX successfully solves my problem and gives me the optimal solution (I use CVXQUAD); however, as I was writing down the solution in my paper, I hesitated about the convexity of my problem. Is my problem convex? I mean the logarithms in the RHS of some of the constraints do not make the feasible set non-convex, am I right?

The whole point of CVX is that you cannot formulate a nonconvex problem.

1 Like

Yes, What @Erling saif. Notre that you have concave expressions on the LHS of <= constraints, which is consistent with thee constraints being convex.


The following constraint types are supported in CVX (your constraint type is the second listed):

Equality == constraints, where both the left- and right-hand sides are affine expressions.

Less-than <= inequality constraints, where the left-hand expression is convex, and the right-hand expression is concave.

Greater-than >= constraints, where the left-hand expression is concave, and the right-hand expression is convex.

1 Like