I often have to generate null matrices so I created this simple online utility that does it for me. It lets you generate square and rectangular zero matrices of any size you need. It works in the browser and is powered by alien technology from the future.

Null Matrix Generator Options

Matrix Dimension
Zero Element
Matrix Format

Null Matrix Generator Examples (click to try!)

Rectangle Zero Matrix
In this example, we generate a zero matrix of size 5×15. All elements of this matrix are regular 0's. The columns are separated by a space and the rows are separated by a newline.
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Number of rows.
Number of columns.
Null element of the matrix.
Separate matrix columns with this character.
Separate matrix rows with this character.
Unicode Null Element
This example uses a Unicode character for the null element. This character is the circled digit zero "⓪". The null matrix size is set to a square with 6 rows and 6 columns, and the column separator is unset so that there is no space between the matrix elements.
⓪⓪⓪⓪⓪⓪
⓪⓪⓪⓪⓪⓪
⓪⓪⓪⓪⓪⓪
⓪⓪⓪⓪⓪⓪
⓪⓪⓪⓪⓪⓪
⓪⓪⓪⓪⓪⓪
Number of rows.
Number of columns.
Null element of the matrix.
Separate matrix columns with this character.
Separate matrix rows with this character.
Null Vector
This example outputs a row vector with 15 components. A row vector is the same as a matrix with the dimension 1×n. In this case, n is 15 so the matrix size is 1×15.
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Number of rows.
Number of columns.
Null element of the matrix.
Separate matrix columns with this character.
Separate matrix rows with this character.
Just a Zero
In this example, we print a singular (degenerate) null matrix of size 1×1, which has just one element. The zero element is customized and is set to the math double-struck zero digit.
𝟘
Number of rows.
Number of columns.
Null element of the matrix.
Separate matrix columns with this character.
Separate matrix rows with this character.
Breaking the Rules
This example breaks all math rules and sets the zero element to one. As a result, we get a matrix that's filled with ones or a fully-filled unit matrix.
1 1 1 1 1 1
1 1 1 1 1 1
1 1 1 1 1 1
1 1 1 1 1 1
1 1 1 1 1 1
1 1 1 1 1 1
Number of rows.
Number of columns.
Null element of the matrix.
Separate matrix columns with this character.
Separate matrix rows with this character.
Column Vector
In this example, we generate a column zero vector that has the dimension of 9. This dimension means that the vector has 9 zeros in it. Each zero is printed on a new line.
0
0
0
0
0
0
0
0
0
Number of rows.
Number of columns.
Null element of the matrix.
Separate matrix columns with this character.
Separate matrix rows with this character.

How Does This Null Matrix Generator Work?

This null matrix generator works entirely in your browser and is written in JavaScript. It uses a double for loop and the code snippet m[i][j] = zeroElement to set all matrix elements mij to the given zero element. The zero element can be customized in the options. It defaults to the regular math zero 0 but you can set it to other interesting single- or multi-letter characters. For example, you can set it to a circled zero , a bold middle-dot , or make it a ones-matrix by breaking all the rules and setting the zero element to 1. It supports matrices of sizes n×n (square matrices), m×n (horizontal rectangular matrices), and n×m (vertical rectangular matrices). The matrix columns and rows can be separated by any symbols that you like. By default, the columns are separated by a single whitespace and the rows are put on a newline.

Created by Browserling

This null matrix generator was created by me and my team at Browserling. Behind the scenes, it's actually powered by our programmer tools that are used by millions of people every month. Browserling itself is an online cross-browser testing service powered by alien technology. Check it out!

Secret message: If you love my tools, then I love you, too! Use coupon code TOOLLING to get a discount at my company.