Search for a tool
Gaussian Elimination

Tool to apply the gaussian elimination method and get the row reduced echelon form, with steps, details, inverse matrix and vector solution.

Results

Gaussian Elimination -

Tag(s) : Matrix, Symbolic Computation

Share
dCode and more

dCode is free and its tools are a valuable help in games, maths, geocaching, puzzles and problems to solve every day!
A suggestion ? a feedback ? a bug ? an idea ? Write to dCode!

Please, check our dCode Discord community for help requests!
NB: for encrypted messages, test our automatic cipher identifier!

Feedback and suggestions are welcome so that dCode offers the best 'Gaussian Elimination' tool for free! Thank you!

# Gaussian Elimination

## Gaussian Elimination Calculator

 Display Detailed Calculation Steps Only solution vector

## Equation System to Matrix Converter

### What is the Gaussian Elimination method?

The Gaussian elimination algorithm (also called Gauss-Jordan, or pivot method) makes it possible to find the solutions of a system of linear equations, and to determine the inverse of a matrix.

The algorithm works on the rows of the matrix, by exchanging or multiplying the rows between them (up to a factor).

At each step, the algorithm aims to introduce into the matrix, on the elements outside the diagonal, zero values.

### How to calculate the solutions of a linear equation system with Gauss?

From a system of linear equations, the first step is to convert the equations into a matrix.

Example: $$\left\{ \begin{array}{} x&-&y&+&2z&=&5\\3x&+&2y&+&z&=&10\\2x&-&3y&-&2z&=&-10\\\end{array} \right.$$ can be written under multiplication">matrix multiplication form: $$\left( \begin{array}{ccc} 1 & -1 & 2 \\ 3 & 2 & 1 \\ 2 & -3 & -2 \end{array} \right) . \left( \begin{array}{c} x \\ y \\ z \end{array} \right) = \left( \begin{array}{c} 5 \\ 10 \\ -10 \end{array} \right)$$ that corresponds to the (augmented) matrix $$\left( \begin{array}{ccc|c} 1 & -1 & 2 & 5 \\ 3 & 2 & 1 & 10 \\ 2 & -3 & -2 & -10 \end{array} \right)$$

Then, for each element outside the non-zero diagonal, perform an adequate calculation by adding or subtracting the other lines so that the element becomes 0.

Example: Subtract 3 times (Row 1) to (Row 2) such as the element in row 2, column 1 becomes 0: $$\left( \begin{array}{ccc|c} 1 & -1 & 2 & 5 \\ 0 & 5 & -5 & -5 \\ 2 & -3 & -2 & -10 \end{array} \right)$$
Subtract 2 times (Row 1) to (Row 3) such as the element in row 3, column 1 becomes 0: $$\left( \begin{array}{ccc|c} 1 & -1 & 2 & 5 \\ 0 & 5 & -5 & -5 \\ 0 & -1 & -6 & -20 \end{array} \right)$$
Subtract 1/5 times (Row 2) to (Row 3) such as the element in row 3, column 2 becomes 0: $$\left( \begin{array}{ccc|c} 1 & -1 & 2 & 5 \\ 0 & 5 & -5 & -5 \\ 0 & 0 & -7 & -21 \end{array} \right)$$
Subtract 1/5 times (Row 2) to (Row 1) such as the element in row 1, column 2 becomes 0: $$\left( \begin{array}{ccc|c} 1 & 0 & 1 & 4 \\ 0 & 5 & -5 & -5 \\ 0 & 0 & -7 & -21 \end{array} \right)$$
Subtract 1/7 times (Row 3) to (Row 1) such as the element in row 1, column 3 becomes 0: $$\left( \begin{array}{ccc|c} 1 & 0 & 0 & 1 \\ 0 & 5 & -5 & -5 \\ 0 & 0 & -7 & -21 \end{array} \right)$$
Subtract 5/7 times (Row 3) to (Row 2) such as the element in row 2, column 3 becomes 0: $$\left( \begin{array}{ccc|c} 1 & 0 & 0 & 1 \\ 0 & 5 & 0 & 10 \\ 0 & 0 & -7 & -21 \end{array} \right)$$

Simplify each line by dividing the value on the diagonal

Example: $$\left( \begin{array}{ccc|c} 1 & 0 & 0 & 1 \\ 0 & 1 & 0 & 2 \\ 0 & 0 & 1 & 3 \end{array} \right)$$

The result vector is the last column.

Example: ${1,2,3}$ that corresponds to ${x,y,z}$ so $x=1, y=2, z=3$

## Source code

dCode retains ownership of the "Gaussian Elimination" source code. Except explicit open source licence (indicated Creative Commons / free), the "Gaussian Elimination" algorithm, the applet or snippet (converter, solver, encryption / decryption, encoding / decoding, ciphering / deciphering, breaker, translator), or the "Gaussian Elimination" functions (calculate, convert, solve, decrypt / encrypt, decipher / cipher, decode / encode, translate) written in any informatic language (Python, Java, PHP, C#, Javascript, Matlab, etc.) and all data download, script, or API access for "Gaussian Elimination" are not public, same for offline use on PC, mobile, tablet, iPhone or Android app!
Reminder : dCode is free to use.

## Cite dCode

The copy-paste of the page "Gaussian Elimination" or any of its results, is allowed (even for commercial purposes) as long as you cite dCode!
Exporting results as a .csv or .txt file is free by clicking on the export icon
Cite as source (bibliography):
Gaussian Elimination on dCode.fr [online website], retrieved on 2023-12-05, https://www.dcode.fr/gaussian-elimination

## Need Help ?

Please, check our dCode Discord community for help requests!
NB: for encrypted messages, test our automatic cipher identifier!