Find the value of the matrix determinant. Decomposition of determinants by elements of its series

Further properties are related to the concepts of minor and algebraic complement

Minor element is called the determinant, composed of the elements remaining after deleting the row and column, at the intersection of which this element is located. The order determinant element minor has order . We will denote it by .

Example 1 Let , Then .

This minor is obtained from A by deleting the second row and third column.

Algebraic addition element is called the corresponding minor multiplied by , i.e. , where is the number of the row and -column at the intersection of which the given element is located.

VIII.(Decomposition of the determinant over the elements of some string). The determinant is equal to the sum of the products of the elements of some row and their corresponding algebraic additions.

Example 2 Let , Then

Example 3 Let's find the matrix determinant , expanding it by the elements of the first row.

Formally, this theorem and other properties of determinants are applicable so far only for determinants of matrices not higher than the third order, since we have not considered other determinants. The following definition will extend these properties to determinants of any order.

Determinant of the matrix order is called a number calculated by successive application of the decomposition theorem and other properties of determinants.

You can check that the calculation result does not depend on the order in which the above properties are applied and for which rows and columns. The determinant can be uniquely determined using this definition.

Although this definition does not contain an explicit formula for finding the determinant, it allows you to find it by reducing to determinants of matrices of lower order. Such definitions are called recurrent.

Example 4 Calculate the determinant:

Although the decomposition theorem can be applied to any row or column of a given matrix, there will be less computation when decomposing on a column containing as many zeros as possible.

Since the matrix has no zero elements, we obtain them using the property VII. Multiply the first row consecutively by numbers and add it to the strings and get:

We expand the resulting determinant in the first column and get:

since the determinant contains two proportional columns.

Some types of matrices and their determinants

A square matrix in which zero elements are below or above the main diagonal () is called triangular.

Their schematic structure accordingly looks like: or

.

Exercise. Calculate the determinant by expanding it over the elements of some row or some column.

Solution. Let us first perform elementary transformations on the rows of the determinant by making as many zeros as possible either in a row or in a column. To do this, first we subtract nine thirds from the first line, five thirds from the second, and three thirds from the fourth, we get:

We expand the resulting determinant by the elements of the first column:

The resulting third-order determinant is also expanded by the elements of the row and column, having previously obtained zeros, for example, in the first column. To do this, we subtract two second lines from the first line, and the second from the third:

Answer.

12. Slough 3 orders

1. Rule of the triangle

Schematically, this rule can be represented as follows:

The product of elements in the first determinant that are connected by lines is taken with a plus sign; similarly, for the second determinant, the corresponding products are taken with a minus sign, i.e.

2. Sarrus rule

To the right of the determinant, the first two columns are added and the products of the elements on the main diagonal and on the diagonals parallel to it are taken with a plus sign; and the products of the elements of the secondary diagonal and the diagonals parallel to it, with a minus sign:

3. Expansion of the determinant in a row or column

The determinant is equal to the sum of the products of the elements of the row of the determinant and their algebraic complements. Usually choose the row/column in which/th there are zeros. The row or column on which the decomposition is carried out will be indicated by an arrow.

Exercise. Expanding over the first row, calculate the determinant

Solution.

Answer.

4. Bringing the determinant to a triangular form

With the help of elementary transformations over rows or columns, the determinant is reduced to a triangular form, and then its value, according to the properties of the determinant, is equal to the product of the elements on the main diagonal.

Example

Exercise. Compute determinant bringing it to a triangular shape.

Solution. First, we make zeros in the first column under the main diagonal. All transformations will be easier to perform if the element is equal to 1. To do this, we will swap the first and second columns of the determinant, which, according to the properties of the determinant, will cause it to change sign to the opposite:

Next, we get zeros in the second column in place of the elements under the main diagonal. And again, if the diagonal element is equal to , then the calculations will be simpler. To do this, we swap the second and third lines (and at the same time change to the opposite sign of the determinant):

Next, we make zeros in the second column under the main diagonal, for this we proceed as follows: we add three second rows to the third row, and two second rows to the fourth, we get:

Further, from the third row we take out (-10) as a determinant and make zeros in the third column under the main diagonal, and for this we add the third to the last row:


Formulation of the problem

The task involves familiarizing the user with the basic concepts of numerical methods, such as determinant and inverse matrix, and various ways to calculate them. In this theoretical report, in simple and accessible language, the basic concepts and definitions are first introduced, on the basis of which further research is carried out. The user may not have special knowledge in the field of numerical methods and linear algebra, but will easily be able to use the results of this work. For clarity, a program for calculating the matrix determinant by several methods, written in the C ++ programming language, is given. The program is used as a laboratory stand for creating illustrations for the report. And also a study of methods for solving systems of linear algebraic equations is being carried out. The uselessness of calculating the inverse matrix is ​​proved, so the paper provides more optimal ways to solve equations without calculating it. It is explained why there are so many different methods for calculating determinants and inverse matrices and their shortcomings are analyzed. Errors in the calculation of the determinant are also considered and the achieved accuracy is estimated. In addition to Russian terms, their English equivalents are also used in the work to understand under what names to search for numerical procedures in libraries and what their parameters mean.

Basic definitions and simple properties

Determinant

Let us introduce the definition of the determinant of a square matrix of any order. This definition will recurrent, that is, to establish what the determinant of the order matrix is, you need to already know what the determinant of the order matrix is. Note also that the determinant exists only for square matrices.

The determinant of a square matrix will be denoted by or det .

Definition 1. determinant square matrix second order number is called .

determinant square matrix of order , is called the number

where is the determinant of the order matrix obtained from the matrix by deleting the first row and the column with the number .

For clarity, we write down how you can calculate the determinant of a matrix of the fourth order:

Comment. The actual calculation of determinants for matrices above the third order based on the definition is used in exceptional cases. As a rule, the calculation is carried out according to other algorithms, which will be discussed later and which require less computational work.

Comment. In Definition 1, it would be more accurate to say that the determinant is a function defined on the set of square order matrices and taking values ​​in the set of numbers.

Comment. In the literature, instead of the term "determinant", the term "determinant" is also used, which has the same meaning. From the word "determinant" the designation det appeared.

Let us consider some properties of determinants, which we formulate in the form of assertions.

Statement 1. When transposing a matrix, the determinant does not change, that is, .

Statement 2. The determinant of the product of square matrices is equal to the product of the determinants of the factors, that is, .

Statement 3. If two rows in a matrix are swapped, then its determinant will change sign.

Statement 4. If a matrix has two identical rows, then its determinant is zero.

In the future, we will need to add strings and multiply a string by a number. We will perform these operations on rows (columns) in the same way as operations on row matrices (column matrices), that is, element by element. The result will be a row (column), which, as a rule, does not match the rows of the original matrix. In the presence of operations of adding rows (columns) and multiplying them by a number, we can also talk about linear combinations of rows (columns), that is, sums with numerical coefficients.

Statement 5. If a row of a matrix is ​​multiplied by a number, then its determinant will be multiplied by that number.

Statement 6. If the matrix contains a zero row, then its determinant is zero.

Statement 7. If one of the rows of the matrix is ​​equal to the other multiplied by a number (the rows are proportional), then the determinant of the matrix is ​​zero.

Statement 8. Let the i-th row in the matrix look like . Then , where the matrix is ​​obtained from the matrix by replacing the i-th row with the row , and the matrix is ​​obtained by replacing the i-th row with the row .

Statement 9. If one of the rows of the matrix is ​​added to another, multiplied by a number, then the determinant of the matrix will not change.

Statement 10. If one of the rows of a matrix is ​​a linear combination of its other rows, then the determinant of the matrix is ​​zero.

Definition 2. Algebraic addition to a matrix element is called a number equal to , where is the determinant of the matrix obtained from the matrix by deleting the i-th row and the j-th column. The algebraic complement to a matrix element is denoted by .

Example. Let . Then

Comment. Using algebraic additions, the definition of 1 determinant can be written as follows:

Statement 11. Decomposition of the determinant in an arbitrary string.

The matrix determinant satisfies the formula

Example. Calculate .

Solution. Let's use the expansion in the third line, it's more profitable, because in the third line two numbers out of three are zeros. Get

Statement 12. For a square matrix of order at , we have the relation .

Statement 13. All properties of the determinant formulated for rows (statements 1 - 11) are also valid for columns, in particular, the decomposition of the determinant in the j-th column is valid and equality at .

Statement 14. The determinant of a triangular matrix is ​​equal to the product of the elements of its main diagonal.

Consequence. The determinant of the identity matrix is ​​equal to one, .

Conclusion. The properties listed above make it possible to find determinants of matrices of sufficiently high orders with a relatively small amount of calculations. The calculation algorithm is the following.

Algorithm for creating zeros in a column. Let it be required to calculate the order determinant . If , then swap the first line and any other line in which the first element is not zero. As a result, the determinant , will be equal to the determinant of the new matrix with the opposite sign. If the first element of each row is equal to zero, then the matrix has a zero column and, by Statements 1, 13, its determinant is equal to zero.

So, we consider that already in the original matrix . Leave the first line unchanged. Let's add to the second line the first line, multiplied by the number . Then the first element of the second row will be equal to .

The remaining elements of the new second row will be denoted by , . The determinant of the new matrix according to Statement 9 is equal to . Multiply the first line by the number and add it to the third. The first element of the new third row will be equal to

The remaining elements of the new third row will be denoted by , . The determinant of the new matrix according to Statement 9 is equal to .

We will continue the process of obtaining zeros instead of the first elements of strings. Finally, we multiply the first line by a number and add it to the last line. The result is a matrix, denoted by , which has the form

and . To calculate the determinant of the matrix, we use the expansion in the first column

Since then

The determinant of the order matrix is ​​on the right side. We apply the same algorithm to it, and the calculation of the determinant of the matrix will be reduced to the calculation of the determinant of the order matrix. The process is repeated until we reach the second-order determinant, which is calculated by definition.

If the matrix does not have any specific properties, then it is not possible to significantly reduce the amount of calculations in comparison with the proposed algorithm. Another good side of this algorithm is that it is easy to write a program for a computer to calculate the determinants of matrices of large orders. In standard programs for calculating determinants, this algorithm is used with minor changes associated with minimizing the influence of rounding errors and input data errors in computer calculations.

Example. Compute Matrix Determinant .

Solution. The first line is left unchanged. To the second line we add the first, multiplied by the number:

The determinant does not change. To the third line we add the first, multiplied by the number:

The determinant does not change. To the fourth line we add the first, multiplied by the number:

The determinant does not change. As a result, we get

Using the same algorithm, we calculate the determinant of a matrix of order 3, which is on the right. We leave the first line unchanged, to the second line we add the first, multiplied by the number :

To the third line we add the first, multiplied by the number :

As a result, we get

Answer. .

Comment. Although fractions were used in the calculations, the result was an integer. Indeed, using the properties of determinants and the fact that the original numbers are integers, operations with fractions could be avoided. But in engineering practice, numbers are extremely rarely integers. Therefore, as a rule, the elements of the determinant will be decimal fractions and it is not advisable to use any tricks to simplify calculations.

inverse matrix

Definition 3. The matrix is ​​called inverse matrix for a square matrix if .

It follows from the definition that the inverse matrix will be a square matrix of the same order as the matrix (otherwise one of the products or would not be defined).

The inverse matrix for a matrix is ​​denoted by . Thus, if exists, then .

From the definition of an inverse matrix, it follows that the matrix is ​​the inverse of the matrix, that is, . Matrices and can be said to be inverse to each other or mutually inverse.

If the determinant of a matrix is ​​zero, then its inverse does not exist.

Since for finding the inverse matrix it is important whether the determinant of the matrix is ​​equal to zero or not, we introduce the following definitions.

Definition 4. Let's call the square matrix degenerate or special matrix, if non-degenerate or nonsingular matrix, If .

Statement. If an inverse matrix exists, then it is unique.

Statement. If a square matrix is ​​nondegenerate, then its inverse exists and (1) where are algebraic additions to elements .

Theorem. An inverse matrix for a square matrix exists if and only if the matrix is ​​nonsingular, the inverse matrix is ​​unique, and formula (1) is valid.

Comment. Particular attention should be paid to the places occupied by algebraic additions in the inverse matrix formula: the first index shows the number column, and the second is the number lines, in which the calculated algebraic complement should be written.

Example. .

Solution. Finding the determinant

Since , then the matrix is ​​nondegenerate, and the inverse for it exists. Finding algebraic additions:

We compose the inverse matrix by placing the found algebraic additions so that the first index corresponds to the column, and the second to the row: (2)

The resulting matrix (2) is the answer to the problem.

Comment. In the previous example, it would be more accurate to write the answer like this:
(3)

However, the notation (2) is more compact and it is more convenient to carry out further calculations, if any, with it. Therefore, writing the answer in the form (2) is preferable if the elements of the matrices are integers. And vice versa, if the elements of the matrix are decimal fractions, then it is better to write the inverse matrix without a factor in front.

Comment. When finding the inverse matrix, you have to perform quite a lot of calculations and an unusual rule for arranging algebraic additions in the final matrix. Therefore, there is a high chance of error. To avoid errors, you should do a check: calculate the product of the original matrix by the final one in one order or another. If the result is an identity matrix, then the inverse matrix is ​​found correctly. Otherwise, you need to look for an error.

Example. Find the inverse of a matrix .

Solution. - exists.

Answer: .

Conclusion. Finding the inverse matrix by formula (1) requires too many calculations. For matrices of the fourth order and higher, this is unacceptable. The real algorithm for finding the inverse matrix will be given later.

Calculating the determinant and inverse matrix using the Gauss method

The Gauss method can be used to find the determinant and inverse matrix.

Namely, the matrix determinant is equal to det .

The inverse matrix is ​​found by solving systems of linear equations using the Gaussian elimination method:

Where is the j-th column of the identity matrix , is the desired vector.

The resulting solution vectors - form, obviously, the columns of the matrix, since .

Formulas for the determinant

1. If the matrix is ​​nonsingular, then and (the product of the leading elements).

Recall Laplace's theorem:
Laplace's theorem:

Let k rows (or k columns) be arbitrarily chosen in the determinant d of order n, . Then the sum of the products of all k-th order minors contained in the selected rows and their algebraic complements is equal to the determinant d.

To calculate the determinants in the general case, k is taken equal to 1. That is, in the determinant d of order n, a row (or column) is arbitrarily chosen. Then the sum of the products of all elements contained in the selected row (or column) and their algebraic complements is equal to the determinant d.

Example:
Compute determinant

Solution:

Let's choose an arbitrary row or column. For a reason that will become apparent a little later, we will limit our choice to either the third row or the fourth column. And stop at the third line.

Let's use Laplace's theorem.

The first element of the selected row is 10, it is in the third row and first column. Let us calculate the algebraic complement to it, i.e. find the determinant obtained by deleting the column and row on which this element stands (10) and find out the sign.

"plus if the sum of the numbers of all rows and columns in which the minor M is located is even, and minus if this sum is odd."
And we took the minor consisting of one single element 10, which is in the first column of the third row.

So:


The fourth term of this sum is 0, which is why it is worth choosing rows or columns with the maximum number of zero elements.

Answer: -1228

Example:
Calculate the determinant:

Solution:
Let's choose the first column, because two elements in it are equal to 0. Let's expand the determinant in the first column.


We expand each of the third-order determinants in terms of the first and second rows


We expand each of the second-order determinants in the first column


Answer: 48
Comment: when solving this problem, formulas for calculating the determinants of the 2nd and 3rd orders were not used. Only expansion by row or column was used. Which leads to lowering the order of the determinants.

Matrix determinant

Finding the determinant of a matrix is ​​a very common problem in higher mathematics and algebra. As a rule, one cannot do without the value of the matrix determinant when solving complex systems of equations. Cramer's method for solving systems of equations is built on the calculation of the matrix determinant. Using the definition of a determinate, the presence and uniqueness of the solution of systems of equations are determined. Therefore, it is difficult to overestimate the importance of the ability to correctly and accurately find the determinant of a matrix in mathematics. Methods for solving determinants are theoretically quite simple, but as the size of the matrix increases, the calculations become very cumbersome and require great care and a lot of time. It is very easy to make a minor mistake or typo in such complex mathematical calculations, which will lead to an error in the final answer. Therefore, even if you find matrix determinant independently, it is important to check the result. This allows us to make our service Finding the determinant of a matrix online. Our service always gives an absolutely accurate result that does not contain any errors or typos. You can refuse independent calculations, because from the applied point of view, finding matrix determinant does not have a teaching character, but simply requires a lot of time and numerical calculations. Therefore, if in your task determination of matrix determinant are auxiliary, side calculations, use our service and find matrix determinant online!

All calculations are carried out automatically with the highest accuracy and absolutely free. We have a very convenient interface for entering matrix elements. But the main difference between our service and similar ones is the possibility of obtaining a detailed solution. Our service at calculating matrix determinant online always uses the simplest and shortest method and describes in detail each step of the transformations and simplifications. So you get not just the value of the matrix determinant, the final result, but the whole detailed solution.