Given a finite set of quantum gates $\mathcal{G} = \{G_1, \dots, G_n\}$, is it decidable (in computation theoretic sense) whether $\mathcal{G}$ is a universal gate set? On one hand, "almost all" gate sets are universal, on the other, non-universal gate sets are still not well understood (in particular, of course, it is not known whether every non-universal gate set is classically simulatable), so I imagine giving an explicit algorithm for checking universality could be nontrivial.

  • 3
    $\begingroup$ Can you clarify the question? Joe's answer assumes you have a fixed number of qubits and all gates act on those, but for universality, we often assume gates can act on any subset of qubits. E.g., CNOT + all one-qubit gates are not universal if the one-qubit gates can only act on the first qubit, and CNOT is only from qubit 1 to qubit 2. In the latter case, we might want to extrapolate to many qubits to get universality. In that case, I think the anwer may be unknown. $\endgroup$
    – Daniel Gottesman
    Jan 23, 2012 at 15:30
  • $\begingroup$ @DanielGottesman: I agree about the limitations of my answer. Indeed, I believe it is undecidable in the latter case as follows: Take a cellular automata on an infinite lattice of qubits and use it to encode the halting problem (call this update unitary $U_1$). Then take a second lattice with a universal QCA (with update unitary $U_2$). We can define a new unitary $CU_2 = |0\rangle\langle0|_H\otimes I + |1\rangle\langle1|\otimes U_2$, where the subscript $H$ denotes a qubit which is set to $|1\rangle$ iff the first cellular automata halts. $\endgroup$ Jan 31, 2012 at 6:19
  • $\begingroup$ Thus the gate $CU_2 \times U_1$ is universal if and only if the first Turing machine halts, and is hence undecidable. $\endgroup$ Jan 31, 2012 at 6:22
  • 1
    $\begingroup$ I asked a related question on quantum computing stack exchange recently. quantumcomputing.stackexchange.com/questions/32408/… $\endgroup$
    – Callum
    Jun 4, 2023 at 22:14

1 Answer 1


For the case of Hamiltonians, rather than gates the answer is trivially yes: you simply enumerate the independent elements of the Lie algebra. Since the Lie algebra is a vector space with the addition of the Lie bracket operator. Since the space is finite, it has a finite basis, and which can easily be checked as to whether it is closed or open under the Lie bracket operation. Simply checking the Lie bracket of all pairs of orthogonal operators can be done in time polynomial in the dimensionality of the space, and a suitable operator basis can be found by the Gram-Schmidt method.

For gates, you don't really have the same option to resort to infinitesimals straight off, and need to construct gates with irrational eigenvalues so that you can arbitrarily well approximate the required infinitesimal generators. I guess that there is a relatively simple way to do this, but it is not immediately obvious to me.

In any case, taking the log of the gates to obtain a set of operators which generate them when exponentiated and checking whether these generated the full Lie algebra would provide a simple necessary but not sufficient criteria for universality.

  • $\begingroup$ Why we should check only pairs? $\endgroup$ Jan 20, 2012 at 20:40
  • $\begingroup$ @AlexV: Because the Lie bracket takes operates on 2 inputs. Every time you produce a new linearly independent operator you produce an orthogonal one and repeat until you get closure. $\endgroup$ Jan 21, 2012 at 2:41
  • $\begingroup$ I meant you should consider $[\ldots[H_k,H_j],H_l],\ldots]$, but not only pairs, e.g. see my own paper arxiv.org/abs/quant-ph/0010071 $\endgroup$ Jan 21, 2012 at 12:35
  • $\begingroup$ @AlexV: You don't need to. It's a vector space, so a vector is orthogonal to a given subspace if and only if it is orthogonal to any basis for that subspace. $\endgroup$ Jan 21, 2012 at 14:25
  • $\begingroup$ Likely we are talking about different things - which vector space you are talking about? You do not know from very beginning the subalgebra generated by your gates - you need to construct that from given Hamiltonians to check if it whole Lie algebra. $\endgroup$ Jan 21, 2012 at 15:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.