Matrix Calculator

Result
\lambda = 1,\quad \lambda = 2,\quad \lambda = 3

3 eigenvalues.

  • Type: Eigenvalues
  • Method: Matrices
  • Characteristic polynomial: \displaystyle -\lambda^{3} + 6\lambda^{2} - 11\lambda + 6
  • Eigenvectors: \displaystyle \lambda = 1:\ \begin{bmatrix} 0 \\ 0 \\ 1 \end{bmatrix}
    \displaystyle \lambda = 2:\ \begin{bmatrix} -1 \\ 1 \\ 1 \end{bmatrix}
    \displaystyle \lambda = 3:\ \begin{bmatrix} 0 \\ 2 \\ 5 \end{bmatrix}

Step-by-step solution

The problem

A = \begin{bmatrix} 2 & 0 & 0 \\ 1 & 3 & 0 \\ 4 & 5 & 1 \end{bmatrix},\quad \text{eigenvalues of }A
1

Set up \displaystyle \det(A - \lambda I) = 0

\det(A - \lambda I) = \begin{vmatrix} 2 - \lambda & 0 & 0 \\ 1 & 3 - \lambda & 0 \\ 4 & 5 & 1 - \lambda \end{vmatrix}

An eigenvalue \displaystyle \lambda makes \displaystyle A - \lambda I singular, so its determinant is 0. Subtract \displaystyle \lambda from each diagonal entry.

2

Work out the determinant

= \left(2 - \lambda\right)\left[\left(3 - \lambda\right)\left(1 - \lambda\right) - 0 \cdot 5\right]
= -\lambda^{3} + 6\lambda^{2} - 11\lambda + 6

Expand along the first row (cofactor expansion): each entry times its \displaystyle 2 \times 2 minor (\displaystyle ad - bc), with signs \displaystyle +, -, +. Then multiply out and collect powers of \displaystyle \lambda.

3

Multiply by \displaystyle -1

\lambda^{3} - 6\lambda^{2} + 11\lambda - 6 = 0

Same roots, positive leading term.

4

Look for a rational root

1^{3} - 6 \cdot 1^{2} + 11 \cdot 1 - 6 = 1 - 6 \cdot 1 + 11 \cdot 1 - 6 = 1 - 6 + 11 - 6 = 0

By the rational-root theorem any rational root is \displaystyle \pm\frac{p}{q} with \displaystyle p a factor of the constant \displaystyle -6 and \displaystyle q a factor of the leading coefficient \displaystyle 1: \displaystyle \pm 1, \pm 2, \pm 3, \pm 6. Trying them, \displaystyle \lambda = 1 works (the value comes out as 0).

5

Divide by \displaystyle \left(\lambda - 1\right) (synthetic division)

\begin{array}{r|rrrr} 1 & 1 & -6 & 11 & -6 \\ & & 1 & -5 & 6 \\ \hline & 1 & -5 & 6 & \boxed{0} \end{array}

Bring down the first coefficient, multiply by \displaystyle 1, add to the next coefficient, and repeat. The last number is the remainder 0.

6

Write the factors

\lambda^{3} - 6\lambda^{2} + 11\lambda - 6 = \left(\lambda - 1\right)\left(\lambda^{2} - 5\lambda + 6\right)
7

Factor the trinomial

\begin{aligned} -2 \times \left(-3\right) &= 6 \\[4pt] -2 + \left(-3\right) &= -5 \end{aligned}

Find two numbers that multiply to \displaystyle c = 6 and add to \displaystyle b = -5: they are \displaystyle -2 and \displaystyle -3.

8

Write the two brackets

\lambda^{2} - 5\lambda + 6 = \left(\lambda - 2\right)\left(\lambda - 3\right)
9

The factored equation

\left(\lambda - 1\right)\left(\lambda - 2\right)\left(\lambda - 3\right) = 0
10

Set each factor equal to zero

\lambda - 1 = 0
\text{or}\quad \lambda - 2 = 0
\text{or}\quad \lambda - 3 = 0
\lambda = 1 \quad\text{or}\quad \lambda = 2 \quad\text{or}\quad \lambda = 3

A product is 0 only when at least one of its factors is 0 (the zero-product property).

11

Eigenvector for \displaystyle \lambda = 1

A - I = \begin{bmatrix} 1 & 0 & 0 \\ 1 & 2 & 0 \\ 4 & 5 & 0 \end{bmatrix}
\mathbf{v} = \begin{bmatrix} 0 \\ 0 \\ 1 \end{bmatrix}

Solve \displaystyle (A - \lambda I)\mathbf{v} = \mathbf{0}: row-reduce and choose the free variable.

12

Eigenvector for \displaystyle \lambda = 2

A - 2I = \begin{bmatrix} 0 & 0 & 0 \\ 1 & 1 & 0 \\ 4 & 5 & -1 \end{bmatrix}
\mathbf{v} = \begin{bmatrix} -1 \\ 1 \\ 1 \end{bmatrix}

Solve \displaystyle (A - \lambda I)\mathbf{v} = \mathbf{0}: row-reduce and choose the free variable.

13

Eigenvector for \displaystyle \lambda = 3

A - 3I = \begin{bmatrix} -1 & 0 & 0 \\ 1 & 0 & 0 \\ 4 & 5 & -2 \end{bmatrix}
\mathbf{v} = \begin{bmatrix} 0 \\ 2 \\ 5 \end{bmatrix}

Solve \displaystyle (A - \lambda I)\mathbf{v} = \mathbf{0}: row-reduce and choose the free variable.

Matrix A

Matrices as [[1, 2], [3, 4]]; name them A = …, B = … and write an expression like 2A − B^T, A*B or A^-1.

Fill in a matrix up to 6×6 to get its determinant, inverse, RREF, rank, characteristic polynomial or eigenvalues, or add, subtract and multiply two matrices – with cofactor expansion, Gauss–Jordan elimination and each row-by-column sum written out.

What each operation shows

OperationWorking shownNeeds
Determinantad - bc for 2×2; cofactor expansion along the row or column with the most zeros for 3×3; row reduction to triangular form for largerSquare matrix
InverseThe 2×2 formula, or Gauss–Jordan elimination on [A \mid I], then a check that AA^{-1} = ISquare, determinant ≠ 0
MultiplyEach entry as row × column: products, then sumsColumns of A = rows of B
Add / subtractEntry by entrySame size
PowerRepeated multiplication A^2, A^3, \dotsSquare matrix
RREF and rankRow operations column by column: pivot to 1, zeros above and belowAny size
EigenvaluesCharacteristic polynomial \det(A - \lambda I), its roots, and an eigenvector for each rational eigenvalueSquare, up to 4×4

Determinant of a 2×2 and a 3×3 matrix

\det\begin{bmatrix} a & b \\ c & d \end{bmatrix} = ad - bc

For a 3×3 matrix, expand along a row: each entry times the determinant of the 2×2 matrix left when its row and column are crossed out, with alternating signs +\,-\,+.

Example: \det\begin{bmatrix} 2 & 0 & 1 \\ 1 & 3 & 2 \\ 1 & 1 & 1 \end{bmatrix} along row 1

2(3 \cdot 1 - 2 \cdot 1) - 0 + 1(1 \cdot 1 - 3 \cdot 1) = 2 \cdot 1 + 1 \cdot (-2) = 0

The determinant is 0, so this matrix has no inverse.

Inverse of a matrix

For a 2×2 matrix swap the diagonal entries, change the signs of the other two, and divide by the determinant:

\begin{bmatrix} a & b \\ c & d \end{bmatrix}^{-1} = \frac{1}{ad - bc}\begin{bmatrix} d & -b \\ -c & a \end{bmatrix}

For larger matrices, write the identity matrix next to A and use row operations until the left half is the identity; the right half is then A^{-1}. If a row of zeros appears on the left, the matrix is singular and has no inverse.

Matrix multiplication

The entry in row i, column j of AB is row i of A times column j of B: multiply matching entries and add. An m × n matrix times an n × p matrix gives an m × p matrix. Order matters – AB and BA are usually different.

To solve a system of linear equations directly, use the system of equations calculator; for lengths, angles and cross products, the vector calculator.

Frequently asked questions

Why can’t I multiply these two matrices?

AB exists only when the number of columns of A equals the number of rows of B. A 2×3 matrix can multiply a 3×4 matrix (giving 2×4), but not a 2×3 matrix.

Is AB the same as BA?

Usually not – matrix multiplication is not commutative. Try A = [[1, 2], [3, 4]] and B = [[0, 1], [1, 0]]: AB − BA is not the zero matrix.

How are eigenvalues found?

Solve det(A − λI) = 0. The determinant is a polynomial in λ (the characteristic polynomial); its roots are the eigenvalues. For each one, the solutions of (A − λI)v = 0 are its eigenvectors.

Can I enter fractions?

Yes. Type 1/2, −3/4 or 0.25 in a cell. All the working uses exact fractions, so answers like 3/5 stay exact.