potentialpaper

Walking the Hypercube: Unbiased Quantum Partition Functions Without the Matrix

Kumar Avinava Dubey, Arijit Sehanobish, Krzysztof Marcin Choromanski

NeurIPS 2026

Edit this page

Or clone it with git

Run in a terminal:

Needs Git LFS. To push, use an API key from your profile as the password.

Or let your agent set it up

It checks and sets up everything: signing in, git, the clone, credentials and an SSH key.

TL;DR. We present a novel method for computing the trace of the partition functions of Ising systems without ever materializing the Hamiltonian.

Abstract. Computing the partition function Z=tr(e−βH)\mathcal{Z} = \mathrm{tr}(e^{-\beta H}) of a quantum spin Hamiltonian HH on nn sites is a fundamental problem in statistical physics and quantum chemistry. However exact evaluation requires O(8n)O(8^n) time and O(4n)O(4^n) memory making it intractable for all but the smallest systems. We propose an unbiased stochastic estimator of Z\mathcal{Z}, and more generally of tr(f(H))\mathrm{tr}(f(H)) for any function ff admitting a convergent power series over exponentially large, implicitly defined operators using only local random walks, avoiding both matrix materialization and matrix-vector products. Our approach combines Graph Random Features with the Hutchinson's stochastic trace estimator, and exploits the algebraic structure of quantum spin Hamiltonians to reduce the per-step computational cost to O(n+d)O(n + d), where dd is the mean degree of the spin coupling graph, independent of the Hilbert space dimension N=2nN = 2^n. We validate the estimator empirically against exact matrix exponentiation for small system sizes, and demonstrate its applicability to system sizes where exact methods are infeasible.

Are you an author? Claim this paper to see who's reading it, with views and other statistics, and to write about it here.

Claim this paper
How does this paper connect to your work? Write how you built on it, compared with it or reproduced it, or add a summary, a critique or errata.
Or make it interactive:
Start writing

edit · history

DateVersionSubmitted toPDFEvidence
1 May 2026NeurIPS 2026submittedNeurIPS 2026Accept (poster)reviews ↓[1]PDF[1]
Missing a version?

NeurIPS 2026

Accept (poster) · 3 reviews · OpenReview

Updated 25 Nov 2026, 03:49 UTC.

Program Chairs · DecisionOpenReview ↗
Decision
Accept (poster)
Read decision
Meta-review

This paper proposes an unbiased stochastic estimator for quantum partition functions without explicit Hamiltonian materialization. Reviewers agree that the problem is important, the approach is novel, and the theoretical contribution is strong.

The main concerns are:

(0) Limited discussion around the sign problem is undoubtedly the main problem in stochastic estimators for quantum partition functions. (1) sample complexity and variance scaling. (2) scalability beyond the validated regime. (3) clarification of several technical details.

Addressing these points would further strengthen an already promising submission.

Final justification

I have read the authors’ response and the subsequent reviewer discussion.

The rebuttal substantially addressed the main concerns raised in the initial reviews and meta-review. In particular, the authors provided an end-to-end sample-complexity bound, clarified the memory/time tradeoff and underlying computational hardness, added experiments characterizing variance and sign behavior and extended tests to larger sizes.

The main limitation is the sign problem: variance becomes severe at low temperatures, and accuracy at large system sizes in frustrated regimes remains less thoroughly validated. The authors are now explicit about this fundamental limitation.

Following the rebuttal and discussion, overall, I believe the novelty and technical contribution outweigh the remaining limitations, and I recommend acceptance.

Area Chair f7Jp · Meta-reviewOpenReview ↗
Read meta-review
Meta-review

This paper proposes an unbiased stochastic estimator for quantum partition functions without explicit Hamiltonian materialization. Reviewers agree that the problem is important, the approach is novel, and the theoretical contribution is strong.

The main concerns are:

(0) Limited discussion around the sign problem is undoubtedly the main problem in stochastic estimators for quantum partition functions. (1) sample complexity and variance scaling. (2) scalability beyond the validated regime. (3) clarification of several technical details.

Addressing these points would further strengthen an already promising submission.

Final justification

I have read the authors’ response and the subsequent reviewer discussion.

The rebuttal substantially addressed the main concerns raised in the initial reviews and meta-review. In particular, the authors provided an end-to-end sample-complexity bound, clarified the memory/time tradeoff and underlying computational hardness, added experiments characterizing variance and sign behavior and extended tests to larger sizes.

The main limitation is the sign problem: variance becomes severe at low temperatures, and accuracy at large system sizes in frustrated regimes remains less thoroughly validated. The authors are now explicit about this fundamental limitation.

Following the rebuttal and discussion, overall, I believe the novelty and technical contribution outweigh the remaining limitations, and I recommend acceptance.

Reviewer 87rWOpenReview ↗
Rating
4/6
Confidence
3/5
Quality
3/4
Clarity
3/4
Significance
3/4
Originality
3/4
Contribution type
general
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

This paper tackles the problem of computing the partition function (more generally tr(f(H))\mathrm{tr}(f(H)), where ff admitting a convergent power series), of a quantum spin Hamiltonian HH on nn sites, a quantity that encodes a system's properties but whose exact evaluation requires O(4n)O(4^n) memory and O(8n)O(8^n) time, making it intractable beyond very small systems. The authors propose the Hypercube Walk Estimator (HWE), an unbiased stochastic estimator that combines graph random features with Hutchinson's trace estimator to estimate the trace using only local random walks, while never materializing the matrix. The core insight is that the off diagonal part of the Hamiltonian induces a structured hypercube, while the diagonal terms are maintained through incremental local updates and therefore reducing the per-step cost to O(n+d)O(n+d) (where dd is the mean degree of the spin coupling graph), independent of the Hilbert space dimension N=2nN = 2^n. They provide a proof that the estimator is exactly unbiased and adapt it to three Hamiltonian classes of physical interest: (1) the transverse-field Ising model, (2) the Sherrington-Kirkpatrick spin glass and (3) the XXZ model. HWE maintains a bounded memory and accuracy (n the validated nn that were checked) where exact matrix methods run out of memory.

Strengths and weaknesses

Strengths:

  • Reducing the memory footprint from an exponential O(4n)O(4^n) to a bounded O(n)O(n)

  • HWE has exact unbiasedness, without introducing truncation or Trotter approximation errors

  • Dropping the per step computation cost to O(n+d)O(n+d) instead of materializing a giant matrix

Weaknesses:

  • The underlying problem is #P-hard, the number of samples required to control the estimator's noise can still scale exponentially with the system size (in the worst case scenarios)

  • In near zero temperatures, the random walks encounter rapid sign alterations causing the estimator's variance to explode

  • The accuracy was not checked past n=14n=14

Questions
  1. You describe the method as parallelizable but ran all experiments on a single CPU. Did you actually run any parallel experiments? and if so, how much faster does it get?
  2. You mention that you trade space complexity for sampling. What is the price of this trade off? How much sampling that trade actually costs as n grows?
  3. You show the method runs with low memory up to n=20n=20 (Figure 2), but the empirical error comparisons stop at n=14n=14 (Figures 1,3,4). How do you know the estimate is still accurate at n>14n>14 ?
Limitations

Yes

Final justification

Parallelism and sample complexity concerns were resolved, and the novel, unbiased, memory efficient contribution outweighs remaining gaps.

Formatting concerns

No

5 comments
Authors · RebuttalOpenReview ↗
Rebuttal

We thank the reviewer for the thoughtful feedback and for recognizing that our method successfully reduces the memory footprint to O(n)O(n) while maintaining exact unbiasedness.

The underlying problem is #P-hard, the number of samples required to control the estimator's noise can still scale exponentially with the system size (in the worst case scenarios)

Calculating the partition function for these general, frustrated Hamiltonians is indeed inherently #P-hard; no algorithm can guarantee polynomial time to a fixed accuracy. Our new theorem explicitly reflects this fundamental limit, proving an exponential sample complexity scaling of exp⁡(O(βnd))\exp(O(\beta nd)).

Let HH be an nn-spin Hamiltonian with maximum degree dd, and let W≤ndW \leq nd be the maximum absolute row sum of HH. To estimate Z=tr(e−βH)Z = \mathrm{tr}(e^{-\beta H}) to within relative error ϵ\epsilon with probability ≥1−δ\geq 1 - \delta, the number of samples MM satisfies:

M≤1ϵ2δ p2exp⁡ ⁣(C βnd1−p),C=2(1+1−p)M \leq \frac{1}{\epsilon^2 \delta\, p^2} \exp\!\left(\frac{C\,\beta n d}{\sqrt{1-p}}\right), \quad C = 2\bigl(1 + \sqrt{1-p}\bigr)

Proof sketch. We split e−βH=(e−βH/2)2e^{-\beta H} = (e^{-\beta H/2})^2 and generate two independent random walks from the same starting node, each producing a one-hot random feature vector for g(H)=e−βH/2g(H) = e^{-\beta H/2}. The second moment of a single walk's importance weight is bounded by noting that the ratio ∣H(u,v)∣/t(u,v)|H(u,v)|/t(u,v) at each step simplifies to the row sum ∑v∣H(u,v)∣≤W\sum_v |H(u,v)| \leq W. Averaging over the geometric walk length yields a series that evaluates to the modified Bessel function I0(βW/1−p)∼exp⁡(βW/1−p)I_0(\beta W/\sqrt{1-p}) \sim \exp(\beta W/\sqrt{1-p}). The key cancellation occurs when forming the relative error bound via Chebyshev's inequality: the N2N^2 factor from the variance of the NN-scaled estimator cancels exactly with the N2N^2 from the partition function lower bound Z≥Ne−βWZ \geq N e^{-\beta W} (Gershgorin), eliminating the Hilbert space dimension entirely.

However, our core contribution is not breaking #P-hardness, but rather relocating the exponential bottleneck. Exact methods fail due to an insurmountable memory limit: they require O(4n)O(4^n) continuous memory. Our HWE method strictly bounds memory to O(n2)O(n^2) for dense couplings and O(nd)O(nd) for sparse couplings, completely eliminating the memory wall.

You describe the method as parallelizable but ran all experiments on a single CPU. Did you actually run any parallel experiments? and if so, how much faster does it get?

Thanks for pointing this out. We have significantly expanded the experiments section to demonstrate this capability. Because each Hutchinson sample is independent, the algorithm achieves near-linear speedup (25.1×25.1\times on 32 workers), demonstrating that the time bottleneck can be effectively mitigated with standard parallel compute.

Parallel Speedup (n=14n=14, 1 to 32 workers)

Workers Relative Speedup Rel Diff in Z^\hat{Z} Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2
1 1.00$\times$ — 7×10−67 \times 10^{-6}
2 1.89$\times$ -0.45% 1.5×10−51.5 \times 10^{-5}
4 3.62$\times$ -0.98% 1.5×10−51.5 \times 10^{-5}
8 7.78$\times$ +1.90% 1.5×10−51.5 \times 10^{-5}
16 13.72$\times$ -0.16% 1.5×10−51.5 \times 10^{-5}
32 25.12$\times$ -0.16% 1.5×10−51.5 \times 10^{-5}

We trade that space bottleneck for a time bottleneck which, crucially, is embarrassingly parallel. By eliminating the memory barrier, our method allows us to scale to system sizes completely unreachable by exact methods and leverage parallel compute to manage the variance. To demonstrate this trade-off in practice, we successfully scaled HWE to n=50n=50 (representing a massive 250≈10152^{50} \approx 10^{15} dimensional Hilbert space).

Large-nn Scaling (TFIM on 64 cores)

nn Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2 Avg Wall Time
20 2.0×10−52.0 \times 10^{-5} 371.5s
30 4.8×10−54.8 \times 10^{-5} 467.8s
40 2.7×10−42.7 \times 10^{-4} 483.3s
50 5.8×10−35.8 \times 10^{-3} 508.8s

In near zero temperatures, the random walks encounter rapid sign alterations causing the estimator's variance to explode

Thank you for suggesting we show how sign alterations affect variance. The effective sign does indeed decay severely at higher β\beta (low temperatures), which is the standard manifestation of the sign problem. However, at moderate temperatures, the effective sign decays gracefully and does not collapse with nn.

Effective Sign vs. Inverse Temperature (β\beta) (system size n=10n=10)

β\beta Frustrated TFIM XXZ Model
0.1 0.837 0.839
0.2 0.725 0.746
0.3 0.649 0.708
0.5 0.561 0.729
0.7 0.523 0.738
1.0 0.508 0.542
1.5 0.551 0.134
2.0 0.620 0.048

Effective Sign vs. System Size (nn) (β=0.2\beta=0.2)

nn Frustrated TFIM XXZ Model
4 0.810 1.596
6 0.775 0.770
8 0.747 0.898
10 0.725 0.746
14 0.693 1.080
20 0.658 0.625

You show the method runs with low memory up to n=14. But the empirical error comparisons stop at n=14.

To evaluate the accuracy of our model for much larger nn (up to n=50n=50, representing a 2502^{50} space), we designed the M_only experiment. This evaluates a structurally biased estimator, Z^M=tr(e−βM)\hat{Z}_M = \text{tr}(e^{-\beta M}), which isolates the off-diagonal transverse field (MM) by completely ignoring the diagonal Ising couplings (DD) of the full Hamiltonian.

By removing the diagonal terms—which typically introduce sign cancellations and larger importance weights—this estimator establishes a variance lower bound, reflecting the baseline noise of the underlying random walk and Hutchinson machinery alone. We measure its relative error against the exact diagonalization of MM alongside its relative variance, proving the core algorithmic machinery remains highly accurate and stable at extreme scales.

M_only — tr(e−βM)\text{tr}(e^{-\beta M}), β=0.4\beta=0.4, 64 workers

nn Rel Error Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2
4 1.42% 1×10−61 \times 10^{-6}
8 4.43% 1×10−61 \times 10^{-6}
10 5.40% 1×10−61 \times 10^{-6}
14 5.44% 3×10−63 \times 10^{-6}
20 5.82% 3×10−63 \times 10^{-6}
30 6.87% 1.1×10−51.1 \times 10^{-5}
40 6.19% 3.1×10−53.1 \times 10^{-5}
50 6.79% 4.3×10−44.3 \times 10^{-4}

You mention that you trade space complexity for sampling. What is the price of this trade off? How much sampling that trade actually costs as n grows?

The price of trading O(N)/O(N2)O(N)/O(N^2) memory for a walk-based Monte Carlo estimator is increased sampling variance, and hence more samples (NHutch,Nsources,NwalksN_{\text{Hutch}}, N_{\text{sources}}, N_{\text{walks}}) needed to reach a fixed target accuracy. Quantitatively, required sample count scales as ∼1/⟨sign⟩2\sim 1/\langle\text{sign}\rangle^2, where ⟨sign⟩\langle\text{sign}\rangle is the effective-sign metric. In the moderate-temperature regime we benchmarked (see response above), this cost grows mildly / sub-exponentially with nn. At low temperature (large β\beta), the cost grows sharply which is consistent with the standard sign problem in Monte Carlo methods generally and is not specific to the space/time savings of our walk construction; this is a fundamental limitation shared by all sign-problem-affected stochastic trace estimators, not an artifact we introduced. We view this as an honest characterization of the tradeoff's boundary rather than a limitation we can eliminate: the method is most advantageous in the regime (moderate β\beta, larger nn) where memory savings are needed most and the variance cost remains controlled.

Reviewer 87rW · CommentOpenReview ↗

Response to the authors

I thank the authors for the substantial new experiments, which seem to address several concerns well. Two concerns remain regarding the sign behavior and the large nn accuracy validation:

  1. How was the effective sign computed? The table reports 1.596 at n=4n=4 and 1.080 at n=14n=14 for the XXZ model. Could you define the metric used here and explain the values above 1?

  2. The M_only estimator Z^M=tr(e−βM)\hat{Z}_M = \mathrm{tr}(e^{-\beta M}) removes the diagonal DD, which as you note, is precisely what introduces the sign cancellations and larger importance weights. Do you have any check that the full estimate (not just the underlying machinery) is accurate for n>14n > 14?

Authors · CommentOpenReview ↗

Thank you for engaging with us.

  1. How was the effective sign computed? The table reports 1.596 at n=4n=4 and 1.080 at n=14n=14 for the XXZ model. Could you define the metric used here and explain the values above 1?
⟨sign⟩=Zˉ[signed]Zˉ[unsigned]\langle \text{sign} \rangle = \frac{\bar{Z}[\text{signed}]}{\bar{Z}[\text{unsigned}]}

where both estimates use the same GRF machinery (Hutchinson probes, random walks, source sampling). Zˉ[signed]\bar{Z}[\text{signed}] uses the actual importance weights w[i]w[i] (which can be negative for off-diagonal Hamiltonian terms). Zˉ[unsigned]\bar{Z}[\text{unsigned}] replaces w[i]→∣w[i]∣w[i] \to |w[i]| in the importance ratio while keeping all other components identical. Both quantities are averaged over 500 independent seeds.

Why values above 1 are possible. In path-integral QMC, each sampled configuration contributes to a single sum: Z=∑σ[c]∣w[c]∣Z = \sum \sigma[c] |w[c]|, and the unsigned version Z[+]=∑∣w[c]∣Z[+] = \sum |w[c]| satisfies Z[+]≥∣Z∣Z[+] \geq |Z| term by term. This guarantees ∣⟨sign⟩∣≤1|\langle\text{sign}\rangle| \leq 1.

The GRF estimator has a fundamentally different structure. Each estimate is a product of two walk sums:

Z^∝sum[A]×sum[B],wheresum[A]=∑z(x[k])⋅w[1]⋯w[k]m[1]⋯m[k]⋅(−β)kk!\hat{Z} \propto \text{sum}[A] \times \text{sum}[B], \quad \text{where} \quad \text{sum}[A] = \sum z(x[k]) \cdot \frac{w[1] \cdots w[k]}{m[1] \cdots m[k]} \cdot \frac{(-\beta)^k}{k!}

Each term carries three independent sign sources: (i) the importance weights w[i]w[i], (ii) the Taylor coefficients (−β)k/k!(-\beta)^k/k! which alternate in sign, and (iii) the Rademacher hash z(x[k])∈{−1,+1}z(x[k]) \in \{-1,+1\}. Crucially, even when all weights are made positive (the unsigned variant), sum[A]\text{sum}[A] can still be negative due to sources (ii) and (iii). Removing the weight signs changes the cancellation pattern among all three sources, and can reduce the magnitude of the unsigned sum[A]\text{sum}[A] relative to the signed sum[A]\text{sum}[A] when the signed weights happen to align constructively with the Taylor and Rademacher signs. Since the final estimate is a product of two such sums, the term-by-term ordering guarantee of QMC does not hold, and Zˉ[signed]/Zˉ[unsigned]>1\bar{Z}[\text{signed}] / \bar{Z}[\text{unsigned}] > 1 is possible.

Updated results (500 trials). We reran the XXZ experiments with 500 independent seeds (up from 50) to confirm that the values above 1 are systematic, not finite-sample artifacts:

β\beta-sweep (n=10n=10):

β\beta Effective Sign Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2
0.1 0.839 3.1×10⁻⁶
0.2 0.746 1.4×10⁻⁵
0.3 0.707 3.7×10⁻⁵
0.5 0.729 2.2×10⁻⁴
0.7 0.745 3.8×10⁻³
1.0 0.613 3.3×10⁻¹
1.5 0.517 1.4×10²
2.0 1.155 4.2×10²

nn-sweep (β=0.2\beta=0.2):

nn Effective Sign Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2
4 1.597 5.4×10⁻⁶
6 0.770 9.0×10⁻⁶
8 0.899 1.2×10⁻⁵
10 0.746 1.5×10⁻⁵
14 1.080 2.6×10⁻⁵
20 0.624 6.5×10⁻⁵

The effective sign, as defined above, is an imperfect diagnostic for GRF because the signed and unsigned estimators compute different mathematical quantities, unlike in QMC where they share a common set of sampled configurations. The relative variance Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2 directly measures estimator quality without requiring an unsigned reference: when it is ≪1\ll 1 the estimate is precise, when ≫1\gg 1 it is dominated by noise. The nn-sweep shows that Var/Z^2\text{Var}/\hat{Z}^2 grows only mildly from 5×10−65 \times 10^{-6} to 6.5×10−56.5 \times 10^{-5} over n=4n = 4 to 2020.

  1. The M-only estimator Z^[M]=tr(e−βM)\hat{Z}[M] = \text{tr}(e^{-\beta M}) removes the diagonal DD, which as you note, is precisely what introduces the sign cancellations and larger importance weights. Do you have any check that the full estimate (not just the underlying machinery) is accurate for n>14n > 14?

To validate the GRF estimator at system sizes beyond the n≤14n \le 14 limit of exact diagonalization, we employ the Jordan-Wigner (JW) transformation, which maps the 1D transverse-field Ising model to a system of free fermions, yielding the exact partition function in O(n3)O(n^3) time. This mapping is specific to one-dimensional models with nearest-neighbor couplings and no frustration, it does not apply to the SK model, the XXZ chain, frustrated lattices, or systems in two or more dimensions, all of which the GRF estimator handles without modification. Using JW as an oracle, we compare GRF estimates for n=14,16,18,20n = 14, 16, 18, 20. At β=0.4\beta = 0.4, the average increase in error is from 2.5% for n=14n = 14 to 10.25% for n=20n = 20.

Reviewer 1h6wOpenReview ↗
Rating
5/6
Confidence
3/5
Quality
4/4
Clarity
3/4
Significance
4/4
Originality
3/4
Contribution type
general
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

A method to calculate tr(f(H)) for various discrete systems (spin models). The focus is particularly on the important cases of TFIM, SK and XXZ. The method combines graph random features (GRF) and the Hutchinson trace estimator - crucially it is never necessary to materialize the Laplacian.

Strengths and weaknesses

The paper is well motivated (the problem is tackles is obviously important), and seems to offer a genuinely novel and creative approach. I am not an expert in the field, but my sense is that this is impressive work. The experimental work seems to suggest that the method is competitive. I thought that the baselines were reasonably chosen.

It is also nice that the authors show that walks beyond a hypercube graph walk work with the method, as for the XXZ model.

I would have liked a little more time spent on making the technical ideas clear. In particular, I struggled a little with getting an intuition or section 3.1.

It's probably worth emphasizing in the abstract and intro that this is a method for spin models (i.e. discrete variables), not general problems of the form tr(e^{\beta H}).

Questions

Section E mentions a reasonable concern for the method, namely a sign problem that requires, in the worst case, exponential scaling of the number of walks with system size. As I understand, the experiments tackle relatively small system sizes. Is there a regime of larger systems where another method, in particular QMC, would work but HWE does not for reasons of variance? Are the system sizes shown here useful in practice? (I suspect yes, but might be useful to state for someone outside the field)

Unbiasedness of GRF: you state this as a proposition. Is it known from the literature, obvious, or you proved it? I was unclear.

Limitations

yes

Final justification

Following clarifications about the sign problem and the applicability of the method, I am happy to maintain my score, and would advocate to accept the paper.

Formatting concerns

none

1 comment
Authors · RebuttalOpenReview ↗
Rebuttal

We thank the reviewer for the positive assessment and thoughtful questions.

Section E mentions a reasonable concern for the method, namely a sign problem that requires, in the worst case, exponential scaling of the number of walks with system size. As I understand, the experiments tackle relatively small system sizes. Is there a regime of larger systems where another method, in particular QMC, would work but HWE does not for reasons of variance? Are the system sizes shown here useful in practice?

For unfrustrated (stoquastic) systems, QMC does not have to deal with the sign problem and is highly scalable. However, QMC fundamentally breaks down in frustrated systems (such as the SK model). QMC avoids the exponential variance bottleneck of the "sign problem" under a few specific, basis-dependent conditions. It works inherently for "stoquastic" Hamiltonians, where off-diagonal matrix elements are non-positive in the computational basis; this ensures −H-H has non-negative off-diagonals, allowing path-integral weights to act as true probabilities (Bravyi et al., 2008). For unfrustrated models, like bipartite lattices, the Marshall-Peierls rule guarantees non-negative amplitudes (Marshall, 1955; Lieb & Mattis, 1962). In fermionic systems, determinant QMC can operate sign-problem-free when physical symmetries (such as time-reversal) ensure the fermion determinant remains strictly positive (Blankenbecler et al., 1981; Wu & Zhang, 2005). Because the sign problem is basis-dependent, non-stoquastic systems can sometimes be solved if mathematically transformed into a sign-problem-free basis (Hangleiter et al., 2020). However, universally curing the sign problem by finding such a basis is QMA-complete, and perfectly solving it for general frustrated or fermionic systems remains NP-hard (Troyer & Wiese, 2005; Marvian et al., 2019). Our experiments show that HWE has relatively small variance at moderate temperatures even for much higher nn.

Calculating the partition function for these general, frustrated Hamiltonians is inherently #P-hard, no algorithm can guarantee polynomial time to a fixed accuracy. Our new theorem explicitly reflects this fundamental computational limit (see theorem below), proving an exponential sample complexity scaling of exp⁡(O(βnd))\exp(O(\beta nd)).

However, our core contribution is not breaking #P-hardness, but rather relocating the exponential bottleneck. Exact methods fail due to a memory limit: they require O(4n)O(4^n) continuous memory. Our HWE method strictly bounds memory to O(n2)O(n^2) for dense couplings and O(nd)O(nd) for sparse couplings, completely eliminating the memory limit.

We trade that space bottleneck for a time bottleneck which, crucially, is embarrassingly parallel. By eliminating the memory barrier, our method allows us to scale to system sizes completely unreachable by exact methods and leverage parallel compute to manage the variance. We have substantially expanded our evaluation to demonstrate this:

Large-nn Scaling (TFIM on 64 cores) We successfully scaled HWE to n=50n=50 (representing a 250≈10152^{50} \approx 10^{15} dimensional Hilbert space).

nn Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2 Avg Wall Time
20 2.0×10−52.0 \times 10^{-5} 371.5s
30 4.8×10−54.8 \times 10^{-5} 467.8s
40 2.7×10−42.7 \times 10^{-4} 483.3s
50 5.8×10−35.8 \times 10^{-3} 508.8s

Parallel Speedup (n=14n=14, 1 to 32 workers) Because each Hutchinson sample is independent, the algorithm achieves near-linear speedup (25.1×25.1\times on 32 workers), demonstrating that the time bottleneck can be effectively mitigated with standard parallel compute.

Workers Relative Speedup Rel Diff in Z^\hat{Z} Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2
1 1.00$\times$ — 7×10−67 \times 10^{-6}
2 1.89$\times$ -0.45% 1.5×10−51.5 \times 10^{-5}
4 3.62$\times$ -0.98% 1.5×10−51.5 \times 10^{-5}
8 7.78$\times$ +1.90% 1.5×10−51.5 \times 10^{-5}
16 13.72$\times$ -0.16% 1.5×10−51.5 \times 10^{-5}
32 25.12$\times$ -0.16% 1.5×10−51.5 \times 10^{-5}

We furthermore show how the sign error changes as a function of β\beta and nn. The effective sign decays severely at higher β\beta (low temperatures), which is the standard manifestation of the sign problem. However, at moderate temperatures (β=0.2\beta=0.2), the effective sign decays gracefully and does not collapse with nn.

Effective Sign vs. Inverse Temperature (β\beta) (system size n=10n=10)

β\beta Frustrated TFIM XXZ Model
0.1 0.837 0.839
0.2 0.725 0.746
0.3 0.649 0.708
0.5 0.561 0.729
0.7 0.523 0.738
1.0 0.508 0.542
1.5 0.551 0.134
2.0 0.620 0.048

Effective Sign vs. System Size (nn) (β=0.2\beta=0.2)

nn Frustrated TFIM XXZ Model
4 0.810 1.596
6 0.775 0.770
8 0.747 0.898
10 0.725 0.746
14 0.693 1.080
20 0.658 0.625

Unbiasedness of GRF: you state this as a proposition. Is it known from the literature, obvious, or you proved it? I was unclear.

We apologize for the lack of clarity. Proposition 3.1 (the unbiasedness of the standard GRF method) is known from the literature, established by Choromanski (2023). We will revise the text to make this attribution explicit. Our novel mathematical contribution is Theorem 3.2, which proves the unbiasedness of our combined Two-Walk GRF-Hutchinson estimator.

In addition, we provide a novel sample complexity bound. Let HH be an nn-spin Hamiltonian with maximum degree dd, and let W≤ndW \leq nd be the maximum absolute row sum of HH. To estimate Z=tr(e−βH)Z = \mathrm{tr}(e^{-\beta H}) to within relative error ϵ\epsilon with probability ≥1−δ\geq 1 - \delta, the number of samples MM satisfies:

M≤1ϵ2δ p2exp⁡ ⁣(C βnd1−p),C=2(1+1−p)M \leq \frac{1}{\epsilon^2 \delta\, p^2} \exp\!\left(\frac{C\,\beta n d}{\sqrt{1-p}}\right), \quad C = 2\bigl(1 + \sqrt{1-p}\bigr)

Proof sketch. We split e−βH=(e−βH/2)2e^{-\beta H} = (e^{-\beta H/2})^2 and generate two independent random walks from the same starting node, each producing a one-hot random feature vector for g(H)=e−βH/2g(H) = e^{-\beta H/2}. The second moment of a single walk's importance weight is bounded by noting that the ratio ∣H(u,v)∣/t(u,v)|H(u,v)|/t(u,v) at each step simplifies to the row sum ∑v∣H(u,v)∣≤W\sum_v |H(u,v)| \leq W. Averaging over the geometric walk length yields a series that evaluates to the modified Bessel function I0(βW/1−p)∼exp⁡(βW/1−p)I_0(\beta W/\sqrt{1-p}) \sim \exp(\beta W/\sqrt{1-p}). The key cancellation occurs when forming the relative error bound via Chebyshev's inequality: the N2N^2 factor from the variance of the NN-scaled estimator cancels exactly with the N2N^2 from the partition function lower bound Z≥Ne−βWZ \geq N e^{-\beta W} (Gershgorin), eliminating the Hilbert space dimension entirely.

I would have liked a little more time spent on making the technical ideas clear. In particular, I struggled a little with getting an intuition or section 3.1.

We will add a brief, intuitive summary at the start of Section 3.1: Instead of attempting to compute the exponentially large matrix exponential explicitly, we combine two stochastic techniques. First, Hutchinson's trace estimator lets us project the trace computation onto random probe vectors. Second, GRF allows us to estimate the result of this matrix-vector projection purely by simulating local random walks on the hypercube. Because the walk only needs to know its immediate neighbors to proceed, we completely bypass materializing the Hamiltonian matrix.

That particular construction, involving random walks, is a natural application of the mechanism of Graph Random Features (GRFs), that are constructed via random walks. Random walkers deposit values in the visited nodes of the graph, with the deposited values defined as functions of the current lengths of the walks (the exact formula depends on the particular form of the graph kernel that the GRF mechanism is used to estimate). One of the key insights is that matrices of interest for the quantum systems under consideration here can be equivalently represented as kernel matrices for certain graph kernels. That observation provides a direct link between the setup considered in this paper and the mechanism of GRFs, effectively constituting the cornerstone of the paper. We will clarify it in the camera-ready version.

It's probably worth emphasizing in the abstract and intro that this is a method for spin models (i.e. discrete variables), not general problems of the form tr(eβH)\mathrm{tr}(e^{\beta H})

Thanks for pointing this out. We will modify the abstract and introduction to explicitly state that our method is designed for discrete-variable quantum spin models.

References:

  • Blankenbecler, R., Scalapino, D. J., & Sugar, R. L. (1981). Monte Carlo calculations of coupled boson-fermion systems. I. Physical Review D, 24(8), 2278.
  • Bravyi, S., DiVincenzo, D. P., Oliveira, R., & Terhal, B. M. (2008). The complexity of stoquastic local Hamiltonian problems. Quantum Information and Computation, 8(5), 361-385.
  • Hangleiter, D., Roth, I., Nagaj, D., & Eisert, J. (2020). Easing the Monte Carlo sign problem. Science Advances, 6(33), eabb8341.
  • Lieb, E., & Mattis, D. (1962). Ordering energy levels of interacting spin systems. Journal of Mathematical Physics, 3(4), 749-751.
  • Marshall, W. (1955). Antiferromagnetism. Proceedings of the Royal Society of London. Series A. Mathematical and Physical Sciences, 232(1188), 48-68.
  • Marvian, M., Lidar, D. A., & Hen, I. (2019). On the computational complexity of curing the sign problem. Nature Communications, 10(1), 1571.
  • Troyer, M., & Wiese, U. J. (2005). Computational complexity and fundamental limitations to fermionic quantum Monte Carlo simulations. Physical Review Letters, 94(17), 170201.
  • Wu, C., & Zhang, S. C. (2005). Sufficient condition for absence of the sign problem in the fermionic quantum Monte Carlo algorithm. Physical Review B, 71(15), 155115.
Reviewer KZPGOpenReview ↗
Rating
4/6
Confidence
3/5
Quality
3/4
Clarity
3/4
Significance
3/4
Originality
3/4
Contribution type
general
Ethical concerns
NO or VERY MINOR ethics concerns only
Read review
Summary

This paper try to estimating quantum partition functions without explicitly forming the exponentially large Hamiltonian. For an nn-spin system, the Hilbert space dimension is N=2nN=2^n, so explicit matrix methods require exponential memory and time. The paper directly focuses on avoiding this matrix-materialization barrier. The authors propose a method combining Graph Random Features with the Hutchinson’s stochastic trace estimator.

Strengths and weaknesses

Strengths:

  1. It is interesting to combining Graph Random Features with Hutchinson trace estimation.
  2. The paper has a clear theoretical guarantee.
  3. The paper compares against exact diagonalization, mean-field theory, QMC, and high-temperature series expansions across TFIM, SK, and XXZ models.

Weakness:

  1. The paper does not show that the number of samples needed for a reliable relative-error estimate is polynomial in nn.
    1. There is no theorem connecting MM, RR, and SS to (n,β,ϵ,δ)(n,\beta,\epsilon,\delta), and the variance experiments cover only n∈{6,8,10,12}n\in \{6,8,10,12\}.
  2. J∈Rn×nJ\in\mathbb{R}^{n\times n} total memory is O(n2)O(n^2), not strictly O(n)O(n)
  3. The method does not solve the sign problem. not report the average sign, or separate sign-induced variance from source-sampling and Hutchinson variance.
  4. The paper’s pseudocode uses zx(s)z_x^{(s)} but does not clearly specify this implementation.
  5. The experimental evidence is also limited. Memory is shown up to n=20n=20. The only wall-clock comparison is at n=14n=14, where HWE already require 49mins. The variance ablation is restricted to n≤12n\leq12.
Questions
  1. What is the end-to-end sample complexity for a fixed relative-error estimate of Z=tr⁡(e−βH)Z=\operatorname{tr}(e^{-\beta H})?
  2. For the frustrated and XXZ cases, what is the measured average sign or sign-induced relative variance, and does it decay exponentially in nn or β\beta?
  3. Your estimator is unbiased and memory efficient, but can you demonstrate polynomial time to fixed accuracy?
  4. how does Var⁡(Z^)/Z2\operatorname{Var}(\widehat Z)/Z^2 scale with nn, β\beta, and the sign structure of the Hamiltonian?
Limitations

Yes

Final justification

The detailed rebuttal and additional experiments resolve most of my concerns.

Formatting concerns

N/A

5 comments
Authors · RebuttalOpenReview ↗
Rebuttal

We thank the reviewer for the detailed and constructive feedback. We address each point below.

Q1: What is the end-to-end sample complexity for a fixed relative-error estimate of ZZ?

We provide a new sample complexity bound for a variant of our algorithm where the two independent random walks drop their weight at the last node when there is a collision. Let HH be an nn-spin Hamiltonian with maximum degree dd, and let W≤ndW \leq nd be the maximum absolute row sum of HH. To estimate Z=tr(e−βH)Z = \mathrm{tr}(e^{-\beta H}) to within relative error ϵ\epsilon with probability ≥1−δ\geq 1 - \delta, the number of samples MM satisfies:

M≤1ϵ2δ p2exp⁡ ⁣(C βnd1−p),C=2(1+1−p)M \leq \frac{1}{\epsilon^2 \delta\, p^2} \exp\!\left(\frac{C\,\beta n d}{\sqrt{1-p}}\right), \quad C = 2\bigl(1 + \sqrt{1-p}\bigr)

Proof sketch. We split e−βH=(e−βH/2)2e^{-\beta H} = (e^{-\beta H/2})^2 and generate two independent random walks from the same starting node, each producing a one-hot random feature vector for g(H)=e−βH/2g(H) = e^{-\beta H/2}. The second moment of a single walk's importance weight is bounded by noting that the ratio ∣H(u,v)∣/t(u,v)|H(u,v)| / t(u,v) at each step simplifies to the row sum ∑v∣H(u,v)∣≤W\sum_v |H(u,v)| \leq W. Averaging over the geometric walk length yields a series that evaluates to the modified Bessel function I0(βW/1−p)∼exp⁡(βW/1−p)I_0(\beta W / \sqrt{1-p}) \sim \exp(\beta W / \sqrt{1-p}). The key cancellation occurs when forming the relative error bound via Chebyshev's inequality: the N2N^2 factor from the variance of the NN-scaled estimator cancels exactly with the N2N^2 from the partition function lower bound Z≥Ne−βWZ \geq N e^{-\beta W} (Gershgorin), eliminating the Hilbert space dimension entirely.

Q2: For the frustrated and XXZ cases, what is the measured average sign, and does it decay exponentially in nn or β\beta?

Effective Sign vs. Inverse Temperature (β\beta) (system size n=10n=10)

β\beta Frustrated TFIM XXZ Model
0.1 0.837 0.839
0.2 0.725 0.746
0.3 0.649 0.708
0.5 0.561 0.729
0.7 0.523 0.738
1.0 0.508 0.542
1.5 0.551 0.134
2.0 0.620 0.048

Effective Sign vs. System Size (nn) (β=0.2\beta=0.2)

nn Frustrated TFIM XXZ Model
4 0.810 1.596
6 0.775 0.770
8 0.747 0.898
10 0.725 0.746
14 0.693 1.080
20 0.658 0.625

The effective sign decays severely at higher β\beta (low temperatures), which is the standard manifestation of the sign problem. However, at moderate temperatures, the effective sign decays gracefully and does not collapse with nn.

Q3: Can you demonstrate polynomial time to fixed accuracy?

Calculating the partition function for general frustrated Hamiltonians is #P-hard in the worst case; no algorithm guarantees polynomial time to a fixed accuracy. Our new theorem reflects this, proving an exponential sample complexity of exp⁡(O(βnd))\exp(O(\beta nd)). However, our contribution is relocating the exponential bottleneck. Exact methods fail due to the memory limit (O(4n)O(4^n) continuous memory). HWE bounds memory to O(n2)O(n^2) (dense) or O(nd)O(nd) (sparse), eliminating the memory wall. We trade this space bottleneck for a time bottleneck that is embarrassingly parallel, allowing us to scale to system sizes unreachable by exact methods. We expanded our evaluation to demonstrate this:

Large-nn Scaling (TFIM on 64 cores) We successfully scaled HWE to n=50n=50 (representing a 250≈10152^{50} \approx 10^{15} dimensional Hilbert space).

nn Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2 Avg Wall Time Peak Memory
20 2.0×10−52.0 \times 10^{-5} 371.5s 625.4 MB
30 4.8×10−54.8 \times 10^{-5} 467.8s 623.1 MB
40 2.7×10−42.7 \times 10^{-4} 483.3s 623.3 MB
50 5.8×10−35.8 \times 10^{-3} 508.8s 620.7 MB

Parallel Speedup (n=14n=14, 1 to 32 workers): Because each Hutchinson sample is independent, the algorithm achieves near-linear speedup (25.1×25.1\times on 32 workers), demonstrating that the time bottleneck can be effectively mitigated with standard parallel compute.

Workers Relative Speedup Rel Diff in Z^\hat{Z} Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2
1 1.00$\times$ — 7×10−67 \times 10^{-6}
2 1.89$\times$ -0.45% 1.5×10−51.5 \times 10^{-5}
4 3.62$\times$ -0.98% 1.5×10−51.5 \times 10^{-5}
8 7.78$\times$ +1.90% 1.5×10−51.5 \times 10^{-5}
16 13.72$\times$ -0.16% 1.5×10−51.5 \times 10^{-5}
32 25.12$\times$ -0.16% 1.5×10−51.5 \times 10^{-5}

Q4: How does Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2 scale with n,βn, \beta, and the sign structure of the Hamiltonian?

To explicitly address how the relative variance scales across these parameters, we evaluated Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2 for both the frustrated TFIM and XXZ models, sweeping over inverse temperature (β\beta) and system size (nn).

Relative Variance vs. Inverse Temperature (β\beta) (Conducted at fixed system size n=10n=10)

β\beta Frustrated TFIM XXZ Model
0.1 1.4×10−61.4 \times 10^{-6} 1.6×10−61.6 \times 10^{-6}
0.2 6.6×10−66.6 \times 10^{-6} 7.1×10−67.1 \times 10^{-6}
0.3 2.7×10−52.7 \times 10^{-5} 2.3×10−52.3 \times 10^{-5}
0.5 3.4×10−43.4 \times 10^{-4} 1.8×10−41.8 \times 10^{-4}
0.7 2.3×10−32.3 \times 10^{-3} 2.8×10−32.8 \times 10^{-3}
1.0 1.3×10−21.3 \times 10^{-2} 0.020.02
1.5 0.750.75 14.614.6
2.0 21.521.5 64.664.6

For the frustrated TFIM, the relative variance grows exponentially in β\beta but remains highly manageable up to β≈1.0\beta \approx 1.0. The XXZ model exhibits a sharper sign problem at low temperatures.

Relative Variance Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2 vs. System Size (nn) (Conducted at fixed inverse temperature β=0.4\beta=0.4)

nn Frustrated TFIM XXZ Model
4 1.0×10−41.0 \times 10^{-4} 4.8×10−54.8 \times 10^{-5}
6 1.9×10−41.9 \times 10^{-4} 9.9×10−59.9 \times 10^{-5}
8 9.6×10−59.6 \times 10^{-5} 8.0×10−58.0 \times 10^{-5}
10 7.5×10−67.5 \times 10^{-6} 7.8×10−57.8 \times 10^{-5}
14 8.6×10−68.6 \times 10^{-6} 2.9×10−42.9 \times 10^{-4}
20 1.8×10−51.8 \times 10^{-5} 4.8×10−44.8 \times 10^{-4}

At a moderate temperature (β=0.4\beta=0.4), both models demonstrate excellent stability across system sizes.

Variance Ablation

The HWE estimator has three nested stochastic layers:

  • Source sampling: Uniformly sample root spin configurations from 2n2^n states.
  • Hutchinson probes: Rademacher vectors to estimate the matrix trace.
  • Random walks: Graph random features to estimate matrix elements.

To isolate each component's contribution to total variance, we run 50 independent trials per condition using seed freezing: fix two RNG sources, let the third vary. The variance across trials isolates that component. We then report each as a percentage of the sum of parts: Walk%=Vwalk/(Vwalk+Vhutch+Vsource)\text{Walk\%} = V_{\text{walk}} / (V_{\text{walk}} + V_{\text{hutch}} + V_{\text{source}}).

Model: Sherrington-Kirkpatrick (fully connected random Jij∼N(0,1/n)J_{ij} \sim \mathcal{N}(0, 1/n)), n=12n=12, h=0.3h=0.3, 64 workers.

β\beta Walk Hutchinson Source Var(Z^)/Z^2\text{Var}(\hat{Z})/\hat{Z}^2
0.2 0.9% 0.0% 99.1% 1.1×10−51.1 \times 10^{-5}
0.4 11.1% 0.0% 88.9% 4.6×10−54.6 \times 10^{-5}
1.0 39.2% 0.0% 60.8% 6.4×10−36.4 \times 10^{-3}

Notation zx(s)z^{(s)}_x in the pseudocode of the algorithm

z(s)z^{(s)} is a Rademacher vector drawn for each probe ss, and zx(s)z^{(s)}_x is the xx-th entry of the vector. In practice we never materialize z(s)z^{(s)} as an array. Instead, each entry zx(s)z^{(s)}_x is generated on demand via a deterministic pseudo-random hash of the pair (x,s)(x, s): node index xx is combined with the Hutchinson sample index ss through a fixed bit-mixing hash function (a standard 64-bit multiplicative mixer), and the sign of the top bit gives ±1\pm 1. This costs O(1)O(1) time and O(1)O(1) memory per lookup, with no dependence on NN.

This construction preserves exactly the two properties the estimator needs:

  • Fixed-per-sample: For a given ss, the hash is a pure deterministic function of xx, so repeated queries at the same node xx (which happens naturally as a walk can revisit nodes) always return the same value. That is, z(s)z^{(s)} behaves as one fixed implicit vector for the duration of Hutchinson sample ss, exactly as the algorithm requires.
  • Independence across xx: Outputs at different node indices xx are effectively uncorrelated for fixed ss, which is what the Hutchinson estimator's unbiasedness relies on (E[zxzy]=δxy\mathbb{E}[z_x z_y] = \delta_{xy}). A fresh seed ss per Hutchinson sample gives independence across probes as well.

So zx(s)z^{(s)}_x should be understood not as "index xx into a stored ±1\pm 1 array," but as "the value returned by a fixed, seed-ss-dependent pseudo-random function evaluated at xx" which is functionally equivalent to indexing a Rademacher vector, but realized without ever storing one. We will add a sentence to the algorithm description making this explicit.

Memory is O(n2)O(n^2) not O(n)O(n)

The reviewer is correct: for all-to-all coupling matrices, storing JJ inherently requires O(n2)O(n^2) memory. Our O(n)O(n) claim refers to the incremental per-step diagonal update during a walk (Alg. 1), which is O(n)O(n) even for dense JJ (vs. O(n2)O(n^2) if recomputed from scratch). The walk needs only O(n)O(n) auxiliary storage (spins, local fields) beyond holding JJ. For sparse-coupling models (bounded degree dd), both JJ storage and per-step updates are O(n)O(n). We will revise the text to explicitly separate memory complexity from per-step update complexity.

Memory, walk clock time and variance beyond n=12n=12

To address system size concerns, we extended our evaluation to n=50n=50 (2502^{50} space). Additionally, because Hutchinson sampling is embarrassingly parallel, deploying 32 workers yielded a 25.1×25.1\times speedup, cutting execution time from 49 minutes to under 2 minutes.

Authors · CommentOpenReview ↗

Thank you for taking the time to read our rebuttal. We hope our detailed responses regarding the sample complexity bounds, memory clarifications, and variance ablations have addressed your core concerns.

To further address your feedback regarding experimental validation at larger system sizes, we wanted to share an additional experiment we have conducted since our initial rebuttal:

To validate the GRF estimator at system sizes beyond the n≤14n \le 14 limit of exact diagonalization, we employed the Jordan-Wigner (JW) transformation. This maps the 1D transverse-field Ising model to a system of free fermions, yielding the exact partition function in O(n3)O(n^3) time. While this mapping is specific to one-dimensional models with nearest-neighbor couplings and no frustration (it does not apply to the SK model, the XXZ chain, or frustrated lattices—all of which our GRF estimator handles without modification), it serves as an excellent oracle. Using JW, we compared GRF estimates for n=14,16,18,20n = 14, 16, 18, 20. At β=0.4\beta = 0.4, we found the average error increases from 2.5% for n=14n = 14 to 10.25% for n=20n = 20.

We hope this new validation, alongside the comprehensive data and proofs in our main rebuttal, fully resolves the points you originally noted. Please let us know if you have any remaining questions before the discussion period ends. If our responses have adequately addressed your concerns, we kindly ask if you might consider raising your score.

Thank you again for your time and guidance in strengthening our paper.

Reviewer KZPG · CommentOpenReview ↗

Thank you for the detailed rebuttal and additional experiments; they resolve most of my concerns. Therefore, I would like to raise my score to 4.

From OpenReview, CC BY 4.0. Authors as signed there; shown unedited.

Missing a submission?

Loading the discussion…