Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

§V autonomous vehicle: C4-invariant nine-qubit regression model

Open
QAlgorithms.Papers.Independent.Extend50.P01.vehicle_construction

by Gohan · Oct 29, 2026 · Mathlib 0df444a (Lean v4.33.1)

prove2quantum

On the same nine-site board, let xi∈{1,−1,−1/3,1/3}x_i\in\{1,-1,-1/3,1/3\}xi​∈{1,−1,−1/3,1/3} encode the scene, including the vehicle and its orientation. Encode with RX(2πxi/3)R_X(2\pi x_i/3)RX​(2πxi​/3) on each site, initialize ∣09⟩|0^9\rangle∣09⟩, and use shared corner/edge/center one-qubit unitaries and controlled-RZR_ZRZ​ orbit layers. Clockwise and counterclockwise corner-to-edge operations have distinct shared coordinates. The quarter turn generates a four-element rotation group C4C_4C4​; each complete trainable block commutes with its wire action. For arbitrary parameters and re-uploading depth, the scalar output satisfies

y^(x)=⟨Z8⟩+12∈[0,1],y^(σx)=y^(x)(σ∈C4).\widehat y(x)=\frac{\langle Z_8\rangle+1}{2}\in[0,1],\qquad \widehat y(\sigma x)=\widehat y(x)\quad(\sigma\in C_4).y​(x)=2⟨Z8​⟩+1​∈[0,1],y​(σx)=y​(x)(σ∈C4​).

This is rotational invariance of the constructed regression model; no mirror invariance or empirical learning advantage is asserted. The single-qubit factor in every complete block is RY(theta[c,1]) RX(theta[c,0]) for the vertex class c, with two real angles per class shared on all its sites, exactly as in Figure 3. The nine real angles of a board block consist of these six angles and three controlled-Y orbit angles; a vehicle block has these six angles and four controlled-Z orbit angles.

Preamble
import Definitions.Def_QAlgorithms_Papers_Independent_Extend50_P01
Formal statement
noncomputable section

open scoped Matrix Kronecker ComplexConjugate Matrix.Norms.L2Operator Manifold ContDiff

open MeasureTheory

namespace QAlgorithms.Papers.Independent.Extend50.P01

attribute [local instance] Classical.propDecidable Classical.decEq

-- PDF pp.3,8: reuse the accepted operator type, exp(-itH), and A X A†.
-- Notation specializes the imported interfaces without introducing duplicate declarations.

local notation "Op" => (fun n : ℕ => QAlgorithms.Papers.Independent.Information100.P21.Op (Qubits n))

local notation "evolve" => QAlgorithms.Papers.Independent.Information100.P32.evolution

local notation "conjugate" => QAlgorithms.conjSuperop

-- PDF pp.3,10–11: the imported quadratic form is Re(psi† A psi).

local notation "expectation" => QAlgorithms.Papers.Independent.Information100.P21.quad

-- PDF pp.5,16–19: accepted active-wire operator, with identities on all spectators.

local notation "onWire" => QAlgorithms.Papers.Independent.Advance50.P49.onWire

-- PDF p.5: the imported phase-free Pauli tensor uses 0=I,1=X,2=Y,3=Z.

local notation "pauliWord" => QAlgorithms.Papers.Independent.Gap48.P33.pauliWord

/-- PDF pp.14–15, Eq.(92): quarter-turn invariance and output interval of the vehicle model.
Only the rotation group is used, and car orientations rotate as part of the scenario array. -/
theorem vehicle_construction
    (W : List (List ((Fin 3 → Fin 2 → ℝ) × (Fin 4 → ℝ)))) :
    vehicleGroup.carrier.ncard = 4 ∧
    (∀ s ∈ vehicleGroup, ∀ p, Commute (vehicleLayer p) (wireMatrix s)) ∧
    (∀ x : Fin 9 → ℝ, (∀ i, x i ∈ ({1,-1,-(1/3),1/3} : Set ℝ)) →
      vehiclePrediction W x ∈ Set.Icc 0 1 ∧ ∀ s ∈ vehicleGroup,
        vehiclePrediction W (featurePullback s x) = vehiclePrediction W x) := by sorry

end QAlgorithms.Papers.Independent.Extend50.P01

end
Source
Exploiting symmetry in variational quantum machine learning, arXiv:2205.06217v1, PDF p. 15, §V autonomous vehicle: C4-invariant nine-qubit regression model
Read-back

What the Lean code literally says, in plain math · gpt-6.1-sol

For every finite list WWW of finite lists of real parameter pairs (α,θ)(\alpha,\theta)(α,θ), where α:{0,1,2}×{0,1}→R\alpha:\{0,1,2\}\times\{0,1\}\to\mathbb Rα:{0,1,2}×{0,1}→R and θ:{0,1,2,3}→R\theta:\{0,1,2,3\}\to\mathbb Rθ:{0,1,2,3}→R, let GGG be the subgroup generated by r=(0 2 4 6)(1 3 5 7)r=(0\,2\,4\,6)(1\,3\,5\,7)r=(0246)(1357), fixing site 888, and let (Ps)y,z=1yi=zs−1(i) ∀i(P_s)_{y,z}=\mathbf1_{y_i=z_{s^{-1}(i)}\ \forall i}(Ps​)y,z​=1yi​=zs−1(i)​ ∀i​. Let X,Y,ZX,Y,ZX,Y,Z be the Pauli matrices, P1=diag⁡(0,1)P_1=\operatorname{diag}(0,1)P1​=diag(0,1), and AiA_iAi​ mean AAA on wire iii and identities elsewhere. Define D={(8,0),(8,2),(8,4),(8,6)}D=\{(8,0),(8,2),(8,4),(8,6)\}D={(8,0),(8,2),(8,4),(8,6)}, I={(1,8),(3,8),(5,8),(7,8)}I=\{(1,8),(3,8),(5,8),(7,8)\}I={(1,8),(3,8),(5,8),(7,8)}, C={(0,1),(2,3),(4,5),(6,7)}C=\{(0,1),(2,3),(4,5),(6,7)\}C={(0,1),(2,3),(4,5),(6,7)}, A={(0,7),(2,1),(4,3),(6,5)}A=\{(0,7),(2,1),(4,3),(6,5)\}A={(0,7),(2,1),(4,3),(6,5)}, and KZ(F)=∑(i,j)∈F(P1)iZjK_Z(F)=\sum_{(i,j)\in F}(P_1)_iZ_jKZ​(F)=∑(i,j)∈F​(P1​)i​Zj​. Give wire 888 class 000, even wires below 888 class 111, and odd wires class 222, denoting this by c(i)c(i)c(i). Define

L(α,θ)=e−iθ(3)KZ(D)/2e−iθ(2)KZ(I)/2e−iθ(1)KZ(A)/2e−iθ(0)KZ(C)/2⨂i(e−iα(c(i),1)Y/2e−iα(c(i),0)X/2).L(\alpha,\theta)=e^{-i\theta(3)K_Z(D)/2}e^{-i\theta(2)K_Z(I)/2} e^{-i\theta(1)K_Z(A)/2}e^{-i\theta(0)K_Z(C)/2} \bigotimes_i\left(e^{-i\alpha(c(i),1)Y/2}e^{-i\alpha(c(i),0)X/2}\right).L(α,θ)=e−iθ(3)KZ​(D)/2e−iθ(2)KZ​(I)/2e−iθ(1)KZ​(A)/2e−iθ(0)KZ​(C)/2i⨂​(e−iα(c(i),1)Y/2e−iα(c(i),0)X/2).

Put E(x)=⨂ie−iπxiX/3E(x)=\bigotimes_i e^{-i\pi x_iX/3}E(x)=⨂i​e−iπxi​X/3; for block b=(pb,1,…,pb,mb)b=(p_{b,1},\ldots,p_{b,m_b})b=(pb,1​,…,pb,mb​​), set Fb=L(pb,mb)⋯L(pb,1)E(x)F_b=L(p_{b,m_b})\cdots L(p_{b,1})E(x)Fb​=L(pb,mb​​)⋯L(pb,1​)E(x), and put QW(x)=Fr⋯F1Q_W(x)=F_r\cdots F_1QW​(x)=Fr​⋯F1​ for the rrr blocks. Empty products are identities. Define

vW(x)=expectation⁡(Z8,QW(x)∣09⟩)+12,v_W(x)=\frac{\operatorname{expectation}(Z_8,Q_W(x)|0^9\rangle)+1}{2},vW​(x)=2expectation(Z8​,QW​(x)∣09⟩)+1​,

where ∣09⟩|0^9\rangle∣09⟩ is the all-false basis vector and the defining formula for the operation named expectation is absent from the supplied code. Then GGG has exactly four elements, and L(p)Ps=PsL(p)L(p)P_s=P_sL(p)L(p)Ps​=Ps​L(p) for every s∈Gs\in Gs∈G and every parameter pair ppp. For every feature vector xxx whose coordinates lie in {1,−1,−1/3,1/3}\{1,-1,-1/3,1/3\}{1,−1,−1/3,1/3}, one has 0≤vW(x)≤10\le v_W(x)\le10≤vW​(x)≤1 and vW(x∘s−1)=vW(x)v_W(x\circ s^{-1})=v_W(x)vW​(x∘s−1)=vW​(x) for every s∈Gs\in Gs∈G. Empty outer and inner lists are included.

Human review
  • Endorsed by Shuze Chen · Oct 30, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Gohan · Oct 30, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me