3
$\begingroup$

Is the function $\mbox{tr}(XAX')$ convex, where $A$ is a positive semidefinite (PSD) matrix? I know that for a general $A$, the above trace function is not convex. But for a PSD $A$, is the function convex?

$\endgroup$
  • $\begingroup$ Think about operations which preserve convexity ! $\endgroup$ – Red shoes May 28 '17 at 18:06
4
$\begingroup$

Look at the table for scalar-by-matrix derivatives. In particular, one has

$$\nabla_X \text{tr}(XAX^T) = X^T(A+A^T).$$

Thus if $A$ is psd, then so is the Hessian $A + A^T = 2A$, from which convexity of $X \mapsto \text{tr}(XAX^T)$ follows.

$\endgroup$
2
$\begingroup$

If $\rm A$ is symmetric and positive semidefinite, then there is a matrix $\rm M$ such that $\rm A = M M^{\top}$. Hence,

$$\mbox{tr} \left( \mathrm X \mathrm A \mathrm X^{\top} \right) = \mbox{tr} \left( \mathrm X \mathrm M \mathrm M^{\top} \mathrm X^{\top} \right) = \| \mathrm X \mathrm M \|_{\text{F}}^2$$

is indeed convex.

$\endgroup$
0
$\begingroup$

Let $\mathrm X \in \mathbb R^{m \times n}$. Hence,

$$\mbox{tr} \left( \mathrm X \mathrm A \mathrm X^{\top} \right) = (\mbox{vec} (\mathrm X))^{\top} \left( \mathrm A \otimes \mathrm I_m \right) \mbox{vec} (\mathrm X)$$

If $\rm A$ is symmetric and positive semidefinite, then the Kronecker product $\mathrm A \otimes \mathrm I_m$ is also symmetric and positive semidefinite and, thus, $\mbox{tr} \left( \mathrm X \mathrm A \mathrm X^{\top} \right)$ is convex.

$\endgroup$
0
$\begingroup$

You can easily see that the function $\varphi: \mathbb R^{n^2}\to \mathbb R$ such that $\varphi(X)=\text{tr}(XAX^T)$ is the trace of the matrix whose entries are the scalar products of a set $ (x_i)_{i=1,\ldots,n}$ of vectors in $\mathbb R^n$. Call their components $(x_i^j)_{j=1,\ldots,n}$ for every $i$.

The elements on the diagonal of your matrix are $$(XAX^T)_{ii}= (X^TAX)_{ii}=x_i^TAx_i=\sum_{j,k=1}^n x_i^ja_{jk}x_i^k$$ so the trace is equal to $$\sum_{i,j,k=1}^n x_i^ja_{jk}x_i^k=\sum_{i=1}^n(x_i,x_i)_A=\sum_{i=1}^n x_i^T A x_i$$

This makes $$\frac{\partial^2}{\partial (x^a_b)^2}\varphi=2a_{aa}$$ $$\frac{\partial^2}{\partial (x^a_b)\partial (x^c_d)}\varphi=a_{ac}+a_{ca}$$ so your Hessian is $$H_\varphi=A+A^T$$ Since $A$ is psd, if $y\neq 0$ $$y^T(A+A^T)y=y^T A y+ (y^TAy)^T=2y^TAy\ge 0$$ and $\varphi$ is convex, because $H_\varphi$ is positive semidefinite.

$\endgroup$
0
$\begingroup$

The function $tr : M_n(R) \rightarrow R$ is linear (so convex) and increasing w.r.t Positive matrix cones. And the function $Q:M_n(R) \rightarrow M_n(R) $ with $Q(X)=X A X^t$ is convex w.r.t positive cones (i.e., each row of $XAX^t$ is convex function), since $A$ is PSD (look at it Hessian of each rows ), Therefore, $F=tr oQ :M_n(R) \rightarrow R $ with $F= tr(XAX^t)$ is convex.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.