Exponential perspective function with matrix variables

Hello, I understand that there already exists lots of posts about exponential perspective function. I tried various solutions that were introduced in the site, but I still get a error message.

The objective function is as follows:
f(x,tcp,tcm) =sum(sum( Ax^{B}tcp^{1-B} + Ctcm(exp(D*x/tcm)-1) ))
where A,C,D>0 and B>=1 are constants.

My simplified MATLAB code is as follows:

cvx_begin gp
    variables x(U,K) tcp(U,K) tcm(U,K)  z(U,K)
    for i=1:1:U
        for j=1:1:K
            xPower(i,j)=pow_p(x(i,j), B);
            tcpPower(i,j)=pow_p(tcp(i,j), 1-B);
        end
    end
    enerComp = A .* xPower.*tcpPower;
    enerComm = C .* z;
    obj=sum(sum(enerComp + enerComm));
    minimize obj
    subject to
        for i=1:U
            for j=1:K
                {tcm(i,j), D .* x(i,j), z+1} == exponential(1)
            end
        end
cvx_end

However, the following error message keeps coming up…

Error using cvxprob/newcnstr (line 192)
Disciplined convex programming error:
   Invalid constraint: {log-affine} == {real affine}

Error in cvxprob/newcnstr (line 72)
            newcnstr( prob, x{k}, y{k}, op );

Error in  ==  (line 3)
b = newcnstr( evalin( 'caller', 'cvx_problem', '[]' ), x, y, '==' );

Error in test (line 26)
                {tcm(i,j), D .* x(i,j), z+1} == exponential(1)

Can I use CVX to solve this problem without any error?

I am sure that the objective function is convex function, since it is summation of two convex functions which are perspective functions.

I haven’t looked very closely at what you’re trying to do,. But take a look at Perspective of log det function, and CVX formulations of related log det problems using Quantum Relative Entropy from CVXQUAD

Can you do what you want in a manner along those lines?

However, are you trying to raise non-square matrices to powers? I don’t see how that works unless the matrices are squares, i.e., U = K. Or are you actually trying to do element-wise powers, which is a very different thing, for which matrix functions are not applicable?

In any event, if you are actually looking at matrix (not element-wise) powers, look at the functions (and sets) listed at https://github.com/hfawzi/cvxquad ., which are available in CVX by installing CVXQUAD (you don’t need to install its exponential.m replacement to use the matrix functions). For instance, trace_mpower(X,t,C) = trace(C*X^t),
concave in X for t in [0,1]
convex in X for t in [-1,0] or [1,2]
(C fixed positive semidefinite matrix)`