<p><strong>Short answer.</strong> It turns out that suspending the requirement of unitary transformations, and requiring each operation to be invertible, gives rise to exact gap-definable classes. The specific classes in question are $\mathsf{LWPP}$ and a 'new' subclass $\mathsf{LPWPP}$, both of which  sit between $\mathsf{SPP}$ and $\mathsf{C_=P}$. These classes have fairly technical definitions, which are briefly described below; though these definitions can now be substituted, in principle, with ones in terms of non-unitary "quantum-like" algorithms.</p>

<p>The counting class $\mathsf{SPP}$ contains GRAPH ISOMORPHISM. It also contains the entire class $\mathsf{UP}$, so we would not expect exact <em>unitary</em> quantum algorithms to be as powerful as the non-unitary classes (as we could otherwise show $\mathsf{NP \subseteq BQP}$).</p>

<p><strong>Longer answer.</strong></p>

<ul>
<li><p>In my question, I proposed redefining $\mathsf{EQP}$ to allow for problems which are solvable by uniform circuit families which use gates which are efficiently computable, but not necessarily drawn from a finite gate-set. I'm no longer so certain that it is a good idea to <em>redefine</em> $\mathsf{EQP}$ in this way, though I do believe such circuit families are worthwhile to study. We may call this class something like $\mathsf{UnitaryP_{\mathbb C}}$ instead.</p>

<p>It is possible to show that $\mathsf{UnitaryP_{\mathbb C} \subseteq
 LWPP}$, which until recently was the best known bound for
$\mathsf{EQP}$. The class $\mathsf{LWPP}$ more-or-less corresponds to problems for which there is a randomised algorithm, where NO instances produce an outcome of 1 with probability exactly 0.5, and YES instances produce an outcome of 1 with some probability which can be efficiently and exactly computed in rational form, which is greater than (but possibly exponentially close to) 0.5. The technical definition of $\mathsf{LWPP}$ is presented in terms of nondeterministic Turing machines, but is no more illuminating.</p>

<p>If we define $\mathsf{GLP}_{\mathbb C}$ to be the invertible-gate equivalent of $\mathsf{UnitaryP_{\mathbb C}}$, so that it is the set of problems which are exactly solvable by <em>invertible</em> circuit families with efficiently computable gate coefficients, then $\mathsf{GLP_{\mathbb C} = LWPP}$. </p></li>
<li><p>If we restrict to finite gate-sets, it is possible to show that unitary circuit families may be simulated in a subset of $\mathsf{LWPP}$, which we might call $\mathsf{LPWPP}$. (Using the description of $\mathsf{LWPP}$ above, this corresponds to randomised algorithms where the probability of obtaining an output of 1 for YES instances is exactly $m^{t(x)} / 2^{p(|x|)}$, for some polynomial $p$, some integer $m$, and some efficiently computable polynomial $t$.)</p>

<p>If we define $\mathsf{EQP_{\mathrm{GL}}}$ to be the invertible-gate
equivalent of $\mathsf{EQP}$ as it is normally defined, we may show
that $\mathsf{EQP_{\mathrm{GL}} \subseteq LPWPP}$.</p></li>
</ul>

<p><strong>A correction regarding DISCRETE LOG.</strong></p>

<p>The results above rely on standard techniques to represent algebraic coefficients, in a way which is independent of the input (but which may depend on input size). In the description of the original question, I claimed that [ <a href="http://arxiv.org/abs/quant-ph/0301093" rel="noreferrer">Mosca+Zalka 2003</a> ] show that DISCRETE LOG is exactly solvable by a gate-set with efficiently computable coefficients. The truth appears to be more complicated. If one cares about exact solvability, then I consider exact representation of the coefficients to be important: but Mosca and Zalka do not provide a way of doing this in an input-dependent way. So it is not obvious that DISCRETE LOG is in fact in $\mathsf{EQP}$ or in the new class $\mathsf{UnitaryP_{\mathbb C}}$.</p>

<p><strong>Reference.</strong></p>

<ul>
<li>de Beaudrap, <em>On exact counting and quasi-quantum complexity</em>, [<a href="http://www.arXiv.org/abs/1509.07789" rel="noreferrer">arXiv:1509.07789</a>].</li>
</ul>

CC BY-SA 3.0
2015-10-05T18:09:23.587Z
Very nice!!! A naive question: what is the power of circuits you described (arbitrary invertible; exact or approximate) when you consider sample complexity. (Namely the class of probability distributions they can give.)
Gil Kalai
CC BY-SA 3.0
2015-10-05T18:28:36.127Z
@GilKalai: If you don't impose any invariant on the distributions which these circuits compute (i.e. by having them preserve the 1-norm or the 2-norm), then one would have to define precisely how one would like to map the tensors which such circuits describe to probability distributions. If one imagines that these distributions are somehow secretly quantum states rather than pseudo-probability distributions, one might renormalise in the usual way that a physicist might choose to do, but this choice is not forced upon us.
Niel de Beaudrap
CC BY-SA 3.0
2015-10-05T18:30:38.640Z
Having said that: whatever constraint one imposes, I don't immediately know how I would go about answering the question. But from Aaronson's work on **PostBQP**, we know the approximate sampling class is at least **PP**-hard.
Niel de Beaudrap
CC BY-SA 3.0
2015-10-05T11:58:30.093Z
2015-10-05T15:27:45.420Z
2015-10-05T15:27:45.420Z
Niel de Beaudrap
<h2>Short Question.</h2>

<p>What is the computational power of "quantum" circuits, if we allow non-unitary (but still invertible) gates, and require the output to give the correct answer with certainty?</p>

<p>This question is in a sense about what happens to the class $\mathsf{EQP}$ when you allow the circuits to use more than just unitary gates. (We're still forced to restrict ourselves to invertible gates over $\mathbb C$ if we want to be able to have a well-defined model of computation.)</p>

<p>(This question has undergone some revisions in light of some confusion on my part about the known results about such circuits in the unitary case.)</p>

<h2>About "exact" quantum computation</h2>

<p>I define $\mathsf{EQP}$ for the sake of this question to be the class of problems which can be exactly solved by a uniform quantum circuit family, where the coefficients of each unitary is computable by polynomial-time-bounded Turing machines (from the input string $1^n$) for each input size $n$, and that the layout of the circuit as a directed network can also be produced in polynomial time. By "exactly" solved, I mean that measuring the output bit yields $|0\rangle$ with certainty for NO instances, and $|1\rangle$ with certainty for YES instances.</p>

<p><strong>Caveats:</strong></p>

<ul>
<li><p>Even restricting to unitary gates, this notion of $\mathsf{EQP}$ is different from that described by Bernstein and Vazirani using quantum Turing machines.
The definition above allows a circuit family $\{ C_n \}$ to in principle have an infinite gate set &mdash; each individual circuit $C_n$ only uses a finite subset, of course &mdash; because the gates are in effect computed from the inputs. (A quantum Turing machine can simulate any finite gate set that you like, but can only simulate finite gate sets, because it only has a finite number of transitions.)</p></li>
<li><p>This model of computation trivializes any problems in $\mathsf P$, because the unitary could contain a single gate which hard-codes the solution to any problem in $\mathsf P$ (its coefficients are after all determined by a poly-time computation). So the specific time- or space-complexity of problems are not necessarily interesting for such circuits.</p></li>
</ul>

<p>We can add to these caveats the observation that practical implementations of quantum computers will have noise anyway. <em>This model of computation is interesting primarily for theoretical reasons</em>, as one concerned with composing unitary transformations rather than feasible computation, and also as an exact version of $\mathsf{BQP}$. In particular, despite the caveats above, we have $\mathsf{P} \subseteq \mathsf{EQP} \subseteq \mathsf{BQP}$.</p>

<p>The reason for defining $\mathsf{EQP}$ in the way I do is so that DISCRETE-LOG can be put into $\mathsf{EQP}$.
By [&nbsp;<a href="http://arxiv.org/abs/quant-ph/0301093">Mosca+Zalka&nbsp;2003</a>&nbsp;], there is a polynomial-time algorithm to construct a unitary circuit which exactly solves instances of DISCRETE-LOG by producing exact versions of the QFT depending on the input modulus.
I believe that we can then put DISCRETE-LOG into $\mathsf{EQP}$, as defined above, by embedding the elements of circuit-construction into the way that the gate coefficients are computed. (So the result DISCRETE-LOG $\in \mathsf{EQP}$ essentially holds by fiat, but relying on the construction of Mosca+Zalka.)</p>

<h2>Suspending unitarity</h2>

<p>Let $\mathsf{EQP_{\mathrm{GL}}}$ be the computational class that we get if we suspend the restriction that gates be unitary, and allow them to range over invertible transformations. Can we place this class (or even characterize it) in terms of other traditional non-deterministic classes $\mathbf C$?</p>

<p>One of my reasons for asking: if $\mathsf{BQP}_{\mathrm{GL}}$ is the class of problems efficiently solvable with <em>bounded error</em>, by uniform "non-unitary quantum" circuit families &mdash; where YES instances give an output of $|1\rangle$ with probability at least 2/3, and NO instances with probability at most 1/3 (after normalizing the state-vector) &mdash; then <a href="http://rspa.royalsocietypublishing.org/content/461/2063/3473.full">[Aaronson 2005]</a> shows that $\mathsf{BQP}_{\mathrm{GL}} = \mathsf{PP}$.
That is: suspending unitarity is in this case equivalent to allowing unbounded error.</p>

<p>Does a similar result, or any clear result, obtain for $\mathsf{EQP_{\mathrm{GL}}}$?</p>

CC BY-SA 3.0
2014-03-31T18:58:40.177Z
Intuitively, I would guess ${\bf C}$ to be ${\bf CoC_=P}$.
Tayfun Pay
CC BY-SA 3.0
2014-03-31T19:51:26.613Z
It's not a bad guess, as $\mathsf {coC_=P = NQP}$ is the unbounded-(one-sided)-error version of $\mathsf {EQP}$ just as $\mathsf {PP}$ is the unbounded error version of $\mathsf{BQP}$; and $\mathsf{PP}$ contains both $\mathsf {C_=P}$ and its complement, on account of $\mathsf {PP}$ being closed under intersection and complements.
Niel de Beaudrap
CC BY-SA 3.0
2014-04-01T02:57:57.633Z
Is it obvious that NP is contained in this class? (And is this class the same as EQP with postselection?)
Robin Kothari
CC BY-SA 3.0
2014-04-01T09:38:08.097Z
@RobinKothari: I wouldn't consider either of these obvious, because of the zero-error condition. The second question seems more likely than the first. My agreement with Tayfun that $\mathsf{EQP_{\mathrm{GL}} = coC_=P}$ (...and therefore also $\mathsf{C_=P}$) is a reasonable guess is that if it's going to be any previously defined class at all, that one is a prime suspect, but obviously if true it wouldn't be a trivial observation.
Niel de Beaudrap
CC BY-SA 3.0
2014-04-01T11:24:57.683Z
Do you know any problem in this class that's not in P?
Robin Kothari
CC BY-SA 3.0
2014-04-01T19:30:43.853Z
I seem to recall Scott Aaronson talking about this question at some points, maybe in a survey paper or a long blog post. It might have been the same survey where he talks about writing quantum states as combinations with just real coefficients (both positive and negative), rather than complex coefficients.
greg
CC BY-SA 3.0
2014-04-02T05:35:38.353Z
@mobius: if you would find the link, that would be helpful. A [search for "EQP" in Shtetl Optimised](http://www.google.com/search?hl=en-GB&redir_esc=&v=133247963&qsubts=1396416479289&action=devloc&q=eqp+site%3Awww.scottaaronson.com%2Fblog&v=133247963) didn't turn it up.
Niel de Beaudrap
<complexity-classes><quantum-computing>
How powerful is exact "quantum" computing if you suspend unitarity?
Niel de Beaudrap
# How powerful is exact "quantum" computing if you suspend unitarity?

(Asked by: username_0 on 2014-03-31)

## Short Question.

What is the computational power of "quantum" circuits, if we allow non-unitary (but still invertible) gates, and require the output to give the correct answer with certainty?

This question is in a sense about what happens to the class $\mathsf{EQP}$ when you allow the circuits to use more than just unitary gates. (We're still forced to restrict ourselves to invertible gates over $\mathbb C$ if we want to be able to have a well-defined model of computation.)

(This question has undergone some revisions in light of some confusion on my part about the known results about such circuits in the unitary case.)

## About "exact" quantum computation

I define $\mathsf{EQP}$ for the sake of this question to be the class of problems which can be exactly solved by a uniform quantum circuit family, where the coefficients of each unitary is computable by polynomial-time-bounded Turing machines (from the input string $1^n$) for each input size $n$, and that the layout of the circuit as a directed network can also be produced in polynomial time. By "exactly" solved, I mean that measuring the output bit yields $|0\rangle$ with certainty for NO instances, and $|1\rangle$ with certainty for YES instances.

**Caveats:**

* Even restricting to unitary gates, this notion of $\mathsf{EQP}$ is different from that described by Bernstein and Vazirani using quantum Turing machines.
  The definition above allows a circuit family $\{ C\_n \}$ to in principle have an infinite gate set — each individual circuit $C\_n$ only uses a finite subset, of course — because the gates are in effect computed from the inputs. (A quantum Turing machine can simulate any finite gate set that you like, but can only simulate finite gate sets, because it only has a finite number of transitions.)
* This model of computation trivializes any problems in $\mathsf P$, because the unitary could contain a single gate which hard-codes the solution to any problem in $\mathsf P$ (its coefficients are after all determined by a poly-time computation). So the specific time- or space-complexity of problems are not necessarily interesting for such circuits.

We can add to these caveats the observation that practical implementations of quantum computers will have noise anyway. *This model of computation is interesting primarily for theoretical reasons*, as one concerned with composing unitary transformations rather than feasible computation, and also as an exact version of $\mathsf{BQP}$. In particular, despite the caveats above, we have $\mathsf{P} \subseteq \mathsf{EQP} \subseteq \mathsf{BQP}$.

The reason for defining $\mathsf{EQP}$ in the way I do is so that DISCRETE-LOG can be put into $\mathsf{EQP}$.
By [ [Mosca+Zalka 2003](http://arxiv.org/abs/quant-ph/0301093) ], there is a polynomial-time algorithm to construct a unitary circuit which exactly solves instances of DISCRETE-LOG by producing exact versions of the QFT depending on the input modulus.
I believe that we can then put DISCRETE-LOG into $\mathsf{EQP}$, as defined above, by embedding the elements of circuit-construction into the way that the gate coefficients are computed. (So the result DISCRETE-LOG $\in \mathsf{EQP}$ essentially holds by fiat, but relying on the construction of Mosca+Zalka.)

## Suspending unitarity

Let $\mathsf{EQP\_{\mathrm{GL}}}$ be the computational class that we get if we suspend the restriction that gates be unitary, and allow them to range over invertible transformations. Can we place this class (or even characterize it) in terms of other traditional non-deterministic classes $\mathbf C$?

One of my reasons for asking: if $\mathsf{BQP}\_{\mathrm{GL}}$ is the class of problems efficiently solvable with *bounded error*, by uniform "non-unitary quantum" circuit families — where YES instances give an output of $|1\rangle$ with probability at least 2/3, and NO instances with probability at most 1/3 (after normalizing the state-vector) — then [[Aaronson 2005]](http://rspa.royalsocietypublishing.org/content/461/2063/3473.full) shows that $\mathsf{BQP}\_{\mathrm{GL}} = \mathsf{PP}$.
That is: suspending unitarity is in this case equivalent to allowing unbounded error.

Does a similar result, or any clear result, obtain for $\mathsf{EQP\_{\mathrm{GL}}}$?

**Tags:** complexity-classes, quantum-computing

> **Comments:**
> **username_1**: Intuitively, I would guess ${\bf C}$ to be ${\bf CoC_=P}$.  
> **username_0**: It's not a bad guess, as $\mathsf {coC_=P = NQP}$ is the unbounded-(one-sided)-error version of $\mathsf {EQP}$ just as $\mathsf {PP}$ is the unbounded error version of $\mathsf{BQP}$; and $\mathsf{PP}$ contains both $\mathsf {C_=P}$ and its complement, on account of $\mathsf {PP}$ being closed under intersection and complements.  
> **username_2**: Is it obvious that NP is contained in this class? (And is this class the same as EQP with postselection?)  
> **username_0**: @RobinKothari: I wouldn't consider either of these obvious, because of the zero-error condition. The second question seems more likely than the first. My agreement with Tayfun that $\mathsf{EQP_{\mathrm{GL}} = coC_=P}$ (...and therefore also $\mathsf{C_=P}$) is a reasonable guess is that if it's going to be any previously defined class at all, that one is a prime suspect, but obviously if true it wouldn't be a trivial observation.  
> **username_2**: Do you know any problem in this class that's not in P?  
> **username_3**: I seem to recall Scott Aaronson talking about this question at some points, maybe in a survey paper or a long blog post. It might have been the same survey where he talks about writing quantum states as combinations with just real coefficients (both positive and negative), rather than complex coefficients.  
> **username_0**: @mobius: if you would find the link, that would be helpful. A [search for "EQP" in Shtetl Optimised](http://www.google.com/search?hl=en-GB&redir_esc=&v=133247963&qsubts=1396416479289&action=devloc&q=eqp+site%3Awww.scottaaronson.com%2Fblog&v=133247963) didn't turn it up.  

---

## 1 answers

### Answer by username_0 on 2015-10-05. Score: 8 | Accepted answer

**Short answer.** It turns out that suspending the requirement of unitary transformations, and requiring each operation to be invertible, gives rise to exact gap-definable classes. The specific classes in question are $\mathsf{LWPP}$ and a 'new' subclass $\mathsf{LPWPP}$, both of which sit between $\mathsf{SPP}$ and $\mathsf{C\_=P}$. These classes have fairly technical definitions, which are briefly described below; though these definitions can now be substituted, in principle, with ones in terms of non-unitary "quantum-like" algorithms.

The counting class $\mathsf{SPP}$ contains GRAPH ISOMORPHISM. It also contains the entire class $\mathsf{UP}$, so we would not expect exact *unitary* quantum algorithms to be as powerful as the non-unitary classes (as we could otherwise show $\mathsf{NP \subseteq BQP}$).

**Longer answer.**

* In my question, I proposed redefining $\mathsf{EQP}$ to allow for problems which are solvable by uniform circuit families which use gates which are efficiently computable, but not necessarily drawn from a finite gate-set. I'm no longer so certain that it is a good idea to *redefine* $\mathsf{EQP}$ in this way, though I do believe such circuit families are worthwhile to study. We may call this class something like $\mathsf{UnitaryP\_{\mathbb C}}$ instead.

  It is possible to show that $\mathsf{UnitaryP\_{\mathbb C} \subseteq
  LWPP}$, which until recently was the best known bound for
  $\mathsf{EQP}$. The class $\mathsf{LWPP}$ more-or-less corresponds to problems for which there is a randomised algorithm, where NO instances produce an outcome of 1 with probability exactly 0.5, and YES instances produce an outcome of 1 with some probability which can be efficiently and exactly computed in rational form, which is greater than (but possibly exponentially close to) 0.5. The technical definition of $\mathsf{LWPP}$ is presented in terms of nondeterministic Turing machines, but is no more illuminating.

  If we define $\mathsf{GLP}\_{\mathbb C}$ to be the invertible-gate equivalent of $\mathsf{UnitaryP\_{\mathbb C}}$, so that it is the set of problems which are exactly solvable by *invertible* circuit families with efficiently computable gate coefficients, then $\mathsf{GLP\_{\mathbb C} = LWPP}$.
* If we restrict to finite gate-sets, it is possible to show that unitary circuit families may be simulated in a subset of $\mathsf{LWPP}$, which we might call $\mathsf{LPWPP}$. (Using the description of $\mathsf{LWPP}$ above, this corresponds to randomised algorithms where the probability of obtaining an output of 1 for YES instances is exactly $m^{t(x)} / 2^{p(|x|)}$, for some polynomial $p$, some integer $m$, and some efficiently computable polynomial $t$.)

  If we define $\mathsf{EQP\_{\mathrm{GL}}}$ to be the invertible-gate
  equivalent of $\mathsf{EQP}$ as it is normally defined, we may show
  that $\mathsf{EQP\_{\mathrm{GL}} \subseteq LPWPP}$.

**A correction regarding DISCRETE LOG.**

The results above rely on standard techniques to represent algebraic coefficients, in a way which is independent of the input (but which may depend on input size). In the description of the original question, I claimed that [ [Mosca+Zalka 2003](http://arxiv.org/abs/quant-ph/0301093) ] show that DISCRETE LOG is exactly solvable by a gate-set with efficiently computable coefficients. The truth appears to be more complicated. If one cares about exact solvability, then I consider exact representation of the coefficients to be important: but Mosca and Zalka do not provide a way of doing this in an input-dependent way. So it is not obvious that DISCRETE LOG is in fact in $\mathsf{EQP}$ or in the new class $\mathsf{UnitaryP\_{\mathbb C}}$.

**Reference.**

* de Beaudrap, *On exact counting and quasi-quantum complexity*, [[arXiv:1509.07789](http://www.arXiv.org/abs/1509.07789)].

> **Comments:**
> **username_4**: Very nice!!! A naive question: what is the power of circuits you described (arbitrary invertible; exact or approximate) when you consider sample complexity. (Namely the class of probability distributions they can give.)  
> **username_0**: @GilKalai: If you don't impose any invariant on the distributions which these circuits compute (i.e. by having them preserve the 1-norm or the 2-norm), then one would have to define precisely how one would like to map the tensors which such circuits describe to probability distributions. If one imagines that these distributions are somehow secretly quantum states rather than pseudo-probability distributions, one might renormalise in the usual way that a physicist might choose to do, but this choice is not forced upon us.  
> **username_0**: Having said that: whatever constraint one imposes, I don't immediately know how I would go about answering the question. But from Aaronson's work on **PostBQP**, we know the approximate sampling class is at least **PP**-hard.  

---

