Fixed out of bounds error in SVD implementation