Sum of the largest eigenvalues (source code)

= Sum of the largest eigenvalues
{title2=$F_k(X)=\sum_{i=1}^k\lambda_i(X)$}

For a real <symmetric matrix> $X$ with <eigenvalues> $\lambda_1\geq\cdots\geq\lambda_n$, the sum of its $k$ largest <eigenvalues> is the <support function> of the <fantope>:
$$
F_k(X)=\max\{\operatorname{tr}(XY):0\preceq Y\preceq I,\ \operatorname{tr}Y=k\}.
$$
Here $\preceq$ is the <Loewner order>. In an <orthonormal eigenbasis> for $X$, the objective depends only on the diagonal entries of $Y$, which lie in the <capped simplex>. Thus the identity reduces to the <sum of the largest components> of the <eigenvalues>.