# A Strange result about log_det which need to be explained

I have an optimization problem about log_det and I used cvx to solved it. The cvx code is shown below:

``````cvx_begin
variable  MM(resolution_tran,resolution_tran) diagonal
minimize -log_det(eye(Nr)+snr/min(Nt,Nr)*AR_v*H_VCR*MM*H_VCR'*AR_v');
%maximize -quantum_rel_entr(eye(size(eye(Nr)+snr/min(Nt,Nr)*AR_v*H_VCR*MM*H_VCR'*AR_v')),eye(Nr)+snr/min(Nt,Nr)*AR_v*H_VCR*MM*H_VCR'*AR_v');
subject to
MM>=0;
bs(trace(AR_v*H_VCR*MM*H_VCR'*AR_v'))<=Nt*Nr;
cvx_end
``````

But there is a strange result. When the snr is 2dB-13dB, the cvx will be failed and give me a wrong answer. But when the snr becomes higher the answer is right. And the answer when snr is 0dB is better than that is 2dB-13dB. I don’t know the reson. It will be kind if someone can help me.

And there is no help to use cvxQUAD.

Show is the solver and CVX output. If the solver fails (due to numerical reasons), the objective value and all variable values are meaningless.

Perhaps your problem has poorly scaled (very small or large magnitude) input data?

It appears the code with `quantum_rel_entr` is commented out. Did you actually use it?

All the help for CVXQUAD is at

and
CVXQUAD: How to use CVXQUAD's Pade Approximant instead of CVX's unreliable Successive Approximation for GP mode, log, exp, entr, rel_entr, kl_div, log_det, det_rootn, exponential cone. CVXQUAD's Quantum (Matrix) Entropy & Matrix Log related functions .

As fort how changing the value of `snr` should affect the optimal objective value, it’s your model (or wherever you got it from), not ours, so you should be the expert on that, not us. We don’t know what 'should" happen.

Thank you so much for your advice!