Unitary similarity (source code)

= Unitary similarity
{title2=$B=UAU^\dagger,\quad U^\dagger U=I$}

A <matrix similarity> implemented by a <unitary matrix>. It expresses the same <linear operator> in two <orthonormal bases>, preserving <eigenvalues>, <trace> and <singular values>. For a <Hermitian matrix>, the <spectral theorem> gives a diagonal representative by unitary similarity.