Matrix Diagonalization Calculator screenshot

Matrix Diagonalization Calculator

Work out the P and D with A = P × D × P⁻¹ from square matrix (rows on separate lines). Columns of P are eigenvectors; D holds the eigenvalues on its diagonal, and the page prints the substitution so the result can be checked by hand.

Privacy First
0 Runs
Updated 2026-11-22
Runs in your browser
No sign-up, no upload
Formula printed with the answer

Matrix Diagonalization Calculator

Work out the P and D with A = P × D × P⁻¹ from square matrix (rows on separate lines). Columns of P are eigenvectors; D holds the eigenvalues on its diagonal, and the page prints the substitution so the result can be checked by hand.

How this page computes

Columns of P are eigenvectors; D holds the eigenvalues on its diagonal

The page counts eigenvectors as well as roots. A repeated eigenvalue with too few independent eigenvectors is not diagonalizable, and the refusal names the eigenvalue and the two multiplicities.

P × D × P⁻¹ is multiplied back and compared with A exactly, so the printed P is verified.

The calculation runs entirely in this browser tab; nothing is uploaded.

Matrix Diagonalization Calculator computes the P and D with A = P × D × P⁻¹. Columns of P are eigenvectors; D holds the eigenvalues on its diagonal. The page prints the rule, the numbers substituted into it and the result, so the arithmetic can be checked by hand.

The page counts eigenvectors as well as roots. A repeated eigenvalue with too few independent eigenvectors is not diagonalizable, and the refusal names the eigenvalue and the two multiplicities. Pressed with square matrix 2 1; 0 3, it answers: Eigenvalues: 2 (×1), 3 (×1)

How to use Matrix Diagonalization Calculator

Enter square matrix 2 1; 0 3, then press Run: the page evaluates the P and D with A = P × D × P⁻¹ and prints every line of the working. Typed input is read exactly as written, and a blank field is refused with its name.

Read the first line as the answer and the lines below it as the substitution. If a value is out of range the page refuses it by field and reason instead of printing a number.

With square matrix 2 1; 0 3, the answer is Eigenvalues: 2 (×1), 3 (×1).

Both halves are tested

The page counts eigenvectors as well as roots. A repeated eigenvalue with too few independent eigenvectors is not diagonalizable, and the refusal names the eigenvalue and the two multiplicities.

P × D × P⁻¹ is multiplied back and compared with A exactly, so the printed P is verified.

What to Expect

Best for

  • Working out the P and D with A = P × D × P⁻¹ without a spreadsheet
  • Checking a figure someone else quoted
  • Seeing the formula behind an answer

Not ideal for

  • A characteristic polynomial that does not split over the rationals is refused, and so is a matrix whose geometric multiplicity falls short of its algebraic multiplicity.
  • A quantity the page cannot compute, which it refuses instead of estimating
  • Rounding an answer that has an exact form

What this tool keeps

  • Columns of P are eigenvectors; D holds the eigenvalues on its diagonal
  • Every input exactly as typed

What may need cleanup

  • Nothing: the printed answer is the final output
  • A unit conversion, if the inputs were entered in different units

Common errors

  • A characteristic polynomial that does not split over the rationals is refused, and so is a matrix whose geometric multiplicity falls short of its algebraic multiplicity.
  • An empty field is refused with the field's name

Example use cases

  • Work out the P and D with A = P × D × P⁻¹ for one set of inputs
  • Check the result against the formula by hand
  • See which input the answer is most sensitive to

Sample input

Matrix Diagonalization Calculator: square matrix 2 1; 0 3

Sample output

Eigenvalues: 2 (×1), 3 (×1) — P (eigenvectors as columns):

Who this is for

  • Students checking a formula
  • Anyone who needs the number and the working

Frequently asked questions

What formula does this page use?

Columns of P are eigenvectors; D holds the eigenvalues on its diagonal. The page prints the substitution as well, so the answer can be checked against the rule.

What does Matrix Diagonalization Calculator refuse?

A characteristic polynomial that does not split over the rationals is refused, and so is a matrix whose geometric multiplicity falls short of its algebraic multiplicity.

What does the default example give?

Square matrix 2 1; 0 3 gives Eigenvalues: 2 (×1), 3 (×1). Every line below that restates the same arithmetic.

Developer program

Build custom tools for your store

Join the SDK program to create useful ecommerce utilities for your store.