How to find solution of linear system?

1.2k Views Asked by At

I have to solve a linear system of three equations and 3 unknowns and can't find a way to solve it. Applying Cramer's rule I obtain $\Delta = 0$, $\Delta_x \neq 0$, $\Delta_y \neq 0$, $\Delta_z \neq 0$ so that may exist a solution. How to deal with the system in such a situation?

2

There are 2 best solutions below

2
On BEST ANSWER

Just solve it directly by applying Gauss algorithm.

Assume your equation system is of the form $\begin{bmatrix}a_{11}&a_{12}&a_{13}\\a_{21} & a_{22} & a_{23}\\ a_{31} & a_{32} & a_{33}\end{bmatrix} \begin{bmatrix} x\\y\\z\end{bmatrix} = \begin{bmatrix}b_1\\b_2\\b_3\end{bmatrix}$ then you can solve it as follows:

First make sure that $a_{11}\not=0$, otherwise you can change 2 rows / columns s.t. the new matrix has the first entry not equal to $0$.

Then you subtract the first row multiplicated with $-\frac{a_{21}}{a_{11}}$ from the second. This makes, that the resulting system looks something like this

$\begin{bmatrix}a_{11}&a_{12}&a_{13}\\0 & \tilde{a}_{22} & \tilde{a}_{23}\\ a_{31} & a_{32} & a_{33}\end{bmatrix} \begin{bmatrix} x\\y\\z\end{bmatrix} = \begin{bmatrix}b_1\\\tilde{b}_2\\b_3\end{bmatrix}$

NOTE that for example $\tilde{a}_{22} = a_{22} - \frac{a_{21}}{a_{11}}$

Now repeat: Add the first row multiplicated with $\frac{-a_{31}}{a_{11}}$ to the third row. This makes your system

$\begin{bmatrix}a_{11}&a_{12}&a_{13}\\0 & \tilde{a}_{22} & \tilde{a}_{23}\\ 0 & \tilde{a}_{32} & \tilde{a}_{33}\end{bmatrix} \begin{bmatrix} x\\y\\z\end{bmatrix} = \begin{bmatrix}b_1\\\tilde{b}_2\\\tilde{b}_3\end{bmatrix}$

Note again, that the entries in the third row of the system have changed, so they have a tilde above them now.

Now you need one more step. Make sure, that $\tilde{a}_{22}\not=0$ (if not, change the 2nd and the 3rd row or column in your system to make this the case). Now subtract the second row (with $\tilde{a}_{22}\not=0$) multiplicated with $\frac{-\tilde{a}_{33}}{\tilde{a}_{22}}$ from the third row. This makes your system look like

$\begin{bmatrix}a_{11}&a_{12}&a_{13}\\ 0 & \tilde{a}_{22} & \tilde{a}_{23}\\ 0 & 0 & \bar{a}_{33}\end{bmatrix} \begin{bmatrix} x\\y\\z\end{bmatrix} = \begin{bmatrix}b_1\\ \tilde{b}_2\\\bar{b}_3\end{bmatrix}$

Note, that in the third row again something has changed. The modified elements have a bar above them.

Now you can see that $ \bar{a}_{33} \cdot z = b_3$, so $z = \frac{\bar{b}_3}{\bar{a}_{33}}$.

Inserting this value for $z$ in the second equation, you get the value of $y$.

Afterwards insert the values of $z$ and $y$ into the first equation, to get a value for $x$.

The vector $\begin{bmatrix}x\\y\\z\end{bmatrix}$ is then a solution to the system.

REMARK:

If at one point during calculation you get to the equation $0 = 0$, this means that you can chose a variable (e.g. z) as you wish. As you're normally interested in ALL solutions of the system, not just a particular one, you should call it $t$. This parameter $t$ is no variable anymore, so you can bring it to the right side of your system and calculate the values for the remaining variables with respect to this parameter $t$.

If at one point during calculation you get a wrong equation, e.g. $1=0$, you either did some mistake or the system has no solution!

Good luck :-)

0
On

Here are hints:

This kind of systems may have infinitely many solutions or no solution. Change system into row echelon form. Separate pivot variables and free variables. express pivot variables in terms of free variables.