Added missing matrix inversion.