Why does CVX accept log(2^exp(x)) but don't accept log(2^exp(x)-1)

Nonconvex
Nov 14, 2017
G

log(2^exp(x)) is convex, and log(2^exp(x)-1) should be convex,too.
I search in community and it seems like the CVX simply do not accept it even it is convex.
log(2^exp(x)) is accepted,
log(2^exp(x)+1) is accepted.
log(2^exp(x)-1) with: Illegal operation: log( {convex} ).
Is there any form to approximate it. or some other way out for this problem?
Thank you for your help.

M

Please read the documentation and the FAQ.

M
Replying to #2

That said, expressions involving log and exp don’t quite follow the DCP rules anyway. Still, they do have their own rules, and they can be found here.

G
Replying to #3

Thank you,it helps me a lot.