AFTD Auto-Formalizing Theoretical Domains

cyclic_cubic_family_nonempty

theoremverified

For every n ≥ 6, every member of cyclic_cubic_family n is nonempty.

Statement

theorem cyclic_cubic_family_nonempty (n : ℕ) (hn : 6 ≤ n) : ∀ y ∈ cyclic_cubic_family n, y.Nonempty
Source
step towards cyclic_cubic_t_count_upper_bound
Verified
30 Oct 2026
Axioms
Classical.choiceQuot.soundpropext
Built on 1
  • cyclic_cubic_familyThe explicit parametric parity family on n qubits consists of 10 boundary parities (Group A), 2(n-4) running parities (Group B), and 3…

The proof, explained

This is a real proof sketch: every member is proved nonempty by case analysis. Each member comes from one of three families, and for every case an explicit element is provided using the helper lemma.

  1. test 1

    test 1

    lines 3–4

      use ⟨k, hk⟩
      simp [hs]
  2. test 2

    test 2

    lines 8–34

      intro y hy
      unfold cyclic_cubic_family at hy
      simp only [Finset.mem_image] at hy
      rcases hy with ⟨s, hs, rfl⟩
      simp only [Finset.mem_union] at hs
      rcases hs with (hsA | hsB) | hsC
      · simp only [Finset.mem_insert, Finset.mem_singleton] at hsA
        rcases hsA with rfl | rfl | rfl | rfl | rfl | rfl | rfl | rfl | rfl | rfl
        · exact cyclic_cubic_family_nonempty_helper n _ 1 (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ (n - 3) (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ (n - 3) (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ 1 (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ (n - 4) (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ (n - 4) (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp)
      · simp only [Finset.mem_biUnion, Finset.mem_Iic, Finset.mem_insert, Finset.mem_singleton] at hsB
        rcases hsB with ⟨k, hk, rfl | rfl⟩
        · exact cyclic_cubic_family_nonempty_helper n _ k (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ k (by omega) (by simp)
      · simp only [Finset.mem_insert, Finset.mem_singleton] at hsC
        rcases hsC with rfl | rfl | rfl
        · exact cyclic_cubic_family_nonempty_helper n _ 2 (by omega) (by simp; omega)
        · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp)
        · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp; omega)

Written by a model (gemini-3.8-flash) from the Lean proof and the goal states Lean reported at each step. Lean verified the proof; this explanation is a reading aid and is not itself machine-checked.

Lean source view module on GitHub

lemma cyclic_cubic_family_nonempty_helper (n : ℕ) (s : Finset ℕ) (k : ℕ) (hk : k < n) (hs : k ∈ s) :    ({i : Fin n | (i : ℕ) ∈ s} : Finset (Fin n)).Nonempty := by  use ⟨k, hk⟩  simp [hs]/-- Every parity in cyclic_cubic_family n is nonempty for n ≥ 6. -/theorem cyclic_cubic_family_nonempty (n : ℕ) (hn : 6 ≤ n) : ∀ y ∈ cyclic_cubic_family n, y.Nonempty := by  intro y hy  unfold cyclic_cubic_family at hy  simp only [Finset.mem_image] at hy  rcases hy with ⟨s, hs, rfl⟩  simp only [Finset.mem_union] at hs  rcases hs with (hsA | hsB) | hsC  · simp only [Finset.mem_insert, Finset.mem_singleton] at hsA    rcases hsA with rfl | rfl | rfl | rfl | rfl | rfl | rfl | rfl | rfl | rfl    · exact cyclic_cubic_family_nonempty_helper n _ 1 (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ (n - 3) (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ (n - 3) (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ 1 (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ (n - 4) (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ (n - 4) (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp)  · simp only [Finset.mem_biUnion, Finset.mem_Iic, Finset.mem_insert, Finset.mem_singleton] at hsB    rcases hsB with ⟨k, hk, rfl | rfl⟩    · exact cyclic_cubic_family_nonempty_helper n _ k (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ k (by omega) (by simp)  · simp only [Finset.mem_insert, Finset.mem_singleton] at hsC    rcases hsC with rfl | rfl | rfl    · exact cyclic_cubic_family_nonempty_helper n _ 2 (by omega) (by simp; omega)    · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp)    · exact cyclic_cubic_family_nonempty_helper n _ 0 (by omega) (by simp; omega)
See it in the graphDiscuss this resultChallenge it