Gauss Seidel 228C45
1. **Problem statement:** Solve the system of equations using the Gauss-Seidel iteration method:
$$\begin{cases} 20x + y - 2z = 17 \\ 3x + 20y - z = -18 \\ 2x - 3y + 20z = 25 \end{cases}$$
2. **Gauss-Seidel method formula:**
For each variable, isolate it in its equation:
$$x = \frac{17 - y + 2z}{20}$$
$$y = \frac{-18 - 3x + z}{20}$$
$$z = \frac{25 - 2x + 3y}{20}$$
3. **Initial guess:** Start with $x^{(0)}=0$, $y^{(0)}=0$, $z^{(0)}=0$.
4. **Iteration 1:**
$$x^{(1)} = \frac{17 - 0 + 0}{20} = 0.85$$
$$y^{(1)} = \frac{-18 - 3(0.85) + 0}{20} = \frac{-18 - 2.55}{20} = -1.0275$$
$$z^{(1)} = \frac{25 - 2(0.85) + 3(-1.0275)}{20} = \frac{25 - 1.7 - 3.0825}{20} = 1.109125$$
5. **Iteration 2:**
$$x^{(2)} = \frac{17 - (-1.0275) + 2(1.109125)}{20} = \frac{17 + 1.0275 + 2.21825}{20} = 1.5122875$$
$$y^{(2)} = \frac{-18 - 3(1.5122875) + 1.109125}{20} = \frac{-18 - 4.5368625 + 1.109125}{20} = -1.71336875$$
$$z^{(2)} = \frac{25 - 2(1.5122875) + 3(-1.71336875)}{20} = \frac{25 - 3.024575 - 5.14010625}{20} = 0.917659375$$
6. **Iteration 3:**
$$x^{(3)} = \frac{17 - (-1.71336875) + 2(0.917659375)}{20} = \frac{17 + 1.71336875 + 1.83531875}{20} = 1.5253528125$$
$$y^{(3)} = \frac{-18 - 3(1.5253528125) + 0.917659375}{20} = \frac{-18 - 4.5760584375 + 0.917659375}{20} = -1.82919953125$$
$$z^{(3)} = \frac{25 - 2(1.5253528125) + 3(-1.82919953125)}{20} = \frac{25 - 3.050705625 - 5.48759859375}{20} = 0.731847890625$$
7. **Continue iterations** until values converge to desired accuracy.
**Final approximate solution after 3 iterations:**
$$x \approx 1.5254, \quad y \approx -1.8292, \quad z \approx 0.7318$$