Question from Kamal about Gaussian Elimination via email

In summary, the conversation was about solving a question from a textbook using Gaussian elimination. The person was having trouble getting the correct answer of z = 2 and the conversation included a step-by-step solution using matrices and back substitution to find the correct solution of x = -14, y = -124, and z = -49.
  • #1
Prove It
Gold Member
MHB
1,465
24
HI Sir,
I was having a bit of trouble with a question from the textbook. I have tried it multiple times with different methods and keep getting a different answer. The question wants us to solve it using Gaussian elimination.

2x+y−3z=−5
x − y + 2z = 12
7x − 2y + 3z = 3

The answer for Z is meant to be 2 but i keep getting bigger numbers for Z.

Thanks, Kamal

I'm not sure where you're getting the idea that z = 2, as this is not correct.

I'm assuming this is to be done without pivoting...

Set up your augmented matrix:

$\displaystyle \begin{align*} \left[ \begin{matrix} 2 & \phantom{-}1 & -3 & -5 \\ 1 & -1 & \phantom{-}2 & 12 \\ 7 & -2 & \phantom{-} 3 & \phantom{-}3 \end{matrix} \right] \end{align*}$

As we have to use Gaussian Elimination, we will use multiples of Row 1 to eliminate the terms under the main diagonal in the first column. So apply Row 2 - 1/2 Row 1 to Row 2 and Row 3 - 7/2 Row 1 to Row 3.

$\displaystyle \begin{align*} \left[ \begin{matrix} 2 & 1 & -3 & -5 \\ 1 - 1 & -1 - \frac{1}{2} & 2 - \left( -\frac{3}{2} \right) & 12 - \left( -\frac{5}{2} \right) \\ 7 - 7 & -2 - \frac{7}{2} & 3 - \left( -\frac{21}{2} \right) & 3 - \left( -\frac{35}{2} \right) \end{matrix} \right] &= \left[ \begin{matrix} 2 & \phantom{-}1 & -3 & -5 \\ 0 & -\frac{3}{2} & \phantom{-}\frac{7}{2} & \phantom{-}\frac{29}{2} \\ 0 & -\frac{11}{2} & \phantom{-}\frac{27}{2} & \phantom{-}\frac{41}{2} \end{matrix} \right] \end{align*}$

Now we have to use multiples of Row 2 to eliminate the term under the main diagonal in the second column. So we will have to apply Row 3 - 11/3 Row 2 to Row 3.

$\displaystyle \begin{align*} \left[ \begin{matrix} 2 & \phantom{-}1 & -3 & -5 \\ 0 & -\frac{3}{2} & \phantom{-}\frac{7}{2} & \phantom{-}\frac{29}{2} \\ 0 + 0 & -\frac{11}{2} - \left( -\frac{11}{2} \right) & \frac{27}{2} - \frac{77}{6} & \frac{41}{2} - \frac{319}{6} \end{matrix} \right] &= \left[ \begin{matrix} 2 & \phantom{-}1 & -3 & -5 \\ 0 & -\frac{3}{2} & \phantom{-}\frac{7}{2} & \phantom{-}\frac{29}{2} \\ 0 & \phantom{-}0 & \phantom{-}\frac{2}{3} & -\frac{98}{3} \end{matrix} \right] \end{align*}$

From here we can see that

$\displaystyle \begin{align*} \frac{2}{3} \,z &= -\frac{98}{3} \\ z &= -49 \end{align*}$.

Back substitution yields

$\displaystyle \begin{align*} -\frac{3}{2}\,y + \frac{7}{2}\,z &= \frac{29}{2} \\ -\frac{3}{2}\,y + \frac{343}{2} &= \frac{29}{2} \\ -\frac{3}{2}\,y &= -\frac{372}{2} \\ y &= -124 \end{align*}$

Back substitution again yields

$\displaystyle \begin{align*} 2\,x - y - 3\,z &= -5 \\ 2\,x - 124 + 147 &= -5 \\ 2\,x + 23 &= -5 \\ 2\,x &= -28 \\ x &= -14 \end{align*}$

So the solution to your system is $\displaystyle \begin{align*} \left[ \begin{matrix} x \\ y \\ z \end{matrix} \right] = \left[ \begin{matrix} -14 \\ -124 \\ -49 \end{matrix} \right] \end{align*}$. Substitution into any of your original equations will verify this to be correct.
 
Mathematics news on Phys.org
  • #2
Seems the thread has lost its OP. I will therefore close it.
 
  • Like
Likes Wrichik Basu

What is Gaussian Elimination and how does it work?

Gaussian Elimination is a method used to solve systems of linear equations. It involves using elementary row operations to transform the system into an upper triangular matrix, which can then be easily solved to find the solution.

Why is Gaussian Elimination an important technique in scientific research?

Gaussian Elimination is a fundamental tool in linear algebra and is used in a wide range of scientific fields, such as physics, engineering, and computer science. It allows for efficient and accurate solving of systems of equations, which are often used to model real-world problems.

How does Gaussian Elimination compare to other methods of solving linear equations?

Compared to other methods such as Cramer's rule or matrix inversion, Gaussian Elimination is generally faster and more efficient. It also allows for easier computation with larger systems of equations.

Are there any limitations or drawbacks to using Gaussian Elimination?

One limitation of Gaussian Elimination is that it can encounter issues with round-off errors when dealing with large matrices. Additionally, it may not be suitable for solving systems of equations with complex coefficients.

Is there any software or programming languages that can perform Gaussian Elimination?

Yes, there are many software and programming options available for performing Gaussian Elimination. Some popular choices include Matlab, Python, and Mathematica. These programs often have built-in functions for solving systems of equations using Gaussian Elimination.

Similar threads

Replies
1
Views
4K
Replies
1
Views
4K
  • General Math
Replies
1
Views
4K
  • General Math
Replies
1
Views
4K
Replies
4
Views
10K
Replies
1
Views
9K
Replies
1
Views
10K
Replies
1
Views
9K
Replies
0
Views
4K
Back
Top