Skip to main content
v2026.11,986 entries · CC-BY 4.0

Hadamard Matrices: Definition, Constructions and Open Orders

Hadamard matrices explained: the H·Hᵀ = nI test, Sylvester and Paley constructions, which orders exist, the open conjecture and lab uses.

Written and maintained by CASRAI Editorial Board

Published

On this page

A Hadamard matrix is a square matrix of order n whose entries are all +1 or −1 and whose rows are mutually orthogonal, so that H·Hᵀ = n·Iₙ. Such matrices can exist only for order 1, 2 or a multiple of 4, and the Hadamard conjecture says they exist for every multiple of 4. In laboratory practice they appear in screening experimental designs, coded-aperture spectrometry, error-correcting codes and the quantum Hadamard gate.

Short answer

A Hadamard matrix is an n × n grid of +1 and −1 entries in which any two different rows are orthogonal (their dot product is zero). The smallest example is H₂ = [[1, 1], [1, −1]]. Larger ones are built by named constructions such as Sylvester’s doubling, Paley’s finite-field method and Williamson’s circulant-block method. Whether one exists for every order that is a multiple of 4 is the open Hadamard conjecture. The data table at the end of this page lists the number of inequivalent matrices known for the smallest orders.

Definition and scope

The SageMath documentation for its hadamard_matrix module defines a Hadamard matrix as an n × n matrix H with entries +1 or −1 whose rows are mutually orthogonal. Two equivalent tests follow from that definition: H·Hᵀ = n·Iₙ, where Iₙ is the identity matrix, or |det H| = nn/2. Hadamard’s determinant bound (1893) says that for any real matrix with entries of absolute value at most 1, |det M| ≤ nn/2; a Hadamard matrix is exactly the real case that reaches the bound, which is why they are called maximal-determinant matrices (Wikipedia, “Hadamard matrix”).

The Sage documentation also defines a normalized Hadamard matrix as one whose first row and first column are all +1. Any Hadamard matrix can be brought to this form by multiplying rows and columns by −1, which does not change orthogonality. Orthogonality is also preserved by permuting rows or columns, and that is the basis of the “equivalence” used when counting distinct matrices of a given order.

The matrix is named after Jacques Hadamard, whose 1893 paper in the Bulletin des Sciences Mathématiques (series 2, volume 17, pages 240–246) gave examples of orders 12 and 20. The simplest family had been described earlier by J. J. Sylvester in 1867 (Phil. Mag. 34).

Which orders are possible

The Sage documentation states the necessary condition: a Hadamard matrix of order n can exist only if n = 1, 2 or n is a multiple of 4. It also records the conjecture, which it attributes possibly to Paley, that this condition is sufficient. The Tao et al. optimization-problems page on the Hadamard conjecture gives the same statement. No proof or counterexample is known, so “exists for every multiple of 4” remains a conjecture, not a theorem.

How Hadamard matrices are built

No single formula produces every order. The Sage documentation lists the construction families below, and the table summarises what each one yields, using the order conditions stated there.

Construction What it needs Orders produced
Sylvester (tensor product) A Hadamard matrix of order m and one of order n; tensoring gives order mn. Tensoring repeatedly with H₂ is the Sylvester construction. Powers of 2 (2, 4, 8, 16, …) when starting from H₂
Paley type I A prime power p with p ≡ 3 (mod 4) n = p + 1
Paley type II A prime power p with p ≡ 1 (mod 4) n = 2(p + 1)
Williamson and Turyn types Circulant blocks (Baumert–Hall units in the Turyn variants) Selected orders that the methods above miss
Goethals–Seidel, Cooper–Wallis, Spence, Miyamoto Further block and array methods covered by the module Selected orders
Skew Hadamard A matrix of the form H = S + I with Sᵀ = −S Special subfamily with extra structure

The Paley conditions are written there as p = n − 1 with p ≡ 3 (mod 4) for type I, and p = n/2 − 1 with p ≡ 1 (mod 4) for type II. Both p and the resulting order are therefore tied directly: a prime power such as 11 (which is ≡ 3 mod 4) gives order 12 by type I.

A worked example from the definition

Take H₂ = [[1, 1], [1, −1]]. Its two rows have dot product 1·1 + 1·(−1) = 0, so they are orthogonal, and H₂·H₂ᵀ = 2·I₂. Tensoring H₂ with itself gives the order-4 matrix with rows (1, 1, 1, 1), (1, −1, 1, −1), (1, 1, −1, −1) and (1, −1, −1, 1). Each pair of rows again has dot product 0, and the determinant magnitude is 44/2 = 16.

A checklist for validating a candidate matrix

  1. Confirm the matrix is square and every entry is exactly +1 or −1.
  2. Confirm the order is 1, 2 or a multiple of 4; if not, no Hadamard matrix of that order exists.
  3. Compute H·Hᵀ and check that it equals n times the identity matrix. Equivalent, check that |det H| equals nn/2.
  4. If another system expects normalized form, multiply rows and columns by −1 until the first row and first column are all +1.
  5. Only after these tests, compare against a reference list if you need to know which equivalence class the matrix belongs to.

The Sage module implements these tests as its own validity check, which makes it a convenient reference implementation when you generate a matrix in other software.

Orders and the Hadamard conjecture

The Sage documentation reports that its module covers every order up to 1200 for which a construction is known. Sylvester and Paley together do not reach every multiple of 4. According to Wikipedia, 92 is the smallest order that neither method produces; a matrix of order 92 was found in 1962 at the Jet Propulsion Laboratory by Baumert, Golomb and Hall using the Williamson construction. A matrix of order 428 was reported by Kharaghani and Tayfeh-Rezaie (Journal of Combinatorial Designs 13, 2005).

Which orders are still unresolved depends on the date of the source. The Tao et al. page, which cites the Cati and Pasechnik database of constructions (arXiv:2411.18897), identifies 668 as the smallest unresolved order and lists 668, 716, 892 and 1132 as the only unresolved orders up to 1208. In August 2026, John D. Cook’s blog reported that Levent Alpoge announced he and collaborators had found a Hadamard matrix of order 668 and filled in the remaining gaps below 2000. That blog post gave no primary technical report, so treat the announcement as reported, not as a peer-reviewed result; the same post notes that the general conjecture has not been proved.

A separate, asymptotic result is available as a preprint: Du and Jiang (arXiv:2401.15381, submitted 27 January 2024) show that Hadamard matrices of order 2t·m exist for every odd m, with t growing only logarithmically in m. This narrows the gap between known and conjectured orders, but does not settle individual orders.

The data table below the FAQ records how many inequivalent Hadamard matrices are known at the smallest orders; it shows how quickly the number of distinct matrices grows once the order passes 16.

Where Hadamard matrices matter in labs

Wikipedia’s Hadamard matrix article lists applications that reach into bench and instrument work. These are the ones most relevant to laboratory and research settings.

  • Screening experimental designs. Plackett–Burman designs, used to screen many factors in few runs, are built from Hadamard matrices. Run counts are therefore multiples of 4, which is the same order condition given above.
  • Coded-aperture spectrometry. Coded-aperture spectrometry is among the applications Wikipedia lists for Hadamard matrices.
  • Error-correcting codes. Hadamard codes and Reed–Muller codes are derived from the rows of a Hadamard matrix.
  • Survey and replication methods. Balanced repeated replication uses Hadamard matrices to define half-samples for variance estimation.
  • Compressed sensing. Hadamard-type measurement matrices are listed among the applications.
  • Quantum computing. The one-qubit Hadamard gate is the matrix H₂ scaled by 1/√2, and the Hadamard transform applies it across several qubits. For algorithm context see the CASRAI guide on quantum algorithms.

For related signal-decomposition ideas, the guide to harmonic analysis covers the wider topic of decomposing signals into orthogonal components.

Common misunderstandings

A Hadamard matrix is not the Hadamard product

The Hadamard product multiplies two matrices of the same size element by element. It is unrelated to the matrix defined on this page, apart from being named after the same mathematician. If you came here from a spreadsheet or code question, see the guide to element-wise array multiplication in MATLAB.

Entries are not just “any orthogonal matrix of ones”

The entries must be exactly +1 or −1. A general orthogonal matrix can have other real entries and is not Hadamard. The Hadamard matrix is orthogonal only up to scaling: H·Hᵀ = n·I, so H/√n is orthogonal in the usual sense.

Existence is not proven for all multiples of 4

The necessary condition (order 1, 2 or a multiple of 4) is proven. That it is also sufficient is the conjecture. Results that fill in individual orders do not prove the general statement.

Different-looking matrices can be the same matrix

Row and column permutations and sign changes give equivalent matrices. When the table below says order 12 has a unique matrix, it means unique up to this equivalence, not that only one array of signs exists.

FAQ

What is a Hadamard matrix?

It is a square matrix with entries +1 and −1 whose rows are pairwise orthogonal, so H·Hᵀ = n·Iₙ (SageMath documentation).

For which sizes does a Hadamard matrix exist?

Only for n = 1, 2 or a multiple of 4. It is conjectured, but not proved, that one exists for every multiple of 4 (SageMath documentation; Tao et al. optimization-problems page).

How do you test whether a matrix is Hadamard?

Check that all entries are ±1 and that H·Hᵀ equals n·Iₙ, or equivalently that |det H| = nn/2.

What is the smallest order that is still unresolved?

The Tao et al. page, citing the Cati and Pasechnik database, gives 668 as the smallest unresolved order. An August 2026 announcement reported by John D. Cook’s blog says a matrix of order 668 has since been found; no primary report was available to confirm it.

Is a Hadamard matrix the same as the Hadamard product?

No. The Hadamard product is element-wise multiplication of two matrices of the same size.

Sources

Data: Number of inequivalent Hadamard matrices known at the smallest orders

Count of Hadamard matrices up to equivalence (row/column permutations and sign changes) for each order up to 28, compiled from the Wikipedia Hadamard matrix article and cross-checked against the order conditions in the SageMath documentation.

Period covered: 2026.

Number of inequivalent Hadamard matrices known at the smallest orders
Order nInequivalent Hadamard matrices
11
21
41
81
121
165
203
2460
28487

Sources

Compiled by CASRAI from the sources above. Free to reuse under CC BY 4.0 with attribution.

Follow CASRAI

Research-administration guidance, standards updates and independent tool reviews.

Ask CASRAI · full access

Ask about Hadamard Matrices: Definition, Constructions and Open Orders

Full access: large monthly usage, up to 10 source passages behind each answer, and MCP and API access for Claude Code, Codex and other CLIs. Cancel any time.

An AI assistant for research: funder rules, compliance, methods and publishing. It links the sources behind its answers and labels answers that come from a web search.

Answers draw on CASRAI's guides and dictionary plus the federal and funder documents we index: Federal Register, Grants.gov, Regulations.gov and UKRI.

Works on this site and inside Claude, Cursor and the AI tools you already use.

Everything CASRAI publishes — this page, the dictionary, the guides and the news — stays open to read, with no account and no card.

Referenced across the research world

University of Cambridge logoColumbia University logoCrossref logoUniversity of Edinburgh logoHarvard University logoUniversity of Oxford logoPrinceton University logoStanford School of Medicine logoUniversity College London logoORCID logoUniversity of Cambridge logoColumbia University logoCrossref logoUniversity of Edinburgh logoHarvard University logoUniversity of Oxford logoPrinceton University logoStanford School of Medicine logoUniversity College London logoORCID logo
  • University of Cambridge logo
  • Columbia University logo
  • Crossref logo
  • University of Edinburgh logo
  • Harvard University logo
  • University of Oxford logo
  • Princeton University logo
  • Stanford School of Medicine logo
  • University College London logo
  • ORCID logo

View CASRAI adoption →