Number of electrons in the original density matrix gets computed correctly.