Null Space Calculator

Find a basis for the null space of a matrix.

FreeNo accountOn your device

Runs in your browser. How to verify

Loading tool…

About this tool

Enter a matrix to find the vectors x with Ax = 0. For [1 2 3; 2 4 6] the null space has two basis vectors, (−2, 1, 0) and (−3, 0, 1).

How to use

1
Step 1
Type the matrix.
2
Step 2
Choose nullspace.
3
Step 3
Press Calculate to see the basis vectors as columns.

How it works

Row reduction exposes the free variables, and each free variable gives one basis vector. The count of basis vectors, the nullity, equals the number of columns minus the rank. If the columns are independent, only x = 0 works.

Ax = 0      nullity = columns − rank

Worked example

Rank 1, three columns

Input
[1 2 3; 2 4 6]
Output
(−2, 1, 0) and (−3, 0, 1)
Walkthrough
Both rows say x + 2y + 3z = 0. Choose y = 1, z = 0 to get x = −2, then y = 0, z = 1 to get x = −3. Nullity = 3 − 1 = 2.

Limitations

  • Entries must be real numbers; complex entries are refused.
  • The identity matrix returns only the zero vector.
  • Basis vectors are not unique; any independent combination spans the same space.

Questions

What is the null space of [1 2 3; 2 4 6]?
It is spanned by (−2, 1, 0) and (−3, 0, 1).
What is the null space of the identity matrix?
Only the zero vector.
How is nullity related to rank?
Nullity = number of columns − rank, so 3 − 1 = 2 here.

Features

  • Basis from row reduction
  • Rank-nullity check
  • Runs in your browser

Related resources

Guides and videos from around the web—opens on YouTube or the publisher’s site.

  • Rectangle area as product of dimensions

    Khan Academy

    Foundational area thinking across math tools.

    Watch on YouTube
  • Vectors | Essence of linear algebra

    3Blue1Brown

    Linear algebra intuition for matrix and vector tools.

    Watch on YouTube
  • Order of Operations

    Math is Fun

    PEMDAS/BODMAS when expression calculators surprise you.

  • Pi

    Math is Fun

    What π means when calculators return pi-based results.