Solution (source code)

= Solution

Write
$$
A=D+L+U,
$$
where $D=\operatorname{diag}(a_1,\ldots,a_n)$ and $L,U$ are the strict lower and upper triangular parts. The <Jacobi method> is
$$
x^{(k+1)}=D^{-1}\left(b-(L+U)x^{(k)}\right),
$$
with iteration matrix
$$
H=-D^{-1}(L+U).
$$

Here $A$ is symmetric, so $U=L^T$. Regard the iteration as the splitting
$$
A=M-N,
\qquad
M=D,
\qquad
N=-(L+L^T).
$$
Let
$$
S=\operatorname{diag}(1,-1,1,-1,\ldots).
$$
Because $A$ is tridiagonal, changing alternating signs reverses the sign of every off-diagonal entry while preserving every diagonal entry. Therefore
$$
M^T+N=D-L-L^T=SAS.
$$
Since $S^T=S=S^{-1}$ and $A$ is positive definite, $SAS$ is positive definite. The <Householder-John theorem> now gives
$$
\rho(H)<1.
$$
The Jacobi iterates therefore converge to the unique solution $A^{-1}b$ for every starting vector, which is the <jacobi convergence for a symmetric positive-definite tridiagonal matrix>.