Reverting likely erroneous changes to the matrix arithmetic