# Cvx for maximum likelihood estimation

Hey all,

Im a beginner of cvx.

Here is my objective function: this is in section V-D of paper

maxmimize logdet(\sum_{i=1}^m{z_ia_ia_i^T}+\Sigma^{-1})
subject to 0 \leq z_i \leq 1 and i^Tz=k

Question 1: can I use cvx to estimize z directly by just following this objection function?

Question 2: in my application m=4000 a quite large scale problem, if there is a cvx function can solve this problem much faster?

Thanks

Here’s how you might write this problem in CVX:

cvx_begin
variable z(m)
maximize(log_det(A*diag(z)*A'+Siginv))
subject to
0<=z<=1
sum(z)==k
cvx_end


I tried this with m=4000, k=3, n=10, Siginv=eye(n), and A=randn(n,m). It took less than 15 seconds to run. Your problem can be solved more efficiently by replacing the log_det with det_rootn:

cvx_begin
variable z(m)
maximize(det_rootn(A*diag(z)*A'+Siginv))
subject to
0<=z<=1
sum(z)==k
cvx_end


This takes under 5 seconds on my computer. See mcg’s post on this trick here).

Hey Bien,

How about if set n=1000,k=1200. I tried it but it said Out of memory.

My application is real a large scale problem.

Thanks