### 15.7.7 Solving a linear system using the Jacobi method

The jacobi_linsolve command finds the solution of a linear system of equations using the Jacobi iterative method.

- jacobi_linsolve command takes two mandatory arguments and two optional arguments:
  - A, the matrix of coefficients of a system.
  - b, the right hand side of the system as a list.
  - Optionally, m, an integer indicating the maximum number of iterations (by default m=maxiter, see Section 2.5.7, item 2.5.7).
  - Optionally, ε, a positive number indicating the error tolerance (by default ε=epsilon, see Section 2.5.7, item 2.5.7).
  jacobi_linsolve(A,b ⟨,m,ε⟩) returns the solution of the system.

#### Examples

A:=[[100,2],[2,100]]:; jacobi_linsolve(A,[0,1],1 e-12);

| ⎡ ⎣ | −0.000200080032,0.0100040016006 | ⎤ ⎦

evalf(linsolve(A,[0,1]))

| ⎡ ⎣ | −0.000200080032013,0.0100040016006 | ⎤ ⎦