We study the algorithm for finding the inverse matrix of the two main methods: the method of Gauss and using a matrix of the Union.

You will need

- - care
- - Knowledge of techniques

instructions

1

Given a matrix A certain size.

Inverse matrix and the matrix will bematrix B, which when multiplied to the original matrix A is a unit matrix obtained E. inverse matrix can be obtained only for a square matrix whose determinant is not zero. Matrix B is calculated as follows:

1. Starting with the very first item, go on line from left to right for each item mentally expunged row and column in which it is included, calculate the determinant of the remaining matrix (minor importance), and write it in a new matrix. BUT! If the original matrix of the current element we take, consistently passing over the lines, the new matrix write them in the column. That's not all.

2. Signs derived elements, starting with the first, will alternate in one - this is a rough formulation. To be precise, the sign is given by -1 degree sum of the indices of the element, ie, the sum of row and column in which it is located. In other words, the opposite sign should be changed from the elements having an odd sum of indexes.

3. put the coefficient 1 / (determinant of the original matrix A) before obtaining the inverse matrix B.

2

This is just one of the possible methods. You can also use the Gauss method. It lies in the fact that we take the initial matrix A and the identity matrix E. Applying the transformation of rows or columns (can subtract or add the corresponding columns or rows, or multiply them by the number) to them both at the same time we give A to E. Then the resulting matrix will be the second reverse, ie B.

Check the correctness of your calculation is very simple: multiply the original matrix A and its inverse matrix B. If you get the identity matrix E, then all actions are done right.