Solves a matrix using Gauss-Seidel Method