Matrix of ones


In mathematics, a matrix of ones or all-ones matrix is a matrix where every element is equal to one. Examples of standard notation are given below:
Some sources call the all-ones matrix the unit matrix, but that term may also refer to the identity matrix, a different matrix.

Properties

For an matrix of ones J, the following properties hold:
When J is considered as a matrix over the real numbers, the following additional properties hold:
The all-ones matrix arises in the mathematical field of combinatorics, particularly involving the application of algebraic methods to graph theory. For example, if A is the adjacency matrix of a n-vertex undirected graph G, and J is the all-ones matrix of the same dimension, then G is a regular graph if and only if AJ = JA. As a second example, the matrix appears in some linear-algebraic proofs of Cayley's formula, which gives the number of spanning trees of a complete graph, using the matrix tree theorem.