  Ky Fan's trace minimization principle is extended along the line of the
Brockett cost function $\mathrm{trace}(DX^H AX)$ in $X$ on the Stiefel
manifold, where $D$ of an apt size is positive definite. Specifically, we
investigate $\inf_X \mathrm{trace}(DX^H AX)$ subject to $X^H BX=I_k$ or
$J_k=\mathrm{diag}(\pm 1)$. We establish conditions under which the infimum is
finite and when it is finite, analytic solutions are obtained in terms of the
eigenvalues and eigenvectors of the matrix pencil $A-\lambda B$, where $B$ is
possibly indefinite and singular, and $D$ is also possibly indefinite.
