# Gaussian Elimination

### From Conservapedia

Gaussian Elimination is a simple method for solving a system of simultaneous linear equations by expressing them in matrix form and then subtracting rows from each other sequentially in order to create all ones on the main diagonal and all zeros below the diagonal, thereby facilitating identification of solutions or range of solutions.

The three types of elementary row operations used are:

• swap rows
• multiple a row by a constant
• add or subtract rows from each other

## Example

Here, we work a simple example. Consider the two equations:

$3x-2y=7 \$

$x+\frac{y}{2} = -2 \$.

We represent this collection of equations in matrix form as:

$\begin{pmatrix}3 & -2 & 7\\1 & 1/2 & -2\end{pmatrix}$.

Now, the technique of Gaussian elimination allows us to add and subtract rows from each other, as well as multiples of rows. The idea is to achieve 1s in the main diagonal, and 0s elsewhere. This will become clear as we work the example.

Since the row $\begin{pmatrix}4 & 2 & -8 \end{pmatrix}$ is a multiple of the second row ( $4*\begin{pmatrix}1 & 1/2 & -2 \end{pmatrix}$), we can add this row to the first row:

$\begin{pmatrix}3 & -2 & 7\\1 & 1/2 & -2\end{pmatrix} \to \begin{pmatrix}3+4 & -2+2 & 7-8\\1 & 1/2 & -2\end{pmatrix}=\begin{pmatrix}7 & 0 & -1\\1 & 1/2 & -2\end{pmatrix}$

As you can see, we have already begun altering the matrix so that there will be 0s off of the main diagonal. In our next step, we will divide the top row by 7 and multiply the bottom row by 2 to put 1s in the main diagonal:

$\begin{pmatrix}7 & 0 & -1\\1 & 1/2 & -2\end{pmatrix} \to \begin{pmatrix}1 & 0 & -1/7\\2 & 1 & -4\end{pmatrix}$

Finally, we subtract twice the top row from the bottom to put a zero off the main diagonal in the bottom:

$\begin{pmatrix}1 & 0 & -1/7\\2 & 1 & -4\end{pmatrix} \to \begin{pmatrix}1 & 0 & -1/7\\0 & 1 & -4+2/7\end{pmatrix}=\begin{pmatrix}1 & 0 & -1/7\\0 & 1 & -26/7\end{pmatrix}$

This should yield a solution to the original equation: $x=-1/7, y=-26/7 \$. To check, we insert these values into the original equations:

$3\frac{-1}{7} - 2\frac{-26}{7} = \frac{-3+52}{7} = \frac{49}{7} = 7$

$\frac{-1}{7} + \frac{1}{2}{-26}{7} = \frac{-1-13}{7} = \frac{-14}{7} = -2$

as expected.
{"extraction_info": {"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 11, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0}, "config": {"markdown_headings": true, "markdown_code": true, "boilerplate_config": {"ratio_threshold": 0.18, "absolute_threshold": 10, "end_threshold": 15, "enable": true}, "remove_buttons": true, "remove_image_figures": true, "remove_link_clusters": true, "table_config": {"min_rows": 2, "min_cols": 3, "format": "github"}, "remove_chinese": true, "remove_edit_buttons": true, "extract_latex": true}, "english_confidence": 0.8926413059234619, "perplexity_flag": "head"}