Methods for Solving Linear Algebraic Equations: Which One Is Best?

Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
2 replies · 2K views
eddysd
Messages
39
Reaction score
0
For the system of linear algebraic equations:
x − y = 1
2x + 3y = 7
a) find solution by the Cramer’s rule;
b) find solution by the method of Gaussian elimination;
c) write the first iteration of the Jacobi method with the initial guess x^0=y^0=1.

I understand Cramer's Rule, and I think I understand Gaussian elimination, have got
x=2 and y=1 for both of them, but I have no idea how to do part c). Can anyone help me?
 
Physics news on Phys.org
In terms of matrices, this system would be written as
[tex]\begin{bmatrix}1 & -1 \\ 2 & 3\end{bmatrix}\begin{bmatrix}x \\ y\end{bmatrix}= \begin{bmatrix}1 \\ 7\end{bmatrix}[/tex]

We can take out the "diagonal" and rewrite it as
[tex]\begin{bmatrix}1 & 0 \\ 0 & 3\end{bmatrix}\begin{bmatrix}x \\ y\end{bmatrix}i+ \begin{bmatrix}0 & -1 \\2 & 0\end{bmatrix}\begin{bmatrix}x \\ y \end{bmatrix}= \begin{bmatrix}1 \\ 7\end{bmatrix}[/tex]

so that
[tex]\begin{bmatrix}1 & 0 \\ 0 & 3\end{bmatrix}\begin{bmatrix}x \\ y\end{bmatrix} = \begin{bmatrix}1 \\ 7\end{bmatrix}- \begin{bmatrix}0 & -1 \\2 & 0\end{bmatrix}\begin{bmatrix}x \\ y \end{bmatrix}[/tex]

or, just in terms of the equations, x= 1+ y, 3y= 7- 2x so we have x= 1+ y, y= (7- 2x)/3.

Taking [itex]x^0= y^0= 1[/itex], we have [itex]x^1= 1+ y^0= 1+ 1= 2[/itex] and [itex]y^1= (7- 2x^0)/3= (7- 2)/3= 5/3[/itex].
 
Thank you, very helpful! :biggrin: