betaFeedback

WorksPhysics and Astronomy

Ancilla-Free Exact Dicke-State Synthesis with Optimal Size and Depth

Abstract

We construct exact circuits for nn-qubit Dicke states of any Hamming weight kk using O(n)O(n) single-qubit gates and CNOTs in O(log⁡n)O(\log n) depth without ancillary qubits. The gate count and depth are asymptotically optimal for every 0<k<n0<k<n. We compress symmetric blocks to free output qubits for weight-dependent phases. A sign correction followed by a collective rotation produces a state whose overlap with the target is at least a positive constant, so exact amplitude amplification takes O(1)O(1) steps. For balanced Dicke states (k=⌊n/2⌋k=\lfloor n/2\rfloor), the logarithmic depth disproves the Ω(k)Ω(k) depth lower bound conjectured by Yuan and Zhang (2025).

Introduction

The nn-qubit Dicke state of weight kk is the uniform superposition of all computational basis states with exactly kk ones,

∣Dkn⟩:=(nk)−1/2∑∣x∣=k∣x⟩,0≤k≤n,\lvert D_k^n\rangle:= \binom{n}{k}^{-1/2} \sum_{\lvert x\rvert=k} \lvert x\rangle,\qquad0 \leq k \leq n,

where ∣x∣=∑i=1nxi\lvert x\rvert= \sum_{i=1}^{n} x_i is the Hamming weight of x=(x1,…,xn)∈{0,1}nx=(x_1,\ldots,x_n)\in\{0,1\}^n. These states form an orthonormal basis of the symmetric subspace [1]. In the decoded quantum interferometry algorithm, ∣Dkn⟩\lvert D_k^n\rangle represents a uniform superposition over all sets of kk error locations in a codeword [2]. In quantum metrology, the balanced state ∣Dn/2n⟩\lvert D_{n/2}^n\rangle serves as a probe for estimating small collective spin rotations when nn is even [3].

For 0<k<n0 < k < n, preparing ∣Dkn⟩\lvert D_k^n\rangle requires Ω(n)\Omega(n) gates [4], [5] and Ω(log⁡n)\Omega(\log n) depth [6]. When r:=min⁡{k,n−k}r:=\min\{k,n-k\} is constant, the circuits of Bärtschi and Eidenbenz [7] and Yuan and Zhang [6] attain both bounds without ancillary qubits. For balanced Dicke states, however, their bounds give O(n2)O(n^2) gates and O(n)O(n) depth (Table I). Liu, Childs, and Gottesman achieve polylogarithmic depth for arbitrary weights by coherent symmetrization, using O(nlog⁡n)O(n\log n) ancillary qubits [8]. We ask whether every Dicke state admits a linear-size preparation circuit that attains optimal depth using only the output qubits.

Problem 1 (Exact Dicke-state preparation). Can every nn-qubit Dicke state be prepared exactly using O(n)O(n) single-qubit gates and CNOTs, with O(log⁡n)O(\log n) depth and without ancillary qubits?

Our Results

Our circuits meet the size and depth bounds in Problem 1 using only the output qubits.

Theorem 1. For every n≥2n \geq2 and 1≤k≤n−11 \leq k \leq n-1, there is an ancilla-free circuit that prepares ∣Dkn⟩\lvert D_k^n\rangle exactly using O(n)O(n) arbitrary single-qubit gates and CNOTs, with O(log⁡n)O(\log n) depth.

In particular, for k=⌊n/2⌋k=\lfloor n/2\rfloor, our logarithmic-depth construction rules out the Ω(k)\Omega(k) depth lower bound conjectured by Yuan and Zhang [6] for Dicke-state preparation. We call the Hamming weights 1≤k≤n−11 \leq k \leq n-1 nontrivial. For k=0k=0, the input is already the target state. For k=nk=n, we prepare the target by applying a Pauli XX gate to each qubit in parallel.

For every nontrivial Dicke state, the reduced state of any pair of qubits is entangled [4]. Huang et al. [5] call states with this property WW-like and show in their Supplemental Material that preparing any such nn-qubit state requires Ω(n)\Omega(n) CNOT gates. Yuan and Zhang [6] show that preparing any nontrivial nn-qubit Dicke state requires depth Ω(log⁡n)\Omega(\log n). Thus our gate count and depth are both asymptotically optimal.

Bärtschi and Eidenbenz give exact Dicke-state preparation using O(nr)O(nr) gates and O(n)O(n) depth without ancillary qubits [9]. Their construction also yields coherent preparation of symmetric states. Bellante et al. [10] develop TreeRLSP, a tree-tensor-network method for preparing regular language states, including Dicke states.

Liu, Childs, and Gottesman give deterministic coherent symmetrization [8]. Zij, Yuan, and Nie [11] start from a biased product state and use an exact Hamming-weight counter to implement the reflections for O(r1/4)O(r^{1/4}) amplitude amplification steps. Our sign correction and inverse rotation reduce the number of steps to O(1)O(1). Khattar et al. [2] use a reversible divide-and-conquer algorithm to map each index to the corresponding set of occupied positions. Their circuit uses O~(n)\widetilde{O}(n) gates for a sparse encoding of Dicke states.

Joshi and Vasconcelos give exact constant-depth Dicke-state preparation with unbounded fanout [12]. Gretta, Gupta, and Joshi obtain constant-depth preparation of polylogarithmic-weight Dicke states using unbounded-control Toffoli gates, and of arbitrary symmetric states with additional fanout gates [13]. Their Dicke-state construction combines constant initial overlap and uniform amplitudes in the target-weight subspace with exact amplitude amplification.

Yu et al. use collective measurements and feedback [14]. For even nn, Yang, Wei, and Yin prepare ∣Dn/2n⟩\lvert D_{n/2}^n\rangle with an adaptive circuit of depth O(log⁡n)O(\log n) or a unitary circuit of depth O(log⁡2n)O(\log^2 n) [15]. Both use O(n)O(n) additional qubits and succeed with constant probability. They ask whether a unitary circuit can achieve O(log⁡n)O(\log n) depth with O(n)O(n) ancillary qubits. Theorem 1 achieves this depth using only the output qubits.

Construction Overview

Our construction has three components: a constant-overlap initial state, ancilla-free weight-dependent phase circuits, and exact amplitude amplification. Figure 1 shows how they fit together.

Circuit overview

Figure 1. Circuit overview. (a) For an input ∣x⟩∈Sn|x\rangle\in\mathcal{S}_n, CC compresses each block as illustrated. The qubits in state ∣0⟩|0\rangle are used to compute the total weight with AA and apply its phase with Φf\Phi_f. A†A^\dagger uncomputes the arithmetic and C†C^\dagger decompresses the blocks. (b) For 1≤k≤n/21\leq k\leq n/2, BB prepares the initial state, QQ amplifies its target component, and MM completes phase matching and global-phase correction (Section V). Here Rα:=Ry(α)⊗nR_\alpha:=R_y(\alpha)^{\otimes n} and φ:=2arcsin⁡k/n\varphi:=2\arcsin\sqrt{k/n}.

ConstructionElementary gatesDepthExternal ancillas
Bärtschi–Eidenbenz [7]O(nr)O(nr)O(rlog⁡(n/r))O(r\log(n/r))0
Yuan–Zhang [6]O(nr)‡O(nr)^{\ddagger}O(r+log⁡(r+1)log⁡(n/r))O(r+\log(r+1)\log(n/r))0
TreeRLSP [10]O(n(r+1)6)O(n(r+1)^6)O((r+1)6log⁡(n+1))O((r+1)^6\log(n+1))0
Zi–Yuan–Nie [11]O(nr1/4log⁡(n+1))O(nr^{1/4}\log(n+1))O(r1/4log⁡(n+1))O(r^{1/4}\log(n+1))⌈log⁡(n+1)⌉\lceil\log(n+1)\rceil
Liu–Childs–Gottesman [8 Result 2]O(nlog⁡4(n+1)log⁡log⁡(n+1))‡O(n\log^4(n+1)\log\log(n+1))^{\ddagger}O(log⁡3(n+1)log⁡log⁡(n+1))O(\log^3(n+1)\log\log(n+1))O(nlog⁡(n+1))O(n\log(n+1))
This workO(n)O(n)O(log⁡(n+1))O(\log(n+1))0

Table 1. Selected upper bounds for deterministic exact preparation of a Dicke state of weight kk by unitary circuits. Here 1≤k≤n−11\leq k\leq n-1 and r=min⁡{k,n−k}r=\min\{k,n-k\}.

For the entries marked ‡\ddagger, we bound the gate count by multiplying width and depth for the full circuit in [8] and for each subcircuit separately in [6]. By [6 Lemma 12], we can limit each division subcircuit to O(r2/log⁡(r+1))O(r^2/\log(r+1)) temporary qubits while preserving the depth bound. This gives O(r2)O(r^2) gates per division subcircuit and O(nr)O(nr) gates in total after summing over the O(n/r)O(n/r) division and leaf subcircuits.

A constant-overlap initial state. After bit complementation, assume 1≤k≤n/21\leq k\leq n/2. One layer of single-qubit rotations prepares the biased product state

∣P⟩:=(1−k/n∣0⟩+k/n∣1⟩)⊗n=∑waw∣Dwn⟩.|P\rangle:= \left(\sqrt{1-k/n}|0\rangle+\sqrt{k/n}|1\rangle\right)^{\otimes n}=\sum_w a_w|D_w^n\rangle.

Its overlap with ∣Dkn⟩|D_k^n\rangle is ak=Θ(k−1/4)a_k=\Theta(k^{-1/4}). We choose the signs of the Dicke coefficients of ∣P⟩|P\rangle to match those of a rotated Dicke state. Set Rθ:=Ry(θ)⊗nR_\theta:=R_y(\theta)^{\otimes n} and βw:=⟨Dwn∣Rθ∣Dkn⟩\beta_w:=\langle D_w^n|R_\theta|D_k^n\rangle. Apply a weight-dependent sign correction S∣Dwn⟩:=sgn⁡(βw)∣Dwn⟩S|D_w^n\rangle:=\operatorname{sgn}(\beta_w)|D_w^n\rangle, taking sgn⁡(0):=1\operatorname{sgn}(0):=1, and then apply Rθ†R_\theta^\dagger. The resulting target overlap is

⟨Dkn∣Rθ†S∣P⟩=∑waw∣βw∣.\langle D_k^n|R_\theta^\dagger S|P\rangle=\sum_w a_w|\beta_w|.

For sufficiently large kk, choose θ=Θ(n−1/2)\theta=\Theta(n^{-1/2}). Let σ:=k(1−k/n)\sigma:=\sqrt{k(1-k/n)} denote the standard deviation of the Hamming weight in ∣P⟩|P\rangle. On a weight interval of width Θ(σ)\Theta(\sigma) centered at kk, every awa_w is Ω(σ−1/2)\Omega(\sigma^{-1/2}). We approximate the collective rotation by a quantum walk and show that the sum of the magnitudes of its amplitudes over this interval is Ω(σ)\Omega(\sqrt{\sigma}). Multiplying these bounds gives a constant overlap for the walk after sign correction. The approximation error is small enough that the overlap for the collective rotation remains bounded below by a positive constant. For bounded kk, the product state alone suffices (Lemma 2).

Weight-dependent phases without ancillas. We need the phase circuit only on the symmetric subspace Sn\mathcal{S}_n. For such inputs, each full block of 31 qubits lies in the span of its 32 Dicke states. Encoding the block weight in five qubits leaves the other 26 in ∣0⟩|0\rangle. We use these qubits to compute the total weight and apply the corresponding phase, then reverse the arithmetic and decompress the blocks. Lemma 1 thus implements any prescribed weight-dependent phase on Sn\mathcal{S}_n with O(n)O(n) gates and O(log⁡n)O(\log n) depth using only the output register. This gives both the sign correction SS and the phase shifts needed for amplification.

Exact amplitude amplification. Let BB prepare the initial state above. Following the constant-overlap approach of [13], we amplify the target amplitude by alternating phase shifts on the target and on the initial state. The latter shift uses BB and B†B^\dagger. Since the initial overlap is at least a positive constant, O(1)O(1) iterations suffice. A final phase-matching step cancels any remaining component orthogonal to ∣Dkn⟩|D_k^n\rangle. Each step uses O(n)O(n) gates and O(log⁡n)O(\log n) depth, proving Theorem 1.

Preliminaries

States and notation. The Dicke states form an orthonormal basis of the symmetric subspace

Sn:=span⁡{∣Dwn⟩:0≤w≤n}.\mathcal{S}_n:=\operatorname{span}\{|D_w^n\rangle:0\leq w\leq n\}.

For 0≤j<2m0\leq j<2^m, define bin⁡m(j):=(jm−1,…,j0)∈{0,1}m\operatorname{bin}_m(j):=(j_{m-1},\ldots,j_0)\in\{0,1\}^m by j=∑ℓ=0m−1jℓ2ℓj=\sum_{\ell=0}^{m-1}j_\ell2^\ell. We use ∣bin⁡m(j)⟩|\operatorname{bin}_m(j)\rangle to denote the corresponding computational basis state. The symbol ⊕\oplus denotes bitwise addition modulo two. All logarithms are base two.

Circuit model. We use arbitrary single-qubit gates and CNOTs. Circuit size counts these elementary gates. Depth counts layers of gates acting on disjoint sets of qubits. A Dicke-state preparation circuit maps ∣0n⟩|0^n\rangle to ∣Dkn⟩|D_k^n\rangle exactly.

For state preparation, ancillas are qubits beyond the nn output qubits.

Weight-dependent phases within the output register

We construct an ancilla-free circuit that applies a prescribed phase eif(w)e^{if(w)} to each Dicke component ∣Dwn⟩|D_w^n\rangle of a symmetric state. This operation is used for sign correction and amplitude amplification in the state-preparation circuit.

We compress each constant-size symmetric block into a binary encoding of its weight [9]. The resulting qubits in state ∣0⟩|0\rangle are used to compute the total weight by reversible carry-save addition [16]. After applying the required phase, we reverse the computation and decompress the blocks.

Lemma 1. For every function f:{0,…,n}→Rf:\{0,\ldots,n\}\to\mathbb{R}, there is an nn-qubit circuit UfU_f with O(n)O(n) gates and O(log⁡(n+1))O(\log(n+1)) depth satisfying

Uf∣Dwn⟩=eif(w)∣Dwn⟩,0≤w≤n.U_f|D_w^n\rangle=e^{if(w)}|D_w^n\rangle,\qquad0\leq w\leq n.

Proof. For n≤31n \le31, exact synthesis [17] gives a circuit with constant gate count and depth. For n≥32n \ge32, partition the nn qubits into Q:=⌈n/31⌉Q := \lceil n/31\rceil blocks of sizes s1,…,sQs_1,\ldots,s_Q, where si:=31s_i := 31 for i<Qi < Q and sQ:=n−31(Q−1)s_Q := n - 31(Q-1). Set bi:=⌈log⁡(si+1)⌉≤5b_i := \lceil\log(s_i+1)\rceil\le5. Five qubits suffice to encode each block weight, leaving enough space for the addition and phase circuits below. For each block size ss, choose a unitary VsV_s satisfying

Vs∣Djs⟩=∣bin⁡⌈log⁡(s+1)⌉(j)⟩∣0s−⌈log⁡(s+1)⌉⟩(1)V_s\left|D_j^s\right\rangle= \left|\operatorname{bin}_{\lceil\log(s+1)\rceil}(j)\right\rangle\left|0^{s-\lceil\log(s+1)\rceil}\right\rangle \tag*{(1)}

for every block weight j∈{0,…,s}j \in\{0,\ldots,s\}. A single VsV_s acts coherently on all these weights. Since s≤31s \le31, each VsV_s has an exact implementation with constant gate count and depth without ancillary qubits [9, 17]. Applying these circuits to all blocks in parallel requires O(n)O(n) gates and constant depth. The decomposition

∣Dwn⟩=∑∑iji=w∏i(siji)(nw)⨂i∣Djisi⟩\left|D_w^n\right\rangle= \sum_{\sum_i j_i=w}\sqrt{\frac{\prod_i\binom{s_i}{j_i}}{\binom{n}{w}}}\bigotimes_i\left|D_{j_i}^{s_i}\right\rangle

allows each block to be compressed by VsiV_{s_i}. Since block ii yields si−bis_i-b_i qubits in state ∣0⟩\left|0\right\rangle for every jij_i, the compressed state contains n−∑ibi≥n−5Qn-\sum_i b_i \ge n-5Q qubits in state ∣0⟩\left|0\right\rangle. Summing the encoded block weights gives the total Hamming weight ww.

Summation and storage. Treat the QQ binary block weights as rows and sum them using a tree of reversible carry-save adders. Let m:=⌈log⁡(n+1)⌉m := \lceil\log(n+1)\rceil. Each full adder uses one qubit initialized to ∣0⟩\left|0\right\rangle to store the carry:

(a,b,c,0)⟼(a,b,a⊕b⊕c,ab⊕ac⊕bc).(2)(a,b,c,0)\longmapsto(a,b,a\oplus b\oplus c,ab\oplus ac\oplus bc). \tag*{(2)}

The identity ab⊕ac⊕bc=a⊕(a⊕b)(a⊕c)ab\oplus ac\oplus bc=a\oplus(a\oplus b)(a\oplus c) gives a constant-size implementation. First XOR aa into bb, cc and compute their product into the carry qubit. Then XOR aa into that qubit, restore bb, and XOR bb into the sum qubit.

The sum and carry satisfy a+b+c=(a⊕b⊕c)+2(ab⊕ac⊕bc)a+b+c=(a\oplus b\oplus c)+2(ab\oplus ac\oplus bc). Toffoli gates admit constant-size ancilla-free decompositions [17]. Missing bits are treated as zeros. A column with two input bits uses one Toffoli gate to compute the carry and one CNOT to replace the second bit by their XOR. Within each round, adders for different triples or columns act on disjoint qubits and run in parallel. We retain the input and carry bits needed for uncomputation.

For the QQ rows of at most five bits, let MtM_t be the number of rows remaining to be summed after tt carry-save rounds with M0=QM_0=Q. Each round replaces gt:=⌊Mt/3⌋g_t:=\lfloor M_t/3\rfloor triples by pairs, so Mt+1=Mt−gtM_{t+1}=M_t-g_t. Let TT be the number of rounds needed to reduce the rows to two. Then

Mt+1−2≤23(Mt−2),∑t=0T−1gt=Q−2.M_{t+1}-2\le\frac{2}{3}(M_t-2),\qquad\sum_{t=0}^{T-1}g_t=Q-2.

Each round reduces the row count by gtg_t, so ∑t=uT−1gt=Mu−2\sum_{t=u}^{T-1}g_t=M_u-2. Summing over uu gives

∑t=0T−1tgt=∑u=1T−1(Mu−2)≤(Q−2)∑u=1∞(23)u=2(Q−2).\sum_{t=0}^{T-1}tg_t=\sum_{u=1}^{T-1}(M_u-2)\le(Q-2)\sum_{u=1}^{\infty}\left(\frac{2}{3}\right)^u=2(Q-2).

Round tt has at most 5+t5+t columns. The total number of carry qubits used across all rounds is at most

∑t(5+t)gt≤7(Q−2).(3)\sum_t(5+t)g_t\le7(Q-2). \tag*{(3)}

This gives O(Q)O(Q) gates and O(log⁡Q)O(\log Q) depth.

Add the two remaining numbers A,BA,B into an mm-qubit register WW initialized to ∣0m⟩\left|0^m\right\rangle using the carries

c0:=0,cj+1:=AjBj⊕Ajcj⊕Bjcj(0≤j<m−1)c_0:=0,\qquad c_{j+1}:=A_jB_j\oplus A_jc_j\oplus B_jc_j\qquad(0\le j<m-1)

and sum bits Wj:=Aj⊕Bj⊕cjW_j:=A_j\oplus B_j\oplus c_j. Uncompute the carries while preserving A,BA,B. This uses m−1m-1 carry qubits and O(m)O(m) gates and depth. Since n+1≤32Qn+1\le32Q, we have m≤Q+4m\le Q+4. Together with the 5Q5Q qubits initially used to encode the block weights and at most 7(Q−2)7(Q-2) carry qubits retained from the carry-save additions, the total space is at most

5Q+7(Q−2)+(2m−1)≤14Q−7≤n.(4)5Q+7(Q-2)+(2m-1)\le14Q-7\le n. \tag*{(4)}

Phase application. The total weight ww stored in WW determines the phase eif(w)e^{if(w)}. The phase circuit reuses the qubits reset to ∣0⟩\left|0\right\rangle by uncomputing the temporary carry bits of the final ripple-carry adder. Split WW into three high-order bits and ℓ:=m−3\ell:=m-3 low-order bits, and set L:=2ℓL:=2^\ell. The encoded block weights and the carries retained from the carry-save additions together use at most 12Q−1412Q-14 qubits.

For each low-order bit jj, a balanced CNOT tree creates 2j−12^j-1 additional computational-basis copies. The trees run in parallel and collectively use L−1L-1 additional qubits in state ∣0⟩\left|0\right\rangle and O(L)O(L) gates with depth O(ℓ+1)O(\ell+1). The copies are reused across all high-order cases and uncomputed after the last case.

For each high-order value, compute a flag indicating whether the three high-order bits equal that value. This uses at most three available qubits in state ∣0⟩\left|0\right\rangle for the root and intermediate flags. Use the equality flag at the root to construct a binary prefix tree for the low-order bits. At a node, let pp be the flag and yy a copy of the corresponding low-order bit of WW. Let qq be an available qubit in state ∣0⟩\left|0\right\rangle. Apply a Toffoli from p,yp,y to qq followed by a CNOT from qq to pp. This replaces (p,0)(p,0) by (p∧¬y,p∧y)(p\land\neg y,p\land y). The parent qubit pp is reused for the branch with y=0y=0. Thus, a node is marked exactly when the high bits match and the low bits read so far agree with its path. The 2j2^j nodes at level jj use distinct copies of bit jj, so they can be processed in parallel. The tree has depth O(ℓ+1)O(\ell+1) and uses L−1L-1 additional flag qubits. Apply diag⁡(1,eif(w))\operatorname{diag}(1,e^{if(w)}) at each leaf, making the phase angle be zero for w>nw>n. On each computational basis input, only the leaf matching the full weight is marked across all high-order cases. Reverse the tree and the computation of the high-order equality flag before the next high-order case.

The phase stage uses at most 3+(L−1)+(L−1−ℓ)=2L+1−ℓ3+(L-1)+(L-1-\ell)=2L+1-\ell temporary qubits within the output register. Including WW, the phase stage therefore occupies at most

12Q−14+m+2L+1−ℓ=12Q+2L−10≤n.(5)12Q-14+m+2L+1-\ell=12Q+2L-10\le n. \tag*{(5)}

Indeed, 2L=2m−2≤n/22L=2^{m-2}\le n/2 and n≥31Q−30≥24Q−20n\ge31Q-30\ge24Q-20 for Q≥2Q\ge2. The maximum number of qubits used during addition is bounded separately by (4). The same temporary qubits are reused in both stages.

Uncompute the arithmetic, then invert the block compressions. The result is eif(w)∣Dwn⟩e^{if(w)}\left|D_w^n\right\rangle. The high-order register has constant size, so the phase stage uses O(L)O(L) gates and depth O(ℓ+1)O(\ell+1). Together with compression and arithmetic, this proves the stated bounds. □\square

To apply a phase to a single specified weight for n≥32n\ge32, test whether WW equals that weight. Apply one phase gate to the test flag and then reverse the test. The m−1m-1 temporary carry qubits reset to ∣0⟩\left|0\right\rangle suffice, and the phase stage uses O(m)O(m) gates and depth. For weight zero, test that all encoded block weights are zero using a balanced AND tree, apply the phase, and reverse the test and compression. This avoids weight summation. If B0B_0 is the number of bits encoding the block weights, this requires B0−1B_0-1 available qubits in state ∣0⟩\left|0\right\rangle, with $2B_0-1\le10Q-1\le nforforn\ge32.

An initial state with constant overlap

Starting from a product state, we construct an initial state whose overlap with ∣Dkn⟩|D_k^n\rangle is bounded below by a positive constant independent of nn and kk. This bound allows us to prepare ∣Dkn⟩|D_k^n\rangle exactly using O(1)O(1) amplitude amplification steps.

Complementing all bits reduces nontrivial weights to 1≤k≤n/21 \le k \le n/2. Set p:=k/np := k/n and define the product state

∣P⟩:=(1−p∣0⟩+p∣1⟩)⊗n=∑w=0naw∣Dwn⟩,|P\rangle:= \left(\sqrt{1-p}|0\rangle+\sqrt{p}|1\rangle\right)^{\otimes n}=\sum_{w=0}^{n}a_w|D_w^n\rangle,

where aw:=(nw)pw(1−p)n−wa_w:=\sqrt{\binom{n}{w}p^w(1-p)^{n-w}}. The probabilities aw2a_w^2 form a binomial distribution with mean kk and standard deviation σ:=k(1−k/n)\sigma:=\sqrt{k(1-k/n)}. Set aw:=0a_w:=0 for integers w<0w<0 or w>nw>n, and let a:=(aw)w∈Za:=(a_w)_{w\in\mathbb{Z}}. Then ∥a∥2=1\|a\|_2=1. The standard deviation σ\sigma of the weight distribution satisfies k/2≤σ≤k\sqrt{k/2}\le\sigma\le\sqrt{k}. By Stirling’s formula, the coefficient of ∣Dkn⟩|D_k^n\rangle in ∣P⟩|P\rangle is ak=Θ(σ−1/2)=Θ(k−1/4)a_k=\Theta(\sigma^{-1/2})=\Theta(k^{-1/4}). Direct amplitude amplification therefore takes Θ(k1/4)\Theta(k^{1/4}) iterations as kk grows.

Let

Ry(α):=(cos⁡(α/2)−sin⁡(α/2)sin⁡(α/2)cos⁡(α/2))R_y(\alpha):=\begin{pmatrix}\cos(\alpha/2)&-\sin(\alpha/2)\\ \sin(\alpha/2)&\cos(\alpha/2)\end{pmatrix}

denote the single-qubit rotation about the yy axis, and recall that Rθ=Ry(θ)⊗nR_\theta=R_y(\theta)^{\otimes n}. For θ≥0\theta\ge0, let

βw:=⟨Dwn∣Rθ∣Dkn⟩,S∣Dwn⟩:=sgn⁡(βw)∣Dwn⟩.\beta_w:=\langle D_w^n|R_\theta|D_k^n\rangle,\qquad S|D_w^n\rangle:=\operatorname{sgn}(\beta_w)|D_w^n\rangle.

We set the sign at zero to +1+1. Section VI computes sgn⁡(βw)\operatorname{sgn}(\beta_w) exactly for the angles used below. Lemma 1 implements SS with O(n)O(n) gates and O(log⁡(n+1))O(\log(n+1)) depth. With ϕ:=2arcsin⁡p\phi:=2\arcsin\sqrt{p}, define

B:=R−θSRϕ,B:=R_{-\theta}SR_\phi,
∣ψ⟩:=B∣0n⟩=R−θS∣P⟩,|\psi\rangle:=B|0^n\rangle=R_{-\theta}S|P\rangle,
F:=⟨Dkn∣ψ⟩=∑waw∣βw∣.(6)F:=\langle D_k^n|\psi\rangle=\sum_w a_w|\beta_w|. \tag*{(6)}

For d≥0d\ge0, let FdF_d denote this overlap at θd:=2arctan⁡(d/(2n))\theta_d:=2\arctan(d/(2\sqrt{n})). The algorithm chooses the largest overlap among d∈D:={0,1/4,1,2}d\in\mathcal{D}:=\{0,1/4,1,2\} (Section VI). Figure 2 illustrates the resulting sign correction. The first two candidates suffice for the following bound.

Figure 2. For n=128n=128 and k=32k=32, the algorithm selects d=1d=1, giving F1≈0.8384F_1\approx0.8384. At this overlap, only the final phase-matching step is needed. Starting from the product state (F0≈0.2850F_0\approx0.2850) requires two standard amplification steps before phase matching. The plots show ∣w−k∣≤14|w-k|\le14 at the selected angle. (a) Product-state coefficients awa_w and rotated-target coefficients βw\beta_w. (b) Contributions to the overlap after the inverse rotation, awβwa_w\beta_w without sign correction and aw∣βw∣a_w|\beta_w| with it.

Lemma 2. There is a constant η>0\eta>0 such that max⁡{F0,F1/4}≥η\max\{F_0,F_{1/4}\}\ge\eta for all $1\le k\le n/2.

For large kk, we compare the rotated state at d=1/4d=1/4 with a quantum walk on the weight lattice. On an interval of width Θ(σ)\Theta(\sigma) around kk, each awa_w is Ω(σ−1/2)\Omega(\sigma^{-1/2}) and the absolute walk amplitudes sum to Ω(σ)\Omega(\sqrt{\sigma}). Their weighted sum therefore remains bounded below by a constant after accounting for the approximation error. For bounded kk, the product state suffices.

Amplitudes of the Product State

We first establish

ak2>13σ,ak+j2>13σ(k≥16, ∣j∣≤σ/4).(7)a_k^2>\frac{1}{3\sigma},\qquad a_{k+j}^2>\frac{1}{3\sigma}\quad(k\ge16,\ |j|\le\sigma/4). \tag*{(7)}

At w=kw=k, Stirling’s bounds give ak2≥e−1/6/(2πσ)>1/(3σ)a_k^2\ge e^{-1/6}/(\sqrt{2\pi}\sigma)>1/(3\sigma).

For the second bound, set w:=k+jw:=k+j and define

g(w):=wln⁡(w/k)+(n−w)ln⁡((n−w)/(n−k)).g(w):=w\ln(w/k)+(n-w)\ln((n-w)/(n-k)).

Stirling’s bounds for n!n!, w!w!, and (n−w)!(n-w)! give

aw2≥exp⁡[−g(w)−1/(12w)−1/(12(n−w))]2πw(1−w/n).a_w^2\ge\frac{\exp[-g(w)-1/(12w)-1/(12(n-w))]}{\sqrt{2\pi w(1-w/n)}}.

Since σ≤k\sigma\le\sqrt{k} and k≥16k\ge16, both w/kw/k and (n−w)/(n−k)(n-w)/(n-k) lie in [15/16,17/16][15/16,17/16]. Thus w,n−w≥15w,n-w\ge15 and w(1−w/n)≤(17/16)2σ2w(1-w/n)\le(17/16)^2\sigma^2. Throughout ∣w−k∣≤σ/4|w-k|\le\sigma/4, g′′(w)=1/w+1/(n−w)≤4/(3σ2)g''(w)=1/w+1/(n-w)\le4/(3\sigma^2). Since g(k)=g′(k)=0g(k)=g'(k)=0, Taylor’s theorem gives for g(w)≤2(w−k)2/(3σ2)≤1/24g(w)\le2(w-k)^2/(3\sigma^2)\le1/24. The Stirling correction for the denominator factorials is at most 1/(12w)+1/(12(n−w))≤1/901/(12w)+1/(12(n-w))\le1/90. Using e−x>1−xe^{-x}>1-x and 2π<8/3\sqrt{2\pi}<8/3, we obtain

aw2≥e−19/360(17/16)2πσ>13σ.a_w^2\ge\frac{e^{-19/360}}{(17/16)\sqrt{2\pi}\sigma}>\frac{1}{3\sigma}.

Comparison with a Continuous-Time Quantum Walk

Near weight kk, the rotation couples adjacent weights with nearly constant strength. We approximate it by a continuous-time quantum walk on Z\mathbb{Z} with constant couplings. For integer jj, the Bessel function of the first kind has the integral representation [18]

Jj(z):=1π∫0πcos⁡(jt−zsin⁡t) dt.(8)J_j(z):=\frac{1}{\pi}\int_0^\pi\cos(jt-z\sin t)\,dt. \tag*{(8)}

Set h:=k(n−k)/2h:=\sqrt{k(n-k)}/2 and z:=2hθz:=2h\theta. Extend βw\beta_w by zero outside 0≤w≤n0\le w\le n. For θ≥0\theta\ge0, we claim

(∑j∈Z(∣βk+j∣−∣Jj(z)∣)2)1/2≤nθ222+3nθ2σ.(9)\left(\sum_{j\in\mathbb{Z}}(|\beta_{k+j}|-|J_j(z)|)^2\right)^{1/2}\le\frac{n\theta^2}{2\sqrt{2}}+\frac{3\sqrt{n}\theta}{2\sigma}. \tag*{(9)}

Identify ∣j⟩|j\rangle with ∣Dk+jn⟩|D_{k+j}^n\rangle for −k≤j≤n−k-k\le j\le n-k. Let AA be the generator of RθR_\theta in this basis, extended by zero outside this range. On ℓ2(Z)\ell^2(\mathbb{Z}), define D∣j⟩:=ij∣j⟩D|j\rangle:=ij|j\rangle and T∣j⟩:=∣j+1⟩T|j\rangle:=|j+1\rangle for j∈Zj\in\mathbb{Z}. The diagonal change of basis gives D†AD=−iHD^\dagger A D=-iH, where HH is a real symmetric tridiagonal operator with off-diagonal coefficients

hj:=12(k+j+1)(n−k−j)(−k≤j<n−k),h_j:=\frac{1}{2}\sqrt{(k+j+1)(n-k-j)}\qquad(-k\le j<n-k),

and zero elsewhere. Compare HH with K:=h(T+T†)K:=h(T+T^\dagger). Figure 3 illustrates the two couplings.

Weight-basis comparison

Figure 3. Weight-basis comparison, with j=w−kj=w-k. The larger nodes mark the starting point j=0j=0, corresponding to Hamming weight w=kw=k. Replacing hjh_j by hh gives the walk used to compare ∣βk+j∣|\beta_{k+j}| with ∣Jj(z)∣|J_j(z)|.

For every integer jj,

∣hj−h∣≤λ(∣j∣+1),λ:=n2k(n−k).|h_j-h|\le\lambda(|j|+1),\qquad\lambda:=\frac{n}{2\sqrt{k(n-k)}}.

For −k≤j<n−k-k \le j < n-k, subtract the expressions under the square roots and use (k+j+1)(n−k−j)−k(n−k)=(n−2k−j)j+(n−k−j)(k+j+1)(n-k-j)-k(n-k)=(n-2k-j)j+(n-k-j). Here ∣n−2k−j∣≤n|n-2k-j|\le n and 0<n−k−j≤n0<n-k-j\le n. Outside this range, ∣j∣+1≥k|j|+1\ge k and λk≥h\lambda_k\ge h. Let ϕ(s):=e−isK∣0⟩\phi(s):=e^{-isK}|0\rangle. Under the Fourier transform, KK acts by multiplication by 2hcos⁡t2h\cos t. The Jacobi–Anger expansion [18] therefore gives

⟨j∣ϕ(s)⟩=12π∫−ππe−i2hscos⁡teijt dt=(−i)jJj(2hs).(10)\langle j|\phi(s)\rangle=\frac{1}{2\pi}\int_{-\pi}^{\pi}e^{-i2hs\cos t}e^{ijt}\,dt=(-i)^jJ_j(2hs). \tag*{(10)}

Applying Parseval’s identity to e−i2hscos⁡te^{-i2hs\cos t} and its derivative gives ∥ϕ(s)∥2=1\|\phi(s)\|_2=1 and ∥Mϕ(s)∥2=2hs\|M\phi(s)\|_2=\sqrt{2}hs, where (Mv)j=jvj(Mv)_j=jv_j. Shifting indices and applying the triangle inequality give

∥(H−K)ϕ(s)∥2≤2λ∥Mϕ(s)∥2+3λ∥ϕ(s)∥2=λ(22hs+3).\|(H-K)\phi(s)\|_2\le2\lambda\|M\phi(s)\|_2+3\lambda\|\phi(s)\|_2 =\lambda(2\sqrt{2}hs+3).

Since HH and KK are bounded and self-adjoint, Duhamel’s formula gives

∥(e−iθH−e−iθK)∣0⟩∥2≤∫0θ∥(H−K)ϕ(s)∥2 ds≤λ(2hθ2+3θ).\|(e^{-i\theta H}-e^{-i\theta K})|0\rangle\|_2\le\int_0^\theta\|(H-K)\phi(s)\|_2\,ds \le\lambda(\sqrt{2}h\theta^2+3\theta).

Substituting hh and λ\lambda gives (9), since taking entrywise absolute values does not increase the ℓ2\ell^2 distance.

Bounds on Bessel Functions

Set τ:=11/12\tau:=11/12 and Kτ:=2/π(1−τ2)−1/4K_\tau:=\sqrt{2/\pi}(1-\tau^2)^{-1/4}. Krasikov’s bound [19] gives

∣Jj(z)∣≤2/π(z2−j2+1/4)1/4(j≥1, z>j2−1/4).|J_j(z)|\le\frac{\sqrt{2/\pi}}{(z^2-j^2+1/4)^{1/4}}\qquad(j\ge1,\ z>\sqrt{j^2-1/4}).

Together with ∣J0(z)∣≤2/(πz)|J_0(z)|\le\sqrt{2/(\pi z)} [19] and ∣J−j(z)∣=∣Jj(z)∣|J_{-j}(z)|=|J_j(z)|, this implies

∣Jj(z)∣≤Kτz(∣j∣≤τz).(11)|J_j(z)|\le\frac{K_\tau}{\sqrt z}\qquad(|j|\le\tau z). \tag*{(11)}

Parseval’s identity applied to (10) gives ∑jJj(z)2=1\sum_jJ_j(z)^2=1 and ∑jj2Jj(z)2=z2/2\sum_jj^2J_j(z)^2=z^2/2. Hence

∑∣j∣≤τzJj(z)2≥1−12τ2=49121.\sum_{|j|\le\tau z}J_j(z)^2\ge1-\frac{1}{2\tau^2}=\frac{49}{121}.

The interval contains constant probability mass, while each absolute amplitude is at most Kτ/zK_\tau/\sqrt z by (11). Hence

∑∣j∣≤τz∣Jj(z)∣≥49z121Kτ.(12)\sum_{|j|\le\tau z}|J_j(z)|\ge\frac{49\sqrt z}{121K_\tau}. \tag*{(12)}

Proof of Lemma 2. If σ<48\sigma<48, then F0=ak>1/12F_0=a_k>1/12 by (7). Suppose σ≥48\sigma\ge48, so k≥16k\ge16, and take θ=θ1/4\theta=\theta_{1/4}. Since x/2≤arctan⁡x≤xx/2\le\arctan x\le x on [0,1][0,1],

18≤z/σ=nθ≤14.\frac{1}{8}\le z/\sigma=\sqrt n\theta\le\frac{1}{4}.

Thus ∣j∣≤τz|j|\le\tau z implies ∣j∣≤σ/4|j|\le\sigma/4. By (7), (12), and Kτ<2K_\tau<\sqrt2,

∑jak+j∣Jj(z)∣≥491213Kτzσ>1162.\sum_j a_{k+j}|J_j(z)|\ge\frac{49}{121\sqrt3K_\tau}\sqrt{\frac z\sigma}>\frac{1}{16\sqrt2}.

By Cauchy–Schwarz and (9), this sum differs from F1/4F_{1/4} by at most 1/(322)+3/(8σ)1/(32\sqrt2)+3/(8\sigma), since ∥a∥2=1\|a\|_2=1. Hence

F1/4>1322−38σ>1128.F_{1/4}>\frac{1}{32\sqrt2}-\frac{3}{8\sigma}>\frac{1}{128}.

The two cases give the claim with η=1/128\eta=1/128.

Exact amplitude amplification

Proof of Theorem 1. By bit complementation, assume 1≤k≤n/21\le k\le n/2. For ∣u∣=1|u|=1, let Zw(u)Z_w(u) multiply ∣Dwn⟩|D_w^n\rangle by uu and fix all other Dicke basis states. Lemma 1 implements this operation on SnS_n. For the angle selected in Section IV, the state ∣ψ⟩=B∣0n⟩|\psi\rangle=B|0^n\rangle has overlap FF with ∣Dkn⟩|D_k^n\rangle. If F=1F=1, this state is already ∣Dkn⟩|D_k^n\rangle. Otherwise, put α:=arcsin⁡F\alpha:=\arcsin F and write

∣ψ⟩=F∣Dkn⟩+cos⁡α∣⊥⟩,|\psi\rangle=F|D_k^n\rangle+\cos\alpha|\perp\rangle,

where ∣⊥⟩|\perp\rangle is a unit vector orthogonal to ∣Dkn⟩|D_k^n\rangle. The operator BZ0(u)B†BZ_0(u)B^\dagger applies phase uu to ∣ψ⟩|\psi\rangle. Thus the usual amplification step [20] is Q:=−BZ0(−1)B†Zk(−1)Q:=-BZ_0(-1)B^\dagger Z_k(-1). After t:=⌈[π/(4α)−1/2]⌉t:=\lceil[\pi/(4\alpha)-1/2]\rceil such steps,

Qt∣ψ⟩=sin⁡β∣Dkn⟩+cos⁡β∣⊥⟩,β:=(2t+1)α≤π/2.Q^t|\psi\rangle=\sin\beta|D_k^n\rangle+\cos\beta|\perp\rangle,\qquad\beta:=(2t+1)\alpha\le\pi/2.

If β<π/2\beta<\pi/2, apply one phase-matching step [20, 21]. After Zk(u)Z_k(u), the overlap with ∣ψ⟩|\psi\rangle is ξ:=Fusin⁡β+cos⁡αcos⁡β\xi:=Fu\sin\beta+\cos\alpha\cos\beta. Applying BZ0(v)B†BZ_0(v)B^\dagger adds (v−1)∣ψ⟩(v-1)|\psi\rangle to the state. To cancel the coefficient of ∣⊥⟩|\perp\rangle, we therefore need

vξ=ξ−cos⁡βcos⁡α.v\xi=\xi-\frac{\cos\beta}{\cos\alpha}.

Since ∣v∣=1|v|=1, the right-hand side must have modulus ∣ξ∣|\xi|. Squaring and substituting the expression for ξ\xi gives

2cos⁡αRe⁡ξ=cos⁡β,Re⁡u=−cot⁡(2α)cot⁡β.2\cos\alpha\operatorname{Re}\xi=\cos\beta,\qquad\operatorname{Re}u=-\cot(2\alpha)\cot\beta.

For α<π/4\alpha<\pi/4, the choice of tt gives β>π/2−2α\beta>\pi/2-2\alpha, so the required real part lies in (−1,0)(-1,0). For α≥π/4\alpha\ge\pi/4, we have t=0t=0 and it equals 1−1/(2F2)∈[0,1)1-1/(2F^2)\in[0,1). Choose uu on the upper unit semicircle with this real part. Then Re⁡ξ>0\operatorname{Re}\xi>0, and the required second phase is v=−ξ‾/ξv=-\overline{\xi}/\xi. The coefficient of ∣Dkn⟩|D_k^n\rangle is then usin⁡β−tan⁡αcos⁡βu\sin\beta-\tan\alpha\cos\beta. If β=π/2\beta=\pi/2, the coefficient is already one after QtQ^t. In either case a single-qubit gate proportional to the identity cancels the final global phase, including the sign in QQ if omitted from its implementation.

Each complete weight-dependent phase circuit and each collective rotation preserves SnS_n. Lemma 2 gives F≥ηF\ge\eta, so the number of amplification steps is O(1)O(1). The circuit BB consists of one phase circuit and two layers of single-qubit rotations. Each amplification step uses BB, B†B^\dagger and two single-weight phase circuits. Lemma 1 therefore gives O(n)O(n) gates and O(log⁡n)O(\log n) depth without ancillary qubits, including any final bit flips.

Classical circuit generation

Algorithm 1 generates the circuit by selecting the rotation with the largest overlap after sign correction. It compares the four squared overlaps exactly and keeps the smallest dd in case of a tie. Both (13) and (14) use the target weight r=min⁡{k,n−k}r=\min\{k,n-k\}, with sgn⁡(0)=1\operatorname{sgn}(0)=1.

Proposition 1. Algorithm 1 generates the circuits of Theorem 1 in time polynomial in nn.

Proof. An integer recurrence determines every required sign exactly. Each overlap FdF_d has algebraic degree at most four, and all Fd2F_d^2 lie in a common real field of degree at most two. As in Section IV, assume 1≤k≤n/21\le k\le n/2 after bit complementation.

Algorithm 1 Generate a circuit for ∣Dkn⟩|D_k^n\rangle

Input: Integers n≥2n \ge2 and 0≤k≤n0 \le k \le n

Output: Layers of CNOTs and exact algebraic single-qubit gates with their qubit indices

  1. if k=0k = 0 then return the empty circuit

  2. if k=nk = n then return one layer of nn XX gates

  3. r←min⁡{k,n−k}r \leftarrow\min\{k,n-k\}, p←r/np \leftarrow r/n

  4. d⋆←0d_{\star} \leftarrow0, F←(nr)pr(1−p)n−rF \leftarrow\sqrt{\binom{n}{r}p^r(1-p)^{n-r}}, s←(+1)w=0ns \leftarrow(+1)^{n}_{w=0}

  5. for dd in (1/4,1,2)(1/4,1,2) do

  6. Compute H0,…,HnH_0,\ldots,H_n by (13) with q=4n/d2q=4n/d^2

  7. Compute FdF_d by (14)

  8. if Fd2>F2F_d^2 > F^2 then

  9. (d⋆,F,s)←(d,Fd,(sgn⁡Hw)w=0n)(d_{\star},F,s) \leftarrow(d,F_d,(\operatorname{sgn}H_w)^{n}_{w=0})

  10. end for

  11. Generate the sign circuit SS for ss using Lemma 1

  12. φ←2arcsin⁡p\varphi\leftarrow2\arcsin\sqrt{p}, θ←2arctan⁡(d⋆/(2n))\theta\leftarrow2\arctan(d_{\star}/(2\sqrt{n}))

  13. Form BB from RφR_{\varphi}, SS, and R−θR_{-\theta}, in that order

  14. C←BC \leftarrow B

  15. if F<1F < 1 then

  16. Append to CC the amplification steps for BB, FF, rr (Section V)

  17. if k>n/2k > n/2 then append X⊗nX^{\otimes n} to CC

  18. return CC

Exact signs. Fix d>0d>0 in DD and suppress its subscript for the moment. Set q:=4n/d2q:=4n/d^2, an integer for each of the three positive candidates. For any output string of weight ww, exactly (wj)(n−wk−j)\binom{w}{j}\binom{n-w}{k-j} weight-kk input strings share jj ones with it. Each has k−jk-j transitions 1→01\to0, giving the sign (−1)k−j(-1)^{k-j}, and n−w−k+2jn-w-k+2j unchanged bits. Each unchanged bit contributes q\sqrt{q} after the common factor (q+1)−n/2(q+1)^{-n/2} is taken out of the product. Summing over jj and normalizing the Dicke states gives

βw=(nw)(nk)q(n−w−k)/2(q+1)n/2Hw,\beta_w=\sqrt{\frac{\binom{n}{w}}{\binom{n}{k}}}\frac{q^{(n-w-k)/2}}{(q+1)^{n/2}}H_w,

where

Hw:=∑j=max⁡{0,k−(n−w)}min⁡{w,k}(−1)k−j(wj)(n−wk−j)qj.H_w:=\sum_{j=\max\{0,k-(n-w)\}}^{\min\{w,k\}}(-1)^{k-j}\binom{w}{j}\binom{n-w}{k-j}q^j.

Thus sgn⁡(βw)=sgn⁡(Hw)\operatorname{sgn}(\beta_w)=\operatorname{sgn}(H_w), with sgn⁡(0)=1\operatorname{sgn}(0)=1. Starting from H0=(−1)k(nk)H_0=(-1)^k\binom{n}{k}, the Krawtchouk difference relation [22] yields

(n−w)Hw+1=[n−w+qw−k(q+1)]Hw−qwHw−1(0≤w<n).(13)(n-w)H_{w+1}=[n-w+qw-k(q+1)]H_w-qwH_{w-1}\qquad(0\le w<n). \tag*{(13)}

The last term is omitted at w=0w=0. Indeed, Hw=[tk]Pw(t)H_w=[t^k]P_w(t) for Pw(t):=(1+qt)w(1−t)n−wP_w(t):=(1+qt)^w(1-t)^{n-w}, and taking the coefficient of tkt^k in

(n−w)Pw+1+qwPw−1=(n−w+qw)Pw−(q+1)tPw′(n-w)P_{w+1}+qwP_{w-1}=(n-w+qw)P_w-(q+1)tP_w'

gives (13). At d=0d=0 the rotation is the identity, so βw=1{w=k}\beta_w=\mathbf{1}_{\{w=k\}} and every sign is +1+1.

Overlaps and angle selection. For d>0d>0, write

b:=pq(1−p),A:=(1−p)nqn−k(nk)(q+1)n.b:=\frac{p}{q(1-p)},\qquad A:=\frac{(1-p)^nq^{n-k}}{\binom{n}{k}(q+1)^n}.

Separating the even and odd weights in (6) gives

Fd=A(E0+E1b),F_d=\sqrt{A(E_0+E_1\sqrt{b})},
Ej:=∑h=0⌊(n−j)/2⌋(n2h+j)∣H2h+j∣bh(j=0,1).(14)E_j:=\sum_{h=0}^{\lfloor(n-j)/2\rfloor}\binom{n}{2h+j}|H_{2h+j}|b^h\qquad(j=0,1). \tag*{(14)}

Here AA, bb, E0E_0, E1E_1 are rational. Because b=dσ/[2(n−k)]\sqrt{b}=d\sigma/[2(n-k)], every Fd2F_d^2 lies in Q(σ)\mathbb{Q}(\sigma). For d=0d=0, F02=ak2=(nk)pk(1−p)n−kF_0^2=a_k^2=\binom{n}{k}p^k(1-p)^{n-k} is rational. All FdF_d are nonnegative, so comparing their squares in Q(σ)\mathbb{Q}(\sigma) determines the maximizing candidate exactly.

Vandermonde’s identity gives ∣Hw∣≤qk(nk)≤qk2n|H_w|\le q^k\binom{n}{k}\le q^k2^n. These integers and the numerators and denominators of AA, bb, E0E_0, E1E_1 have O(nlog⁡(n+1))O(n\log(n+1)) bits. Generating the binomial coefficients consecutively and evaluating the parity sums by Horner’s rule takes O(n)O(n) arithmetic operations per candidate, including the recurrence. Fast integer arithmetic therefore computes all sign tables and overlaps in O~(n2)\widetilde{O}(n^2) bit operations.

Amplification parameters. For the selected overlap F<1F<1, compute cos⁡α=1−F2\cos\alpha=\sqrt{1-F^2}. If F2>1/2F^2>1/2, then t=0t=0. Otherwise start with (x,y)=(F,cos⁡α)(x,y)=(F,\cos\alpha) and repeatedly form

(x′y′)=(1−2F22Fcos⁡α−2Fcos⁡α1−2F2)(xy).\begin{pmatrix}x'\\y'\end{pmatrix} = \begin{pmatrix} 1-2F^2 & 2F\cos\alpha\\ -2F\cos\alpha& 1-2F^2 \end{pmatrix} \begin{pmatrix}x\\y\end{pmatrix}.

This adds 2α≤π/22\alpha\le\pi/2 to the current angle. Accept the update when y′≥0y'\ge0, and stop when y′=0y'=0 or before the first update with y′<0y'<0. The number of accepted updates is tt, and the final pair is (sin⁡β,cos⁡β)(\sin\beta,\cos\beta). For t=0t=0 this is the initial pair. Since F≥ηF\ge\eta, only O(1)O(1) comparisons are needed.

The formulas in Section V now give the final phases by exact algebraic operations. Adjoining cos⁡α\cos\alpha, 1−(Re⁡u)2\sqrt{1-(\operatorname{Re}u)^2} and ii to Q(F)\mathbb{Q}(F) gives a field of degree at most 32. The constant number of operations preserves the O(nlog⁡(n+1))O(n\log(n+1)) bound on coefficient bit lengths, so bounded-degree arithmetic and sign tests take only polynomial time.

Elementary gates. For each block size s≤31s\le31, compose the inverse coherent Dicke transform [9] with a unary-to-binary conversion. The resulting circuit acts only on the ss qubits of the block, and the entries of each gate matrix are algebraic numbers. For n≤31n\le31, exact synthesis of the phase circuit uses O(1)O(1) algebraic operations and root extractions. These constructions generate the qubit indices, parallel layers and exact algebraic descriptions of the gate matrices in polynomial time in nn.

Conclusion

We give ancilla-free circuits that exactly prepare any nn-qubit Dicke state using O(n)O(n) gates in O(log⁡n)O(\log n) depth. Both bounds are asymptotically optimal for 0<k<n0<k<n. By implementing weight-dependent phases within the output kets, we prepare an initial state with constant overlap with the target, so exact amplitude amplification takes only O(1)O(1) steps. Future work includes reducing the gate count by optimizing the phase circuits and the rotation angle, and adapting the construction to finite gate sets and restricted qubit connectivity.

Acknowledgments

Yunqi Huang and Shenggen Zheng were supported by the Guangdong Provincial Quantum Science Strategic Initiative (Grant No. GDZX2503001) and the Shenzhen Science and Technology Program (Grant No. ZDYJ20251211120859002). Zekun Ye was supported by start-up research funding from Fuzhou University (Grant No. XRC-26004). Wei Zi acknowledges support from the National Natural Science Foundation of China (Grant No. 62602563).

Content Generated by AI

OpenAI ChatGPT (Codex) assisted with the Abstract and Sections I–VII: literature comparison, proof development and checking, drafting and revision, the figures, and resource accounting. Its contributions include generated mathematical arguments and code. The authors are responsible for all claims, references, and results.

References

References

  1. [1]D. Castro-Silva, T. Gur, and S. Strelchuk, “Symmetric quantum computation,” in 17th Innovations in Theoretical Computer Science Conference (ITCS 2026), ser. Leibniz International Proceedings in Informatics, vol. 362. Schloss Dagstuhl – Leibniz-Zentrum für Informatik, 2026, pp. 35:1–35:10, arXiv:2501.01214v2.
  2. [2]T. Khattar, N. Shutty, C. Gidney, A. Zalckman, N. Yosri, D. Maslov, R. Babbush, and S. P. Jordan, “Verifiable quantum advantage via optimized DQI circuits,” 2025, arXiv:2510.10967v1.DOI
  3. [3]Y. Wang and B. M. Terhal, “Preparing Dicke states in a spin ensemble using phase estimation,” Physical Review A, vol. 104, p. 032407, 2021.DOI
  4. [4]X. Wang and K. Mølmer, “Pairwise entanglement in symmetric multi-qubit systems,” The European Physical Journal D, vol. 18, no. 3, pp. 385–391, 2002, arXiv:quant-ph/0106145.DOI
  5. [5]C. Chang, T. Wang, F. Wu, D. Ding, Q. Ye, L. Kong, F. Zhang, X. Ni, Z. Song, Y. Shi, H.-H. Zhao, C. Deng, and J. Chen, “Quantum instruction set design for performance,” Physical Review Letters, vol. 130, no. 7, p. 070601, 2023, Supplemental Material.
  6. [6]P. Yuan and S. Zhang, “Depth-efficient quantum circuit synthesis for deterministic Dicke state preparation,” 2025, arXiv:2505.15413v1.
  7. [7]A. Bärtschi and S. Eidenbenz, “Short-depth circuits for Dicke state preparation,” in IEEE International Conference on Quantum Computing and Engineering, 2022, pp. 87–96, arXiv:2207.09998.DOI
  8. [8]Z. Liu, A. M. Childs, and D. Gottesman, “Low-depth quantum symmetrization,” Physical Review X, vol. 16, p. 031056, 2026, arXiv:2411.0419v2.
  9. [9]A. Bärtschi and S. Eidenbenz, “Deterministic preparation of Dicke states,” in Fundamentals of Computation Theory, 2019, pp. 126–139, arXiv:1904.07358.DOI
  10. [10]E. Bellante, R. Irmejs, M. Florido-Llinàs, M. Cea Fernández, M. Crupi, M. Kiser, and J. I. Cirac, “Compiling quantum regular language states,” Proceedings of the ACM on Programming Languages, vol. 10, no. OOPSLA2, pp. 320–347, 2026, article 326; arXiv:2602.02698v1.DOI
  11. [11]W. Zi, P. Yuan, and J. Nie, “Exact quantum Hamming-weight computation at optimal depth and minimum width,” 2026, arXiv:2610.25315v1.
  12. [12]M. R. Joshi and F. Vasconcelos, “Constant-depth unitary preparation of Dicke states,” 2026, arXiv:2601.10693v3.
  13. [13]L. Gretta, M. Gupta, and M. R. Joshi, “Polylogarithmic-weight Dicke states in QAC⁰ and arbitrary symmetric states in QAC⁰,” 2026, arXiv:2604.15298v3.
  14. [14]Y. Yu, S. R. Muleady, Y.-X. Wang, N. Schine, A. V. Gorshkov, and A. M. Childs, “Efficient preparation of Dicke states,” Physical Review Letters, vol. 136, p. 030601, 2026, arXiv:2411.03428.arxiv.org/abs/2411.03428
  15. [15]M. Yang, R. Wei, and C. Yin, “Digital quantum algorithms for generating and utilizing spin squeezed states,” 2026, arXiv:2609.36004v1.
  16. [16]W. Zi, P. Yuan, J. Nie, and S. Zhang, “Efficient depth–ancilla tradeoffs for Hamming weight computation and symmetric Boolean functions,” 2026, arXiv:2608.04627v2.
  17. [17]A. Barenco, C. H. Bennett, R. Cleve, D. P. DiVincenzo, N. Margolus, P. Shor, T. Sleator, J. A. Smolin, and H. Weinfurter, “Elementary gates for quantum computation,” Physical Review A, vol. 52, pp. 3457–3467, 1995, arXiv:quant-ph/9503016.
  18. [18]National Institute of Standards and Technology, “NIST Digital Library of Mathematical Functions, chapter 10: Bessel functions,” 2026, eqs. 10.9.2 and 10.12.1–10.12.3. https://dlmf.nist.gov/10.
  19. [19]I. Krasikov, “Approximations for the Bessel and Airy functions with an explicit error term,” LMS Journal of Computation and Mathematics, vol. 17, no. 1, pp. 209–225, 2014.
  20. [20]G. Brassard, P. Høyer, M. Mosca, and A. Tapp, “Quantum amplitude amplification and estimation,” in Quantum Computation and Information, ser. Contemporary Mathematics. American Mathematical Society, 2002, vol. 305, pp. 53–74, arXiv:quant-ph/0005055.DOI
  21. [21]P. Høyer, “Arbitrary phases in quantum amplitude amplification,” Physical Review A, vol. 62, p. 052304, 2000, arXiv:quant-ph/0006031.DOI
  22. [22]National Institute of Standards and Technology, “NIST Digital Library of Mathematical Functions, sec. 18.22(ii): Difference equations in x,” 2026, eq. 18.22.12 and Table 18.22.2. https://dlmf.nist.gov/18.22.ii, accessed November 5, 2026.

Paper details

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

views · 9

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