Updated the linear equation solver