Uniqueness of simultaneous diagonalization via congruence

diagonalizationlinear algebramatrices

My question is about the uniqueness of simultaneous diagonalization via congruence: I have two symmetric matrices A and B of dimension d. One of them (say A) is positive-definite, the other one (B) is positive semi-definite and has rank $k<d$. Say we want to diagonalize A and B simultaneously via congruence, i.e. we want to find a regular matrix $C$ of dimension $d$ such that $$ C^TAC=I_d \quad\text{and}\quad C^TBC=D$$
where $I_d$ is the $d$-dimensional identity matrix and $D$ is some diagonal matrix. There are at least two solutions:

  1. Since A is positive-definite, we can compute the inverse of its square root $A^{-1/2}$. Then $M_1:=A^{-1/2}BA^{-1/2}$ is symmetric and has eigendecomposition $Q_1\Lambda_1 Q_1^T$. Taking $C_1:=A^{-1/2}Q_1$ does the job since: $$C_1^TAC_1=Q_1^TA^{-1/2}AA^{-1/2}Q_1=Q_1^TQ_1=I_d\quad \text{and}\quad C_1^TBC_1=Q_1^TA^{-1/2}BA^{-1/2}Q_1=Q_1^TM_1Q_1=\Lambda_1.$$
  2. Another solution is to use the inverse of the Cholesky factor of $A$ instead of the inverse of its square root: Let $A=R^TR$ the Cholesky decomposition of $A$ where $R$ is upper triangular. Then perform the spectral decomposition of $M_2:=R^{-T}BR^{-1}$ to obtain $Q_2\Lambda_2Q_2^T$ and define $C_2:=R^{-1}Q_2$. The matrix $C_2$ does the job as well since:
    $$ C_2^TAC_2=Q_2^TR^{-T}R^TRR^{-1}Q_2=Q_2^TQ_2=I_d\quad\text{and}\quad C_2^TBC_2=Q_2^TR^{-T}BR^{-1}Q_2=Q_2^TM_2Q_2=\Lambda_2.$$

I have implemented both procedures and observe that the diagonal matrices $\Lambda_1$ and $\Lambda_2$ coincide exactly. Furthermore, I observe that the first $k=rank(B)$ columns of the two transformation matrices $C_1$ and $C_2$ coincide (up to orientation, i.e. up to multiplication with -1). My question is whether there are any uniqueness statements in this context. Is the resulting diagonal matrix $D$ unique? Are the first $k=rank(B)$ columns of $C$ unique? Or may there be further matrices $C$ that diagonalize both $A$ and $B$ in the above sense but where the first $k$ columns will not coincide with those of $C_1$ and $C_2$? If the transformation matrix $C$ is unique (or its first $k$ columns), how can one prove that?

Best Answer

Let $Q=A^{1/2}C$. The conditions $C^TAC=I$ and $C^TBC=D$ are then equivalent to $Q^TQ=I$ and $Q^T(A^{-1/2}BA^{-1/2})Q=D$. Therefore, the apparent simultaneous diagonalisation of two matrices by congruence is just the usual orthogonal diagonalisation of a single real symmetric matrix $S=A^{-1/2}BA^{-1/2}$.

Since the diagonal entries of $D$ are the eigenvalues of $S$, they are unique up to permutation. Since the columns of $Q$ are mutually orthonormal eigenvectors of $S$, they are also unique (up to permutation and multiplications by $\pm1$) when $S$ has distinct eigenvalues. In this case, as $C=A^{-1/2}Q$, the columns of $C$ are also unique (up to permutation and multiplications by $\pm1$).

$C$ is not unique in general if $S$ has repeated eigenvalues. An obvious counterexample is the case where $A=I$ and $B=0$. Every orthogonal matrix $C$ will diagonalise $A$ and $B$ by congruence.

Related Question