What does the atm matrix look like? Transposing a matrix in Microsoft Excel

What does the atm matrix look like? Transposing a matrix in Microsoft Excel

12.12.2022

Transposing a matrix through this online calculator will not take you much time, but it will quickly give results and help you better understand the process itself.

Sometimes in algebraic calculations there is a need to swap the rows and columns of a matrix. This operation is called matrix transposition. The rows in order become columns, and the matrix itself becomes transposed. There are certain rules in these calculations, and to understand them and visually familiarize yourself with the process, use this online calculator. It will make your task much easier and help you better understand the theory of matrix transposition. A significant advantage of this calculator is the demonstration of an expanded and detailed solution. Thus, its use promotes a deeper and more informed understanding of algebraic calculations. In addition, with its help you can always check how successfully you completed the task by transposing the matrices manually.

The calculator is very easy to use. To find a transposed matrix online, specify the matrix size by clicking on the “+” or “-” icons until you get required values number of columns and rows. Next, enter the required numbers into the fields. Below is the “Calculate” button - clicking it displays a ready-made solution with a detailed explanation of the algorithm.

Matrix A -1 is called the inverse matrix with respect to matrix A if A*A -1 = E, where E is the identity matrix of the nth order. An inverse matrix can only exist for square matrices.

Purpose of the service. By using of this service V online mode can be found algebraic additions, transposed matrix A T , allied matrix and inverse matrix. The decision is carried out directly on the website (online) and is free. The calculation results are presented in a report in Word format and in Excel format(i.e. it is possible to check the solution). cm. design example.

Instructions. To obtain a solution, it is necessary to specify the dimension of the matrix. Next, fill out matrix A in the new dialog box.

see also Inverse matrix using the Jordano-Gauss method

Algorithm for finding the inverse matrix

  1. Finding the transposed matrix A T .
  2. Definition of algebraic complements. Replace each element of the matrix with its algebraic complement.
  3. Compiling an inverse matrix from algebraic additions: each element of the resulting matrix is ​​divided by the determinant of the original matrix. The resulting matrix is ​​the inverse of the original matrix.
Next algorithm for finding the inverse matrix similar to the previous one with the exception of some steps: first calculate algebraic additions, and then the union matrix C is determined.
  1. Determine whether the matrix is ​​square. If not, then there is no inverse matrix for it.
  2. Calculation of the determinant of a matrix A. If it is not equal to zero, we continue the solution, otherwise the inverse matrix does not exist.
  3. Definition of algebraic complements.
  4. Filling out the union (mutual, adjoint) matrix C .
  5. Compiling an inverse matrix from algebraic additions: each element of the adjoint matrix C is divided by the determinant of the original matrix. The resulting matrix is ​​the inverse of the original matrix.
  6. They do a check: they multiply the original and the resulting matrices. The result should be an identity matrix.

Example No. 1. Let's write the matrix in the form:

Algebraic additions. ∆ 1.2 = -(2·4-(-2·(-2))) = -4 ∆ 2.1 = -(2 4-5 3) = 7 ∆ 2.3 = -(-1 5-(-2 2)) = 1 ∆ 3.2 = -(-1·(-2)-2·3) = 4
A -1 =
0,6 -0,4 0,8
0,7 0,2 0,1
-0,1 0,4 -0,3

Another algorithm for finding the inverse matrix

Let us present another scheme for finding the inverse matrix.
  1. Find the determinant of a given square matrix A.
  2. We find algebraic complements to all elements of the matrix A.
  3. We write algebraic additions of row elements to columns (transposition).
  4. We divide each element of the resulting matrix by the determinant of the matrix A.
As we can see, the transposition operation can be applied both at the beginning, on the original matrix, and at the end, on the resulting algebraic additions.

A special case: The inverse of the identity matrix E is the identity matrix E.

When working with matrices, sometimes you need to transpose them, that is, saying in simple words, turn over. Of course, you can enter the data manually, but Excel offers several ways to do this easier and faster. Let's look at them in detail.

Matrix transposition is the process of swapping columns and rows. IN Excel program There are two possibilities for performing transposition: using the function TRANSSP and using the insert special tool. Let's look at each of these options in more detail.

Method 1: TRANSPOSE operator

Function TRANSSP belongs to the category of operators "Links and Arrays". The peculiarity is that, like other functions that work with arrays, the output result is not the contents of the cell, but an entire data array. The syntax of the function is quite simple and looks like this:

TRANSP(array)

That is, the only argument of this operator is a reference to the array, in our case the matrix, that should be converted.

Let's see how this function can be applied using an example with a real matrix.

  1. We select an empty cell on the sheet, which we plan to make the uppermost left cell of the transformed matrix. Next, click on the icon "Insert Function", which is located near the formula bar.
  2. Launch in progress Function Wizards. Open the category in it "Links and Arrays" or "Complete alphabetical list". After finding the name "TRANSP", select it and click on the button "OK".
  3. The function arguments window opens TRANSSP. The only argument of this operator corresponds to the field "Array". You need to enter the coordinates of the matrix that needs to be turned over. To do this, place the cursor in the field and, holding down the left mouse button, select the entire range of the matrix on the sheet. After the area address is displayed in the arguments window, click on the button "OK".
  4. But, as we see, in the cell that is intended to display the result, an incorrect value is displayed in the form of an error “#VALUE!”. This is due to the way array operators work. To correct this error, select a range of cells in which the number of rows should be equal to the number of columns of the original matrix, and the number of columns should be equal to the number of rows. Such a correspondence is very important for the result to be displayed correctly. In this case, the cell containing the expression “#VALUE!” should be the top left cell of the selected array and it is from this cell that the selection procedure should begin by holding down the left mouse button. After you have made the selection, place the cursor in the formula bar immediately after the operator expression TRANSSP, which should appear in it. After this, to perform the calculation, you need to press the button Enter, as is customary in conventional formulas, and dial the combination Ctrl+Shift+Enter.
  5. After these actions, the matrix was displayed as we needed, that is, in transposed form. But there is another problem. The fact is that now the new matrix is ​​an array linked by a formula that cannot be changed. When you try to make any change to the contents of the matrix, an error will pop up. Some users are quite satisfied with this state of affairs, since they do not intend to make changes to the array, but others need a matrix with which they can fully work.

    To solve this problem, select the entire transposed range. Moving to the tab "Home" click on the icon "Copy", which is located on the ribbon in the group "Clipboard". Instead of the specified action, after selecting, you can set a standard keyboard shortcut for copying Ctrl+C.

  6. Then, without removing the selection from the transposed range, right-click on it. In the context menu in the group "Insert Options" click on the icon "Values", which looks like a pictogram depicting numbers.

    Following this, the array formula TRANSSP will be deleted, and only one values ​​will remain in the cells, which can be worked with in the same way as with the original matrix.

Method 2: Matrix Transpose Using Paste Special

Additionally, a matrix can be transposed using a single element context menu, which is called "Insert Special".


After these steps, only the transformed matrix will remain on the sheet.

With the same two methods discussed above, you can transpose not only matrices, but also full-fledged tables into Excel. The procedure will be almost identical.

So, we found out that in Excel the matrix can be transposed, that is, turned over by swapping columns and rows, in two ways. The first option involves using the function TRANSSP, and the second is Paste Special Tools. By and large, the final result obtained when using both of these methods is no different. Both methods work in almost any situation. So when choosing a conversion option, the personal preferences of a particular user come to the fore. That is, which of these methods is more convenient for you personally, use that one.

To transpose a matrix, you need to write the rows of the matrix into columns.

If , then the transposed matrix

If , then

Exercise 1. Find

  1. Determinants of square matrices.

For square matrices, a number is introduced that is called the determinant.

For second-order matrices (dimension ) the determinant is given by the formula:

For example, for a matrix its determinant is

Example . Calculate determinants of matrices.

For square matrices of the third order (dimension ) there is a “triangle” rule: in the figure, the dotted line means multiply the numbers through which the dotted line passes. The first three numbers must be added, the next three numbers must be subtracted.

Example. Calculate the determinant.

To give general definition determinant, we need to introduce the concept of minor and algebraic complement.

Minor element of the matrix is ​​called the determinant obtained by crossing out - that row and - that column.

Example. Let's find some minors of matrix A.

Algebraic complement element is called number.

This means that if the sum of the indices is even, then they are no different. If the sum of the indices is odd, then they differ only in sign.

For the previous example.

Matrix determinant is the sum of the products of the elements of a certain string

(column) to their algebraic complements. Let's consider this definition on a third-order matrix.

The first entry is called the expansion of the determinant in the first row, the second is the expansion in the second column, and the last is the expansion in the third row. In total, such expansions can be written six times.

Example. Calculate the determinant using the “triangle” rule and expanding it along the first row, then along the third column, then along the second row.

Let's expand the determinant along the first line:

Let's expand the determinant in the third column:

Let's expand the determinant along the second line:

Note that the more zeros, the simpler the calculations. For example, expanding by the first column, we get

Among the properties of determinants there is a property that allows you to receive zeros, namely:

If you add elements of another row (column) to the elements of a certain row (column), multiplied by a non-zero number, then the determinant will not change.

Let's take the same determinant and get zeros, for example, in the first line.

Determinants of higher orders are calculated in the same way.

Task 2. Calculate the fourth order determinant:

1) spreading over any row or any column

2) having previously received zeros


We get an additional zero, for example, in the second column. To do this, multiply the elements of the second line by -1 and add them to the fourth line:

  1. Solving systems of linear algebraic equations using Cramer's method.

We will show the solution of a system of linear algebraic equations using Cramer's method.

Task 2. Solve a system of equations.

We need to calculate four determinants. The first is called the main one and consists of coefficients for the unknowns:

Note that if , the system cannot be solved by Cramer's method.

The three remaining determinants are denoted by , , and are obtained by replacing the corresponding column with a column of right-hand sides.

We find. To do this, change the first column in the main determinant to a column of right-hand sides:

We find. To do this, change the second column in the main determinant to a column of right-hand sides:

We find. To do this, change the third column in the main determinant to a column of right-hand sides:

We find the solution to the system using Cramer’s formulas: , ,

Thus, the solution to the system is , ,

Let’s do a check; to do this, we’ll substitute the found solution into all the equations of the system.

  1. Solving systems of linear algebraic equations using the matrix method.

If a square matrix has a nonzero determinant, there is an inverse matrix such that . The matrix is ​​called the identity matrix and has the form

The inverse matrix is ​​found by the formula:

Example. Find the inverse of a matrix

First we calculate the determinant.

Finding algebraic complements:

We write the inverse matrix:

To check the calculations, you need to make sure that .

Let a system of linear equations be given:

Let's denote

Then the system of equations can be written in matrix form as , and hence . The resulting formula is called the matrix method of solving the system.

Task 3. Solve the system using the matrix method.

We need to write out the matrix of the system, find its inverse and then multiply it by the column of right-hand sides.

We have already found the inverse matrix in the previous example, which means we can find a solution:

  1. Solving systems of linear algebraic equations using the Gauss method.

Cramer's method and the matrix method are used only for quadratic systems (the number of equations is equal to the number of unknowns), and the determinant must not be equal to zero. If the number of equations is not equal to the number of unknowns, or the determinant of the system is zero, the Gaussian method is used. The Gaussian method can be used to solve any system.

And let's substitute it into the first equation:

Task 5. Solve a system of equations using the Gaussian method.

Based on the resulting matrix, we restore the system:

We find a solution:

© 2024 hecc.ru - Computer technology news