A way to write a convex function in such a way that CVX understands it

I need to solve the following problem:

(\bigstar)\left\{\begin{array}{lll} {\displaystyle \inf_{(\beta,\lambda)\in\mathbb{R}^{2},s\in\mathbb{R}^{N}} } & {\displaystyle \lambda \varepsilon +\frac{1}{N}\sum_{i=1}^{N}s_{i}} &\\ \mbox{subject to} &\beta^{2}+4a_{i}\lambda\beta+4a_{i}^{2}\lambda-4\lambda s_{i}+4s_{i}\leq 0 & \forall i\leq N \\ &\lambda >1& \\ & \beta\geq 0.& \end{array}\right.

where \varepsilon, a_{i}\in \mathbb{R} are fixed for all i=1,2,\ldots,N.

My intention is to use CVX, but I have problems, as it is stated (\bigstar) the solver does not interpret it.

Remark: I do not know if the following is useful, but note that the constrain

\beta^{2}+4a_{i}\lambda\beta+4a_{i}^{2}\lambda-4\lambda s_{i}+4s_{i}\leq 0 \quad \forall i\leq N

can be changed by

\frac{\beta^{2}}{4(\lambda-1)}+\frac{\lambda}{\lambda-1}a_{i}(\beta+a_{i})-s_{i}\leq 0 \quad \forall i\leq N

I showed that the function f:\mathbb{R}^{3}\rightarrow \mathbb{R} given by f(\beta,\lambda,s):=\frac{\beta^{2}}{4(\lambda-1)}+\frac{\lambda}{\lambda-1}a(\beta+a)-s is convex in \mathbb{R}\times\mathbb{R}_{\geq 1}\times\mathbb{R} for any a\in \mathbb{R}.

My attempt: CVX can solve geometric programs (GP), the problem is that (\bigstar) is not a geometric program because a_{i} can be negative, my idea was to express (\bigstar) as a geometric program but what arrived was the following equivalent formulation:

(\blacktriangle)\left\{ \begin{array}{lll} {\displaystyle \inf_{\beta,\lambda,s_{i},r_{i}} } & r_{0} & \\ \mbox{subject to} & \varepsilon\lambda r_{0}^{-1}+\frac{1}{N}\sum_{i=1}^{N}s_{i}r_{i}\leq 1 &\\ &\left.\begin{array}{l}\beta^{2}r_{i}^{-1}+4a_{i}\lambda \beta r_{i}^{-1}+4a_{i}^{2}\lambda r_{i}^{-1}+4s_{i}r_{i}^{-1}+r_{i}^{-1}\leq 1 \\ 4\lambda s_{i}r_{i}^{-1}+r_{i}^{-1}\geq 1 \end{array}\right\} &\forall i\in I_{1} \\ &\left.\begin{array}{l}\beta^{2}r_{i}^{-1}+4a_{i}^{2}\lambda r_{i}^{-1}+4s_{i}r_{i}^{-1}+r_{i}^{-1}\leq 1 \\ 4\lambda s_{i}r_{i}^{-1}+4(-a_{i})\lambda\beta r_{i}^{-1}+r_{i}^{-1}\geq 1 \end{array}\right\} &\forall i\in I_{2} \\ & \lambda >1 & \\ & \beta\geq 0. \end{array}\right.

where I_{1}:=\{i \:|\: 0<i\leq N \mbox{ such that } a_{i}\geq 0 \} and I_{2}:=\{i \:|\: 0<i\leq N \mbox{ such that } a_{i}< 0 \}.

The problem of (\blacktriangle) is that it is not yet a geometric program, the difficulty is in the constrains \geq 1. The only advantage that has (\blacktriangle) is that all constrains are in terms of posynomials, really do not know if this is an advantage because CVX has not yet interpreted it, it shows an error in the restrictions \geq 1.

Since my attempt has not had the desired results I hope that someone will read this problem, my can help with a way to solve it or a way of expressing it in such a way that CVX can solve it.

There’s just no way to do this, Diego. Your problem simply isn’t convex (before or after the standard GP transformation).