Numpy Function To Solve Linear Equations