← LibraryNonsingular Matrices Are Invertible | KEVOS® MathematicsProject Delivery · Project ManagementLesson 109/189← PrevNext →
ArticlePublished 8 Aug 202621 min readBy Kevin Jogin
Skip to content

Engineering/Mathematics/Matrices

Nonsingular Matrices Are Invertible

For a square matrix, having a trivial null space and having an inverse are the same condition. Two supporting results deliver the equivalence: a product involving a singular factor is singular, and for square matrices a one-sided inverse is automatically two-sided.

  • Core level
  • Stream: matrix-algebra
  • Reading time 13 min
  • Ref KVS-ENG-MATH-0045
Taxonomy
Engineering / Mathematics
Prerequisite
Null spaces, nonsingularity and the matrix inverse
Central result
A nonsingular A invertible
Scope
Square matrices only
Consequence
AB=In alone implies BA=In
Payoff
Unique solution x=A1b for every b

Overview

Two apparently unrelated properties of a square matrix have been circling one another. Nonsingularity is a statement about a homogeneous system: Ax=0 has only the trivial solution, equivalently N(A)={0}. Invertibility is a statement about matrix algebra: there is a matrix B with AB=In and BA=In. The result established here is that, for square matrices, these are the same property. Neither can hold without the other.

The equivalence is worth more than its economy suggests, because the two descriptions are tested in completely different ways. Nonsingularity is checked by row reduction, which is an O(n3) computation on the matrix alone. Invertibility is exploited algebraically, by rearranging equations. Knowing the two coincide means a cheap structural test licenses an expensive algebraic privilege, and conversely that any failure of one is a failure of the other.

Two supporting results carry the argument. The first says that a product of square matrices in which at least one factor is singular is itself singular — singularity is contagious under multiplication. The second, and more surprising, says that for square matrices a one-sided inverse suffices: if AB=In then BA=In follows automatically. That is emphatically not a general algebraic fact; it depends on the finite, equal dimensions involved, and it fails for infinite-dimensional operators.

The immediate practical dividend is a formula. When A is nonsingular the system Ax=b has exactly one solution for every choice of b, and that solution is A1b. Existence, uniqueness and an explicit expression arrive together, which is why nonsingularity of a coefficient matrix is the first thing an engineer checks when a model is required to have a well-defined answer for every input.

Definition

Product With a Singular Matrix is Singular

PWSMS

Let A and B be square matrices of size n, at least one of which is singular. Then the product AB is singular.

The proof splits into the case where B is singular and the case where B is nonsingular and A is singular. That asymmetric split is deliberate: the second case is easier to argue with the stronger hypothesis, and the two cases together cover every configuration permitted by the hypothesis.

One-Sided Inverse is Sufficient

OSIS

Let A and B be square matrices of size n with AB=In. Then BA=In as well, so A and B are inverses of each other.

Squareness is essential. For rectangular matrices a one-sided inverse can exist with no matching inverse on the other side, and the analogous statement fails outright for operators on infinite-dimensional spaces.

NonSingularity is Invertibility

NSI

A square matrix A is nonsingular if and only if A is invertible. Having only the trivial solution to Ax=0 and possessing a two-sided inverse are the same condition.

Solution with NonSingular Coefficient Matrix

SNSCM

If A is nonsingular, the system Ax=b has the unique solution x=A1b, for every vector of constants b.

Existence follows by substitution: A(A1b)=(AA1)b=Inb=b. Uniqueness is a separate consequence of nonsingularity, and both hold for every b simultaneously.

Concepts

Singularity propagates through a product

If B is singular there is a non-zero z with Bz=0, and then (AB)z=A(Bz)=A0=0, so the same z certifies AB as singular. If instead B is nonsingular and A is singular, take a non-zero y with Ay=0 and let w be the unique solution of Bw=y. That w cannot be zero, since B0=0y, and (AB)w=Ay=0. Either way a non-zero null vector for AB is exhibited.

Why one side is enough for square matrices

Suppose AB=In. The identity matrix is nonsingular, so if B were singular the previous result would force In to be singular — a contradiction. Hence B is nonsingular, and the augmented reduction procedure supplies a matrix C with BC=In. Then BA=(BA)In=(BA)(BC)=B(AB)C=BInC=BC=In. Every step is associativity or the identity property; the substance is that a right inverse for B was available, and that availability came from B being nonsingular.

The equivalence in both directions

If A is invertible and Ax=0, then x=Inx=(A1A)x=A1(Ax)=A10=0, so the null space is trivial and A is nonsingular. Conversely, if A is nonsingular then reduction of [AIn] produces B with AB=In, and the one-sided result upgrades this to a genuine two-sided inverse. The two implications use entirely different machinery, which is characteristic of the equivalence theorems in this subject.

What the procedure proves and what it does not

The reduction procedure applied to a singular matrix fails to produce an inverse, but failing to find something is not the same as showing it does not exist. The equivalence supplies the missing half: a singular matrix has no inverse at all, by any method. That distinction is not pedantry — it is the difference between an algorithm reporting no result and a proof of impossibility, and only the latter licenses a conclusion about the underlying model.

The growing list of equivalent conditions

Invertibility joins a list of statements about a square matrix A of size n that are all equivalent: A is nonsingular; A row-reduces to In; N(A)={0}; the system Ax=b has a unique solution for every b; the columns of A form a linearly independent set; and A is invertible. Each entry is a different diagnostic instrument aimed at the same underlying property, and the list keeps growing as further structures are introduced.

Existence, uniqueness and a formula at once

When A is nonsingular, A1b satisfies the system by direct substitution, and nonsingularity rules out any second solution. The three questions an engineer asks about a linear model — is there an answer, is it the only one, and what is it — are therefore settled together and for every right-hand side simultaneously. This is why nonsingularity of a coefficient matrix functions as a well-posedness certificate for the model that produced it.

Logical route from nonsingularity to a solution formula

A row-reduces to InEquivalently N(A)={0}: the matrix is nonsingular.
Reduction of [AIn] yields B with AB=InThe augmented procedure succeeds precisely because the left block reduces to the identity.
A product with a singular factor is singularSince AB=In is nonsingular, neither A nor B can be singular.
One side suffices, so BA=InB is nonsingular, so it has a right inverse C; regrouping gives BA=BC=In.
A is invertible with A1=BBoth defining products hold, and uniqueness of the inverse fixes B as the inverse.
Every system has the unique solution A1bExistence by substitution, uniqueness from nonsingularity, for every right-hand side.

Equations

Singularity propagates through a product

EQ-NSMI-01
Bz=0,z0(AB)z=A(Bz)=A0=0

The same non-zero vector that certifies B as singular certifies AB as singular.

One-sided inverse is sufficient

EQ-NSMI-02
BA=(BA)In=(BA)(BC)=B(AB)C=BInC=BC=In

Given AB=In and a right inverse C of the nonsingular matrix B, regrouping produces the missing product.

Invertibility forces a trivial null space

EQ-NSMI-03
x=Inx=(A1A)x=A1(Ax)=A10=0

Any solution of the homogeneous system is forced to be the zero vector, so an invertible matrix is nonsingular.

Nonsingularity is invertibility

EQ-NSMI-04
N(A)={0}A1withAA1=A1A=In

The central equivalence, valid for square matrices of any size over .

Unique solution with a nonsingular coefficient matrix

EQ-NSMI-05
A(A1b)=(AA1)b=Inb=b

Substitution confirms that A1b solves the system; nonsingularity confirms that nothing else does.

Equivalent conditions for a square matrix

EQ-NSMI-06
AnonsingularAInN(A)={0}columns independentAinvertible

Five interchangeable diagnostics for the same property. The symbol denotes row equivalence.

A nonsingular and a singular matrix compared

EQ-NSMI-07
A=[121231113],S=[121231112]

The pair used below. A single entry separates a matrix with a trivial null space from one whose null space is a line.

Variable Definitions

Symbols used on this page
SymbolNameMeaningDomain / type
ASquare matrix under testThe matrix whose nonsingularity and invertibility are in questionn x n complex matrix
BCandidate inverseMatrix produced by the augmented reduction, satisfying AB=Inn x n complex matrix
CRight inverse of BAuxiliary matrix with BC=In, used to complete the one-sided argumentn x n complex matrix
zNull vectorNon-zero solution of a homogeneous system, the certificate of singularityC^n, nonzero
bVector of constantsRight-hand side of the system Ax=bC^n
N(A)Null space of ASet of all solutions of Ax=0subspace of C^n
InIdentity matrixNonsingular reference matrix and target of both defining productsn x n matrix
SSingular example matrixSquare matrix with a non-trivial null space, used as a contrast casen x n complex matrix
nSizeCommon row and column count of all matrices involvedpositive integer

Worked Numerical Example

Problem statement

Two candidate designs for a three-node resistive sensing network differ in a single conductance. Determine which coefficient matrix is nonsingular, invert it, use the inverse across two excitation cases, and interpret the failure of the other design.

  1. Row-reduce the first candidate

    Apply R2R22R1 and R3R3R1 to A, then continue to reduced form. The result is the identity matrix, so N(A)={0} and A is nonsingular.

    A=[121231113][100010001]
  2. Invoke the equivalence

    Nonsingularity now guarantees invertibility — not merely that the reduction procedure will terminate, but that an inverse exists as a mathematical object. Reducing [AI3] produces it.

    A1=[875543111]
  3. Confirm with one product

    Row 1 of A against the three columns of A1 gives 8+101=1, 78+1=0 and 5+61=0; the remaining rows follow the same pattern. Because the matrices are square, the one-sided result guarantees the reverse product without a second computation.

    AA1=I3A1A=I3
  4. Excitation case one

    For b=(5,6,0) the entries of A1b are 40+42+0=2, 2524+0=1 and 56+0=1.

    x=A1[560]=[211]
  5. Excitation case two

    For b=(0,3,4) the entries are 0+2120=1, 012+12=0 and 03+4=1. Substituting back into the original equations reproduces b, confirming both results.

    x=A1[034]=[101]
  6. Row-reduce the second candidate

    Changing the (3,3) entry from 3 to 2 gives S. Reduction now stalls with a zero row: the third row is a combination of the first two, so S has only two pivot columns.

    S=[121231112][105013000]
  7. Exhibit the null vector

    Setting the free variable x3=1 gives x1=5 and x2=3. Direct substitution confirms Sz=0: the rows evaluate to 5+61, 10+9+1 and 5+3+2, all zero.

    z=[531]0,Sz=0
  8. Conclude that no inverse exists

    Since N(S){0}, the matrix S is singular, and the equivalence rules out an inverse by any method whatsoever. It follows further that SB is singular for every square B, so no combination of S with another network can restore a well-posed model.

Result

The first design yields a unique node-voltage vector for every excitation, obtained from one stored inverse at the cost of a matrix-vector product per case. The second design is singular: the vector z describes a non-zero pattern of node quantities that produces no measurable response, so the network cannot distinguish states differing by any multiple of z. That is an observability defect in the design, not a numerical difficulty, and it must be fixed by changing the topology or the element values.

Applications & Industry Use

Instrumentation and measurement

Observability of a sensing array

A measurement model y=Ax with square A is invertible exactly when distinct states produce distinct readings. A non-trivial null space is a set of state changes the instrument cannot see, so testing nonsingularity of the design matrix is the formal check that a sensor layout resolves everything it is meant to resolve.

Electrical circuit analysis

Well-posedness of nodal analysis

Modified nodal analysis produces a square system whose nonsingularity guarantees a unique operating point. Singularity signals a genuine modelling defect — a floating subcircuit with no reference, a loop of ideal voltage sources — which simulators detect and report as a topology error rather than a convergence failure.

Structural engineering

Adequate restraint of a model

An assembled stiffness matrix is singular when the structure retains a rigid-body mechanism, and the null space is spanned by the corresponding motions. Because singularity is proved rather than merely detected, an analysis package can report the specific unrestrained mode instead of simply refusing to solve.

Control systems

Feasibility of state feedback and estimation

Pole placement and observer design require the controllability or observability matrix to be nonsingular. The equivalence means the same computation that answers the rank question also certifies that the required inverse exists, so the design step and the feasibility test are one calculation.

Computational geometry

Degenerate configurations in mesh generation

Barycentric coordinates within a simplex are obtained by inverting a square matrix built from its vertices. Singularity means the vertices are affinely dependent — a degenerate, zero-volume element — so the invertibility test is simultaneously the mesh quality test.

Chemical process engineering

Independence of a reaction set

A square stoichiometric matrix is singular exactly when the chosen reactions are linearly dependent, in which case the extent of reaction is not determined by the species balances alone. Detecting the null vector identifies the redundant combination and tells the modeller which reaction to remove.

Design Considerations

Nonsingularity is a property of the model, not of the arithmetic

A singular coefficient matrix nearly always encodes a real defect in the underlying model: an unrestrained degree of freedom, an unobservable state, a redundant equation. Treat singularity as a diagnostic to be interpreted rather than a numerical obstacle to be regularised away, and report the null vector, which names the defect.

In floating point the equivalence becomes a matter of degree

Exact arithmetic gives a clean dichotomy; floating point does not. A nearly singular matrix is invertible in principle and useless in practice. Report the condition number or the smallest singular value alongside any invertibility claim, and set the threshold from the accuracy of the input data rather than from machine epsilon.

One-sided verification is enough, but only for square matrices

For square A and B, confirming AB=In establishes that B=A1. The saving is real for large matrices. It disappears entirely for rectangular matrices, where a left inverse and a right inverse are genuinely different objects and may not both exist.

Do not attempt to repair a singular matrix by multiplication

Since a product with a singular factor is singular, no preconditioner, scaling or auxiliary matrix can turn a singular system into a nonsingular one. The remedies are to change the model, add constraints, or move to a least-squares or pseudoinverse formulation that accepts rank deficiency explicitly.

Use the equivalence to choose the cheapest test

All the listed conditions are interchangeable, so pick the one that is cheapest in context. Row reduction is natural when the matrix is already being eliminated; a Cholesky attempt is decisive and fast for a symmetric candidate; a singular value decomposition is the most informative when the answer is marginal.

Prefer a solve to an inverse even after the equivalence is established

Knowing that A1 exists does not make forming it the right computation. The formula x=A1b is a statement about the solution, not an instruction for obtaining it; a factorisation with triangular solves is faster and more accurate for the same result.

Standards & Codes

Notation, interchange and numerical standards that govern how this material is written down, stored and computed in production systems.

Applicable standards, conventions and reference implementations
ReferenceTitleRelevance to this topic
ISO 80000-2Quantities and units — Part 2: MathematicsStandardises the notation for the null space, the identity matrix and the inverse used in stating the equivalence, including the script letters reserved for distinguished subspaces.
LAPACK / BLAS referenceLinear Algebra PACKage reference implementationEncodes the practical form of the equivalence: xGETRF reports a zero pivot through its info parameter, and xGECON supplies the reciprocal condition estimate that replaces an exact singularity test.
IEEE 754-2019IEEE Standard for Floating-Point ArithmeticExplains why exact singularity is essentially never observed numerically: rounding perturbs a zero pivot into a tiny non-zero value, so the sharp dichotomy of the theorem becomes a threshold decision.
IEC 61508Functional safety of electrical, electronic and programmable electronic safety-related systemsMotivates treating an ill-conditioned or singular model matrix as a detected fault requiring a defined safe response, rather than allowing a numerically returned but meaningless solution to propagate.
ISO/IEC 40314Mathematical Markup Language (MathML) Version 3.0Represents the chains of equivalences on this page as structured markup, so the biconditional symbols are exposed as relations rather than as decorative glyphs.

Material Selection

For a mathematical topic, "material" is the numeric representation: the scalar field, storage format and precision the computation is built from.

Representation and precision selection
RepresentationSelect whenTrade-off
Exact rational arithmeticSmall symbolic or structural models where the answer is a definitive yes or no about singularity.Delivers the sharp dichotomy the theorem describes, but is impractical beyond modest sizes and cannot express near-singularity, which is often the more useful engineering information.
IEEE 754 binary64 with condition estimationThe default for engineering coefficient matrices, where a graded answer is more informative than a binary one.Fast and well supported, but requires a tolerance policy; the invertibility verdict then depends on a threshold that must be documented and justified.
Singular value decompositionThe matrix is marginal, or the null space itself must be reported to diagnose the modelling defect.The most numerically reliable rank and null-space determination available, at several times the cost of an LU factorisation.
Cholesky factorisation attemptThe candidate matrix is symmetric and expected to be positive definite, as with stiffness and covariance matrices.Half the cost of a general factorisation and it fails cleanly when definiteness is lost, but it certifies more than nonsingularity, so a failure does not by itself prove singularity.
Modular arithmetic over a prime fieldCertifying nonsingularity of a large exact integer matrix without rational blow-up.Very fast and exact, but nonsingularity modulo an unlucky prime can differ from nonsingularity over the rationals, so several primes are needed for confidence.
Sparse factorisation with fill-reducing orderingLarge network, circuit or finite element matrices where the inverse could never be stored.Answers the invertibility question and solves systems at a fraction of the dense cost, but the ordering computation is itself substantial and the factors, unlike the matrix, are not sparse for free.

Manufacturing Notes

Implementation notes — how the result is actually produced by hand, by algorithm and by library, including cost and numerical behaviour.

How the test is actually performed

Production code does not row-reduce to the identity. It computes an LU factorisation with partial pivoting at about 23n3 operations and inspects the pivots, then estimates the reciprocal condition number at O(n2) additional cost. Together these deliver the invertibility verdict and a quantitative measure of how safe it is.

Verifying a one-sided product

The theorem permits checking AB=In alone, at a cost of 2n3 operations for the product. In floating point the check compares ABIn against a tolerance of order nεAB; a residual far above that indicates an implementation error, while one near it merely reflects rounding.

Extracting the null vector as a diagnostic

When a matrix is found singular, the informative output is not the verdict but the null vector. It is obtained from the reduced form by setting one free variable to unity, or more robustly as the right singular vector belonging to the smallest singular value. In a structural or circuit model that vector names the specific defect.

Hand procedure

For a matrix small enough to reduce by hand, drive it to reduced row-echelon form and compare with In; there is no need to carry an augmented block until invertibility is established. If a zero row appears, stop and read the null space directly from the reduced form rather than restarting with an inversion attempt.

Library conventions on failure

NumPy raises LinAlgError on an exactly singular input to inv, but returns a result with no complaint for a matrix that is merely severely ill-conditioned. MATLAB warns via the reciprocal condition estimate. Neither behaviour should be relied on as a model-validation gate; check the condition number explicitly.

Failure Modes & Common Mistakes

Failure modes, root causes and prevention
Failure mode / mistakeImpactRoot causePrevention & detection
Applying the equivalence to a rectangular matrixhighExtending nonsingularity and invertibility to non-square matrices, where neither term is defined as stated.Check the shape first. For rectangular matrices use rank, one-sided inverses or the pseudoinverse, and say which is meant.
Confusing a failed algorithm with a proof of non-existencemediumConcluding from a stalled reduction that no inverse exists, without invoking the equivalence.Cite the theorem. Nonsingularity is what rules out an inverse, and the failure of one procedure would otherwise leave the question open.
Verifying only one product on rectangular operandshighCarrying the square-matrix shortcut into a setting where a one-sided inverse does not imply the other side.The one-sided result requires both matrices to be square of the same size. Outside that hypothesis, compute both products or work with the pseudoinverse.
Treating near-singularity as nonsingularityhighRelying on the exact dichotomy when the matrix has a condition number near the reciprocal of machine epsilon.Report the condition number with every invertibility claim, and set the acceptance threshold from the uncertainty in the input data.
Trying to fix a singular system by preconditioningmediumExpecting a scaling or auxiliary matrix to restore invertibility, contrary to the propagation of singularity through products.Change the model, add constraints or adopt a least-squares formulation. No multiplication can remove a null vector.
Assuming both factors are singular when a product islowReading the implication backwards; a singular product requires at least one singular factor, not both.State the direction explicitly. The contrapositive is the useful form: if the product is nonsingular then both factors are nonsingular.
Solving by explicit inversion once invertibility is knownmediumReading the formula x=A1b as an algorithm rather than as a statement about the solution.Use a factorisation and triangular solves. The formula certifies existence and uniqueness; it is not a recommended computation.
Ignoring the null vector when singularity is detectedmediumReporting only that the matrix is singular, discarding the vector that identifies the mechanism or unobservable mode.Always extract and report a null space basis; it converts an abstract failure into an actionable design finding.

FAQs

Why is squareness essential to the one-sided inverse result?

The argument needs a right inverse for B, and that is supplied by the reduction procedure only for square nonsingular matrices. For rectangular matrices the two sides are genuinely different: a matrix with full column rank has a left inverse and typically no right inverse, and the sizes of the two identity matrices differ.

Does the equivalence hold over fields other than the complex numbers?

Yes. The arguments use only field arithmetic, so nonsingularity and invertibility coincide over the rationals, the reals, the complex numbers and any finite field. Over a ring such as the integers the statement changes: an integer matrix is invertible over the integers only when its determinant is a unit.

If AB is singular, must both A and B be singular?

No — only at least one of them. The theorem says a singular factor forces a singular product; the contrapositive says a nonsingular product forces both factors to be nonsingular. Reading the implication in the wrong direction is a common slip.

How does this change how I check whether a matrix has an inverse?

It lets you test the cheaper condition. Row-reduce A alone and compare with In, or examine the pivots of an LU factorisation, without ever forming an augmented array. Only after invertibility is confirmed does it make sense to compute the inverse, and even then only if the inverse itself is needed.

What does the null vector of a singular coefficient matrix mean physically?

It is a non-zero pattern of the unknowns that produces no response at all. In a structural model it is a rigid-body or mechanism motion; in a measurement model it is a state change the instrument cannot detect; in a reaction network it is a redundant combination of reactions. It is the most useful single output of a failed invertibility test.

Is the equivalence still meaningful in floating-point arithmetic?

It remains true of the exact matrix, but the exact matrix is rarely what the computer holds. Numerically, invertibility is replaced by a graded question: how close is this matrix to the nearest singular one, as measured by the condition number or the smallest singular value. Design the tolerance from the data, not from the arithmetic.

Why does the proof of the product result split into those particular two cases?

Because the second case is easier with a stronger hypothesis. Assuming B nonsingular and A singular gives access to the unique solution of Bw=y, which the argument needs. The first case covers every situation in which B is singular regardless of A, so together they exhaust the hypothesis.

References

  1. Beezer, R. A. A First Course in Linear Algebra, Version 0.70. University of Puget Sound, 2006. Section MINSM, Subsection NSMI. Licensed under the GNU Free Documentation License v1.2.
  2. ISO 80000-2:2019, Quantities and units — Part 2: Mathematics. International Organization for Standardization.
  3. Horn, R. A. and Johnson, C. R. Matrix Analysis, 2nd edition. Cambridge University Press, 2012.
  4. Golub, G. H. and Van Loan, C. F. Matrix Computations, 4th edition. Johns Hopkins University Press, 2013.
  5. Higham, N. J. Accuracy and Stability of Numerical Algorithms, 2nd edition. Society for Industrial and Applied Mathematics, 2002.
  6. Anderson, E. et al. LAPACK Users' Guide, 3rd edition. Society for Industrial and Applied Mathematics, 1999.

AI Suggested Questions

  • Give a rectangular matrix with a left inverse but no right inverse, and explain why the one-sided result cannot apply.
  • Show how the null vector of a singular stiffness matrix identifies the specific rigid-body mechanism in a planar frame.
  • Compare the cost of testing nonsingularity by LU factorisation, by determinant evaluation and by singular value decomposition for n=1000.
  • Explain why a one-sided inverse does not imply a two-sided inverse for operators on an infinite-dimensional space, with a shift-operator example.
  • How should a safety-critical system respond when a model matrix is found to be numerically singular at run time?
  • Trace how the equivalence list for nonsingular matrices grows as column spaces, determinants and eigenvalues are introduced.

Related Calculators

Continue learning

Algebraic and Geometric Multiplicities of Eigenvalues | KEVOS® MathematicsArticle · Project ManagementAmitsur’s Theorem on the Radical of a Polynomial Ring | KEVOS®Article · Project ManagementAmitsur’s Theorem on the Radical of an Algebra of Small Dimension | KEVOS®Article · Project ManagementArchetypes: Reference Catalogue of Worked Systems | KEVOS® MathematicsArticle · Project Management