I’ve confirmed that this function is convex for all x in R. I try to use quad_over_lin(Q,L) to express this, where Q = 3x^2, L = 4+2abs(x)
However, CVX told me the second term (L) should be concave. How to fix this problem? Or should I try another way?
Erling is right that the presence of |x| in the denominator is only tolerable (i.e., results in a convex expression) because of x^2 in the numerator. In general you’ll find that such strong couplings makes it far trickier to reformulate. In case of t \geq \frac{3 x^2}{4 + 2 |x|}
it is not too difficult (plot the graphs + trial-and-error) to see that it is equivalent to t \geq \frac{3 x^2}{4 + 2 x} and t \geq \frac{3 x^2}{4 - 2 x}
but this trick only works on the limited domain -2 \leq x \leq 2 on which both denominators are nonnegative.
Thanks for your answer. I expressed my function into a form of minimize t given the condition you provided and successfully got the results from CVX. Thanks again for your help!
Compared to the first version, this version looks more efficient and beautiful than the first one. I find it is an art to reformulate a function into a form that CVX can recognize. Also, thanks for your recommendation for that cookbook. It helps me a lot and gives me a guide to deal with more complicated functions. Really thanks for your help.