betaFeedback

WorksPhysics and Astronomy

Quantum Copy Complexity of Testing Monotonicity and Other Properties

Abstract

We study the sample complexity of testing monotonicity of Boolean functions when the tester is given only copies of the quantum function state ∣ψf⟩=12n∑x∈{0,1}n∣x,f(x)⟩|ψ_f\rangle=\frac{1}{\sqrt{2^n}}\sum_{x\in\{0,1\}^n}|x,f(x)\rangle. We give a tester with sample complexity O(min⁡{nε3,n3/2ε2})O\left(\min\left\{\frac{n}{\varepsilon^3}, \frac{n^{3/2}}{\varepsilon^2}\right\}\right), improving on the previous O~(n2/ε2)\widetilde O(n^2/\varepsilon^2) upper bound of [CNS26]. We also prove the first nontrivial lower bounds for monotonicity testing from quantum function states, matching our upper bounds over a broad range of ε\varepsilon. Our upper bounds use two approaches. The first approach refines the Fourier-based tester of [CNS26] by handling high-influence functions separately, adapting an idea from [KMS18]. The second approach uses the classical path tester of [KMS18] by constructing a quantum observable whose expectation equals the path tester's violation probability. To prove the lower bounds, we place independent functions in mutually incomparable regions of the Boolean hypercube, building on the classical constructions of [BB16, CWX17]. We introduce a new argument for the quantum setting that replaces a fixed number of copies with a Poisson-distributed number of copies, allowing the contributions from different regions to be analyzed independently. This same framework also allows us to prove an Ω(n2)Ω(n^2) lower bound for testing union-closedness and 22-monotonicity from quantum function states.

Introduction

In property testing, we study whether a small amount of information suffices to decide if an unknown object satisfies a property or is far from satisfying the property. More formally, given a collection P\mathcal{P} of Boolean functions and a parameter ε>0\varepsilon> 0, the goal is to distinguish between

f∈Panddist⁡(f,P)≥ε,f \in\mathcal{P} \qquad\text{and} \qquad\operatorname{dist}(f,\mathcal{P}) \ge\varepsilon,

promised that one of these is the case. Here,

dist⁡(f,P):=min⁡g∈Pdist⁡(f,g),dist⁡(f,g):=Pr⁡x∼Unif⁡({0,1}n)[f(x)≠g(x)].\operatorname{dist}(f,\mathcal{P}) := \min_{g \in\mathcal{P}} \operatorname{dist}(f,g), \qquad\operatorname{dist}(f,g) := \Pr_{x \sim\operatorname{Unif}(\{0,1\}^{n})}[f(x) \ne g(x)].

Monotonicity testing on the Boolean hypercube has served as a canonical example for property testing algorithms, both in the classical and quantum setting. For example, see [15, 13, 16, 4, 7, 10]. A Boolean function f:{0,1}n→{0,1}f : \{0,1\}^{n} \to\{0,1\} is monotone if

f(x)≤f(y)whenever x⪯y,f(x) \le f(y) \qquad\text{whenever } x \preceq y,

where x⪯yx \preceq y denotes the coordinate-wise order: xi≤yix_i \le y_i for every i∈[n]i \in[n]. The goal is to determine whether a function that is far from monotone can be detected given only limited access to the function.

The answer depends on how the tester is able to access our function ff. In the classical query model, a tester is able to choose any input and observe its function value while in the classical sample-based model, a tester receives random labeled examples (x,f(x))(x,f(x)) (often drawn uniformly). In the quantum query model, the tester can apply the oracle ∣x,b⟩↦∣x,b⊕f(x)⟩|x,b\rangle\mapsto|x,b \oplus f(x)\rangle to any state coherently. In this paper, we study the quantum sample-based setting, where the tester receives copies of the uniform quantum state

∣ψf⟩=2−n/2∑x∈{0,1}n∣x,f(x)⟩.(1)|\psi_f\rangle= 2^{-n/2}\sum_{x \in\{0,1\}^{n}} |x,f(x)\rangle. \tag*{(1)}

The tester may perform arbitrary measurements on multiple copies of this state. Our goal is to minimize the number of copies needed to test any property.

Quantum states of the form ∑xD(x)∣x,f(x)⟩\sum_x \sqrt{D(x)}|x,f(x)\rangle were first studied in the context of PAC learning in [6]. The state in Equation (1) corresponds to taking DD to be uniform. Quantum examples and related models have since been studied in both learning and property testing [2, 3, 11, 1]. Most closely related to our work is that of [10] who give a monotonicity tester that uses O~(n2/ε2)\widetilde{O}(n^2/\varepsilon^2) copies. The authors also show that for monotonicity, the hard distributions used for classical lower bounds can be distinguished using only a few quantum function states, yielding a trivial lower bound of Ω(1/ε)\Omega(1/\varepsilon) copies. In this work, we close this gap by giving matching upper and lower bounds for monotonicity testing in the quantum sample model. Table 1 places our bounds alongside the best known results in other access models.

Access modelUpper boundsLower bounds
Classical samples2Ω~(n/ε)2^{\widetilde{\mathit{\Omega}}(\sqrt{n}/\varepsilon)} [8, 7]2Ω(n/ε)2^{\Omega(\sqrt{n}/\varepsilon)} [7]
Classical queriesO~(nε2)\widetilde{O}\left(\frac{\sqrt{n}}{\varepsilon^2}\right) [16]Ω(n1/2−η)\Omega(n^{1/2-\eta}) for any fixed η>0\eta> 0 [9]
Quantum queriesO~(n1/4ε)\widetilde{O}\left(\frac{n^{1/4}}{\sqrt{\varepsilon}}\right) [4]—
Quantum examplesO(min⁡{nε3,n3/2ε2})O\left(\min\left\{\frac{n}{\varepsilon^3},\frac{n^{3/2}}{\varepsilon^2}\right\}\right) (this work)Ω(min⁡{nε3,n3/2ε2})\Omega\left(\min\left\{\frac{n}{\varepsilon^3},\frac{n^{3/2}}{\varepsilon^2}\right\}\right) (this work)

Table 1. Bounds for monotonicity testing across different access models. Our lower bound holds for 2−n/200≤ε≤1/1282^{-\sqrt{n}/200} \le\varepsilon\le1/128.

Our results

The following statements summarize the results proved in this paper.

Theorem 1 (Upper bound). For every n≥1n \ge1, 0<ε≤1/20 < \varepsilon\le1/2, and 0<δ<1/20 < \delta< 1/2, there exists a quantum algorithm that uses at most

O(min⁡{n3/2ε2,nε3}log⁡1δ)O\left(\min\left\{\frac{n^{3/2}}{\varepsilon^2},\frac{n}{\varepsilon^3}\right\}\log\frac{1}{\delta}\right)

copies of the state ∣ψf⟩|\psi_f\rangle to decide, with success probability at least 1−δ1-\delta, whether ff is monotone or ε\varepsilon-far from monotone.

Theorem 2 (Lower bound). For 2−n/200≤ε≤1/1282^{-\sqrt{n}/200} \le\varepsilon\le1/128, any quantum algorithm requires

Ω(min⁡{nε3,n3/2ε2})\Omega\left(\min\left\{\frac{n}{\varepsilon^3},\frac{n^{3/2}}{\varepsilon^2}\right\}\right)

copies of ∣ψf⟩|\psi_f\rangle to decide, with success probability at least 2/32/3, whether ff is monotone or ε\varepsilon-far from monotone.

The lower-bound construction can also be applied to at least two other Boolean properties. In particular, a function is union-closed if f(x)=f(y)=1f(x)=f(y)=1 implies f(x∨y)=1f(x\lor y)=1, where x∨yx\lor y denotes coordinate-wise OR. Furthermore, a function is 2-monotone if there do not exist x≺y≺zx\prec y\prec z such that f(x)=1f(x)=1, f(y)=0f(y)=0, and f(z)=1f(z)=1 where x≺yx\prec y refers to coordinate-wise order. We show that the following lower bounds apply.

Theorem 3 (Additional lower bounds). For every 0<ε≤1/2560 < \varepsilon\le1/256, any quantum algorithm requires Ω(n2)\Omega(n^2) copies of the state ∣ψf⟩|\psi_f\rangle to decide, with success probability at least 2/32/3, whether ff is union-closed or ε\varepsilon-far from union-closed. The same holds for testing 2-monotonicity.

Overview of our proofs

Upper bounds. We prove our upper bound using two separate testers.

Our first tester improves on the quantum version of the classical edge tester. The classical edge tester of [15] samples a uniformly random edge (x,y)(x,y) of the Boolean hypercube and checks whether it is violated. A monotone function has no violated edges, while a function that is ε\varepsilon-far from monotone has a nontrivial probability of violated edges. [10] estimate this probability using copies of the quantum function state. Specifically, the probability that a random edge of the Boolean hypercube violates monotonicity can be written using the total influence of the function as well as the first-level Fourier coefficients. The influence can be estimated using Fourier sampling while the first-level coefficients can be estimated from measurements in the computational basis.

Our improvement is to first filter functions that have large influence. This idea appears in the classical query-based monotonicity tester of [16]. Since every monotone function has influence at most n\sqrt{n}, we can first do a coarse estimate to reject functions that have influence much larger than this. In the low-influence regime, the estimator for the influence has lower variance which improves the quantum copy complexity.

Our second tester is based on the classical path tester of [16]. While the edge tester only looks at neighboring endpoints of the hypercube, the path tester looks at comparable points farther away. The classical path tester samples a starting point and moves either upward or downward along a random set of coordinates and then checks whether the two endpoints form a violation.

Since we cannot query function values, we construct quantum observables whose expectations reproduce the violation probability of the classical path tester for a specific path length. We estimate these quantities at several path lengths. The structural results of [16], together with the stronger directed isoperimetric inequality of [18], guarantee that some scale has enough violations whenever the function is far from monotone. The stronger inequality is primarily used to eliminate a logarithmic factor in the final bound. Furthermore, as in the Fourier tester, we do a coarse estimate to eliminate functions with high influence, allowing the relevant estimators to have small variance. This gives a tester that uses O(n/ε3)O(n/\varepsilon^3) copies.

These two testers together establish the upper bound in Theorem 1.

Lower bounds. For the lower bound, we construct two distributions over Boolean functions: one supported on monotone functions and one supported on functions that are ε\varepsilon-far from monotone with high probability. We then show that the corresponding averaged tt-copy states are difficult to distinguish, even using arbitrary measurements on all copies by bounding the trace distance.

The construction is based on ideas from classical monotonicity lower bounds [5, 12]. We select many small, pairwise incomparable regions of the hypercube and place an independent local function in each region. Outside of these regions, we assign function values that preserve monotonicity whenever the local functions are monotone. Because no point in one region is comparable to a point in another, the monotonicity behavior of different regions do not interfere. The global function is built out of many independent local pieces.

Next, within each region, we choose a smaller band where the local function can vary. Restricting the construction to this band lets us control how much each function contributes to the global distance from monotonicity. Outside of the band, all of the local functions are identical. Inside the band, we use dictators and constant functions for the monotone case. In the far from monotone case, we use reversed dictators to create violations. The width of the band determines how large the local contribution to the distance can be, while the probability of choosing a reversed dictator determines how often such violations occur. By tuning these two parameters, we make the global function ε\varepsilon-far from monotone with high probability.

The main difficulty now is to show that the two distributions remain hard to distinguish when the tester receives copies of the quantum function states. Let Dyes\mathcal{D}_{\mathrm{yes}} and Dno\mathcal{D}_{\mathrm{no}} denote the two distributions. We want to bound

TD⁡(Ef∼Dyes[(∣ψf⟩⟨ψf∣)⊗t],Ef∼Dno[(∣ψf⟩⟨ψf∣)⊗t]).\operatorname{TD}\left(\mathbb{E}_{f\sim\mathcal{D}_{\mathrm{yes}}}\left[\left(|\psi_f\rangle\langle\psi_f|\right)^{\otimes t}\right],\mathbb{E}_{f\sim\mathcal{D}_{\mathrm{no}}}\left[\left(|\psi_f\rangle\langle\psi_f|\right)^{\otimes t}\right]\right).

Classically, the independence between the different regions can be used directly. In the quantum setting, however, the global tt-copy state does not factor across the regions. To overcome this, we introduce an auxiliary state that is a coherent superposition over different copy numbers, with weights corresponding to a Poisson distribution. In this representation, overlaps between global states factor across the regions. This allows us to analyze each region separately and then combine the resulting bounds. Finally, we transfer the bound back to the original setting with a fixed number of copies.

We consider two ranges of ε\varepsilon. When n−1/2≤ε≤1/128n^{-1/2} \le\varepsilon\le1/128, we choose the band inside each region to have mass Θ(ε)\Theta(\varepsilon), which gives an Ω(n/ε3)\Omega(n/\varepsilon^3) lower bound. When 2−n/200≤ε<n−1/22^{-\sqrt{n}/200} \le\varepsilon< n^{-1/2}, we instead keep the band at mass Θ(n−1/2)\Theta(n^{-1/2}) and reduce the probability of choosing a reversed dictator. This gives an Ω(n3/2/ε2)\Omega(n^{3/2}/\varepsilon^2) lower bound. Together, the two regimes match our upper bounds over the stated range of ε\varepsilon.

Other properties. The same lower bound framework can also be applied to union-closedness and 2-monotonicity. In particular, we can keep the same incomparable regions and reuse the quantum indistinguishability argument. However, we replace dictators and the reversed dictators by XOR and XNOR functions on pairs of coordinates. This gives the Ω(n2)\Omega(n^2) copy lower bounds for both properties.

Preliminaries

Notation and distance. We write [n]:={1,…,n}[n] := \{1,\ldots,n\} and N:=2nN := 2^n. Furthermore, unless stated otherwise, all Boolean functions take values in {0,1}\{0,1\} and probabilities and expectations over {0,1}n\{0,1\}^n are computed over the uniform distribution. For x∈{0,1}nx \in\{0,1\}^n, we write ∣x∣:=∑i=1nxi|x| := \sum_{i=1}^{n} x_i for its Hamming weight.

We write x⪯yx \preceq y if xi≤yix_i \le y_i for every i∈[n]i \in[n], and denote by MON⁡n\operatorname{MON}_n the collection of Boolean functions satisfying f(x)≤f(y)f(x) \le f(y) whenever x⪯yx \preceq y. For any comparable pair, we call xx the lower endpoint and yy the upper endpoint. A pair is a violation if f(x)=1f(x)=1 and f(y)=0f(y)=0. Furthermore, it is a violated edge if the endpoints specifically differ in exactly one coordinate.

Quantum examples and copy complexity. For a Boolean function ff, let ∣ψf⟩|\psi_f\rangle be the function state in Equation (1). We use the terms quantum function state, quantum example, and quantum copy interchangeably. A tester receiving tt copies may perform an arbitrary joint measurement on ∣ψf⟩⊗t|\psi_f\rangle^{\otimes t}.

References

  1. [1]Srinivasan Arunachalam, Sergey Bravyi, Arkopal Dutt, and Theodore J. Yoder. “Optimal Algorithms for Learning Quantum Phase States”. In: 18th Conference on the Theory of Quantum Computation, Communication and Cryptography (TQC 2023). Ed. by Omar Fawzi and Michael Walter. Vol. 266. Leibniz International Proceedings in Informatics (LIPIcs). Dagstuhl, Germany: Schloss Dagstuhl – Leibniz-Zentrum für Informatik, 2023, 3:1–3:24. ISBN: 978-3-95977-283-9. DOI: 10.4230/LIPIcs.TQC.2023.3. URL: https://drops.dagstuhl.de/entities/document/10.4230/LIPIcs.TQC.2023.3.DOI
  2. [2]Alp Atıcı and Rocco A Servedio. “Quantum algorithms for learning and testing juntas”. In: Quantum Information Processing 6.5 (2007), pp. 323–348. DOI: 10.1007/s11128-007-0061-6.DOI
  3. [3]Srinivasan Arunachalam and Ronald de Wolf. “Optimal Quantum Sample Complexity of Learning Algorithms”. In: Journal of Machine Learning Research 19.71 (2018), pp. 1–36. URL: https://www.jmlr.org/papers/v19/18-195.html.
  4. [4]Aleksandrs Belovs and Eric Blais. “Quantum Algorithm for Monotonicity Testing on the Hypercube”. In: Theory of Computing 11.16 (2015), pp. 403–412. ISSN: 1557-2862. DOI: 10.4086/toc.2015.v011a016. URL: http://dx.doi.org/10.4086/toc.2015.v011a016.
  5. [5]Aleksandrs Belovs and Eric Blais. “A Polynomial Lower Bound for Testing Monotonicity”. In: Proceedings of the 48th Annual ACM Symposium on Theory of Computing (STOC 2016). Association for Computing Machinery, 2016, pp. 1021–1032. DOI: 10.1145/2897518.2897567. arXiv: 1511.05053. URL: https://arxiv.org/abs/1511.05053.
  6. [6]Nader H. Bshouty and Jeffrey C. Jackson. “Learning DNF over the uniform distribution using a quantum example oracle”. In: Proceedings of the eighth annual conference on Computational learning theory. 1995, pp. 118–127. DOI: 10.1145/225298.225312.DOI
  7. [7]Hadley Black. “Nearly Optimal Bounds for Sample-Based Testing and Learning of k-Monotone Functions”. In: Approximation, Randomization, and Combinatorial Optimization. Algorithms and Techniques (APPROX/RANDOM 2024). Ed. by Amit Kumar and Noga Ron-Zewi. Vol. 317. Leibniz International Proceedings in Informatics (LIPIcs). Dagstuhl, Germany: Schloss Dagstuhl – Leibniz-Zentrum für Informatik, 2024, 37:1–37:23. ISBN: 978-3-95977-348-5. DOI: 10.4230/LIPIcs.APPROX/RANDOM.2024.37. URL: https://drops.dagstuhl.de/entities/document/10.4230/LIPIcs.APPROX/RANDOM.2024.37.DOI
  8. [8]Nader H. Bshouty and Christino Tamon. “On the Fourier Spectrum of Monotone Functions”. In: Journal of the ACM 43.4 (1996), pp. 747–770. DOI: 10.1145/234533.234564. URL: https://doi.org/10.1145/234533.234564.
  9. [9]Mark Chen, Xi Chen, Hao Cui, William Pires, and Jonah Stockwell. “Boolean Function Monotonicity Testing Requires (Almost) n^{1/2} Queries”. In: Proceedings of the 58th Annual ACM Symposium on Theory of Computing (STOC 2026). Association for Computing Machinery, 2026, pp. 584–594. DOI: 10.1145/3798129.3800775. URL: https://doi.org/10.1145/3798129.3800775.
  10. [10]Matthias C. Caro, Preksha Naik, and Joseph Slote. “Testing Classical Properties from Quantum Data”. In: ITCS. 2026, 34:1–34:26. DOI: 10.4230/LIPIcs.ITCS.2026.34.
  11. [11]Andrew W. Cross, Graeme Smith, and John A. Smolin. “Quantum Learning Robust against Noise”. In: Physical Review A 92.1 (2015), p. 012327. DOI: 10.1103/PhysRevA.92.012327. arXiv: 1407.5088. URL: https://doi.org/10.1103/PhysRevA.92.012327.
  12. [12]Xi Chen, Erik Waingarten, and Jinyu Xie. “Beyond Talagrand Functions: New Lower Bounds for Testing Monotonicity and Unateness”. In: Proceedings of the 49th Annual ACM SIGACT Symposium on Theory of Computing (STOC 2017). Association for Computing Machinery, 2017, pp. 523–536. DOI: 10.1145/3055399.3055461. arXiv: 1702.06997. URL: https://arxiv.org/abs/1702.06997.
  13. [13]Eldar Fischer, Eric Lehman, Ilan Newman, Sofya Raskhodnikova, Ronitt Rubinfeld, and Alex Samorodnitsky. “Monotonicity Testing over General Poset Domains”. In: Proceedings of the 34th Annual ACM Symposium on Theory of Computing (STOC 2002). Association for Computing Machinery, 2002, pp. 474–483. DOI: 10.1145/509907.509977. URL: https://people.csail.mit.edu/sofya/2cnf.pdf.DOI
  14. [14]Christopher A Fuchs and Jeroen Van De Graaf. “Cryptographic distinguishability measures for quantum-mechanical states”. In: IEEE Transactions on Information Theory 45.4 (1999), pp. 1216–1227. DOI: 10.1109/18.761271.
  15. [15]Oded Goldreich, Shafi Goldwasser, Eric Lehman, Dana Ron, and Alex Samorodnitsky. “Testing Monotonicity”. In: Combinatorica 20.3 (Mar. 2000), pp. 301–337. ISSN: 1439-6912. DOI: 10.1007/s004930070011. URL: https://doi.org/10.1007/s004930070011.
  16. [16]Subhash Khot, Dor Minzer, and Muli Safra. “On Monotonicity Testing and Boolean Isoperimetric-type Theorems”. In: SIAM J. Comput. 47.6 (2018), pp. 2238–2276. DOI: 10.1137/16M1065872. URL: https://doi.org/10.1137/16M1065872.
  17. [17]Ryan O’Donnell. Analysis of Boolean Functions. 2021. arXiv: 2105.10386 [cs. DM]. URL: https://arxiv.org/abs/2105.10386.
  18. [18]Ramesh Krishnan S. Pallavoor, Sofya Raskhodnikova, and Erik Waingarten. “Approximating the Distance to Monotonicity of Boolean Functions”. In: Random Structures & Algorithms 60.2 (2022), pp. 233–260. DOI: 10.1002/rsa.21029. arXiv: 1911.06924. URL: https://arxiv.org/abs/1911.06924.
  19. [19]John Watrous. The Theory of Quantum Information. Cambridge University Press, 2018. URL: https://cs.uwaterloo.ca/~watrous/TQI/.DOI

Paper details

vlnc:W_4q8at5q2
Version
v1 · latest
Published
Fresh — added to the Hub within the last 30 days
Added
License
CC BY 4.0
Usage

views · 3

downloads · 0

A view counts once per browser per day, a download each time the PDF is requested.

  • Physics and Astronomy

Not recorded for this paper

View statement
Looking for related papers…
Contents