{
 "gap": "L-meta-1415",
 "claim": "Restricted to the first mask T = 0x80000000 (the AND of all five inputs; bit 31 is the only set bit, sum index 31 = all inputs true). For every gates : List Gate and o : ℕ with every gate AND/OR/NOT of fan-in ≤ 2, at most one NOT gate, and Circuit.eval ⟨gates, o⟩ (List.ofFn x) = Nat.testBit 0x80000000 (∑ i : Fin 5, if x i then 2^i else 0) for all x : Fin 5 → Bool, there exist gates' and o' with only AND/OR gates of fan-in ≤ 2, gates'.length ≤ gates.length, computing the same function. Lean name: PEqualNP.MetaComplexity.LMeta1415Mask80000000.l_meta_1415_mask_80000000. The only extra hypothesis compared with the row is T = 0x80000000; the NOT-count hypothesis is not used.",
 "scope": "restricted",
 "evidence": "(1) Cone bound (lemma `cone`, induction on the gate list from the end): in a gate list gs where every gate reads at most two wires, for every list L of wire indices there is a finset S of input positions with |S| ≤ gs.length + L.length such that any two inputs x, y of length n agreeing (under getD … false) on S give equal values on every wire in L. Wires that do not exist read false (List.getD default), so out-of-range wires and an out-of-range output need no special case. Step for a new gate at wire N = n + gs.length: if N ∈ L, use L.erase N ++ g.inputs (length ≤ |L| - 1 + 2); otherwise keep L. Wires w < N keep their old values, wire N is op applied to its inputs, wires w > N read false. (2) `no_three`: with L = [o] and gates.length ≤ 3 we get |S| ≤ 4, so some input i in 0..4 is not in S. All-ones and all-ones-except-i agree on S, so the circuit gives the same value on both, but testBit 0x80000000 is true at index 31 and false at 31 - 2^i (checked by `decide` for each i : Fin 5, lemma `key`). Contradiction, so every circuit for this mask has at least 4 gates. (3) Four-AND implementation `andChain` = [and[0,1], and[5,2], and[6,3], and[7,4]] with output wire 8 computes x0∧x1∧x2∧x3∧x4. That it matches the posted comparison Nat.testBit 0x80000000 (∑ …) on all 32 inputs is checked by `decide`. Since 4 ≤ gates.length it satisfies gates'.length ≤ gates.length, and it uses only AND gates of fan-in 2. Built with lake build against the pinned Lean v4.36.0 and Mathlib fc4f59e577feb1a4956671bc04ac18aaaf8cd842 (repo commit e3b1828a). #print axioms shows only [propext, Classical.choice, Quot.sound]. There is no sorry and no native_decide. Status: the row is still listed under gaps in gaps.json (updated_at 2026-11-23T23:41:25.113Z) and is not in checked or withdrawn, so it is open.",
 "source": "import PEqualNP.Defs\n\n/-!\n# L-meta-1415, restricted: the mask `T = 0x80000000` (AND of all five inputs)\n\nRestricted result for the row L-meta-1415 (shard 01): only the first mask of the row's\nFinset, `T = 0x80000000`. No extra hypotheses beyond fixing `T`.\n\n* `cone`: in a gate list of fan-in at most two, the values of the wires in a list `L` are\n  determined by at most `gates.length + L.length` wire indices of the input (wires that do not\n  exist read `false`, which is handled by the `getD` semantics).\n* `no_three`: hence an output of a list with at most three gates depends on at most four inputs,\n  so it cannot compute the AND of five inputs.\n* `andChain`: four AND gates compute it, so any circuit for the mask has at least as many gates.\n-/\n\nnamespace PEqualNP.MetaComplexity.LMeta1415Mask80000000\n\nopen PEqualNP.CircuitLowerBounds\n\n/-- The wire values of a gate list (the fold of `Circuit.wires`). -/\ndef W (gs : List Gate) (x : List Bool) : List Bool :=\n  gs.foldl (fun w g => w ++ [g.op.eval (g.inputs.map fun i => w.getD i false)]) x\n\ntheorem W_snoc (gs : List Gate) (g : Gate) (x : List Bool) :\n    W (gs ++ [g]) x = W gs x ++ [g.op.eval (g.inputs.map fun i => (W gs x).getD i false)] := by\n  simp [W, List.foldl_append]\n\ntheorem W_length (gs : List Gate) (x : List Bool) : (W gs x).length = x.length + gs.length := by\n  induction gs using List.reverseRecOn with\n  | nil => simp [W]\n  | append_singleton gs g ih => rw [W_snoc]; simp [ih]; omega\n\ntheorem getD_snoc (l : List Bool) (v : Bool) (w : ℕ) :\n    (l ++ [v]).getD w false =\n      if w < l.length then l.getD w false else if w = l.length then v else false := by\n  split_ifs with h1 h2\n  · simp [List.getD_eq_getElem?_getD, List.getElem?_append_left h1]\n  · subst h2; simp [List.getD_eq_getElem?_getD]\n  · rw [List.getD_eq_default]; simp; omega\n\n/-- Cone bound: the wires in `L` depend on at most `gs.length + L.length` input positions. -/\ntheorem cone (n : ℕ) (gs : List Gate) (hfan : ∀ g ∈ gs, g.inputs.length ≤ 2) :\n    ∀ L : List ℕ, ∃ S : Finset ℕ, S.card ≤ gs.length + L.length ∧\n      ∀ x y : List Bool, x.length = n → y.length = n →\n        (∀ i ∈ S, x.getD i false = y.getD i false) →\n        ∀ w ∈ L, (W gs x).getD w false = (W gs y).getD w false := by\n  induction gs using List.reverseRecOn with\n  | nil =>\n    intro L\n    refine ⟨L.toFinset, by simpa using List.toFinset_card_le L, ?_⟩\n    intro x y _ _ hag w hw\n    simpa [W] using hag w (List.mem_toFinset.mpr hw)\n  | append_singleton gs g ih =>\n    have hfan' : ∀ g' ∈ gs, g'.inputs.length ≤ 2 := fun g' hg' => hfan g' (by simp [hg'])\n    have hg : g.inputs.length ≤ 2 := hfan g (by simp)\n    intro L\n    by_cases hN : n + gs.length ∈ L\n    · obtain ⟨S, hS, hag⟩ := ih hfan' (L.erase (n + gs.length) ++ g.inputs)\n      refine ⟨S, ?_, ?_⟩\n      · have hpos : 0 < L.length := List.length_pos_of_mem hN\n        simp [List.length_erase_of_mem hN] at hS\n        simp; omega\n      · intro x y hx hy hxy w hw\n        rw [W_snoc, W_snoc, getD_snoc, getD_snoc, W_length, W_length, hx, hy]\n        split_ifs with h1 h2\n        · apply hag x y hx hy hxy\n          exact List.mem_append_left _ ((List.mem_erase_of_ne (by omega)).mpr hw)\n        · congr 1\n          apply List.map_congr_left\n          intro i hi\n          exact hag x y hx hy hxy i (List.mem_append_right _ hi)\n        · rfl\n    · obtain ⟨S, hS, hag⟩ := ih hfan' L\n      refine ⟨S, by simp; omega, ?_⟩\n      intro x y hx hy hxy w hw\n      rw [W_snoc, W_snoc, getD_snoc, getD_snoc, W_length, W_length, hx, hy]\n      split_ifs with h1 h2\n      · exact hag x y hx hy hxy w hw\n      · exact absurd (h2 ▸ hw) hN\n      · rfl\n\ntheorem key : ∀ i : Fin 5,\n    Nat.testBit 0x80000000 (∑ k : Fin 5, if (fun _ => true : Fin 5 → Bool) k then 2 ^ (k : ℕ) else 0) ≠\n    Nat.testBit 0x80000000 (∑ k : Fin 5, if (fun k => decide (k ≠ i)) k then 2 ^ (k : ℕ) else 0) := by\n  decide\n\n/-- A fan-in-two list with at most three gates has no output computing the mask. -/\ntheorem no_three (gates : List Gate) (o : ℕ) (hfan : ∀ g ∈ gates, g.inputs.length ≤ 2)\n    (hlen : gates.length ≤ 3) :\n    ¬ ∀ x : Fin 5 → Bool, Circuit.eval ⟨gates, o⟩ (List.ofFn x) =\n        Nat.testBit 0x80000000 (∑ i : Fin 5, if x i then 2 ^ (i : ℕ) else 0) := by\n  intro h\n  obtain ⟨S, hS, hag⟩ := cone 5 gates hfan [o]\n  simp at hS\n  have hex : ∃ i : Fin 5, (i : ℕ) ∉ S := by\n    by_contra hc\n    push Not at hc\n    have hsub : (Finset.univ.image (fun i : Fin 5 => (i : ℕ))) ⊆ S := by\n      intro a ha\n      simp only [Finset.mem_image, Finset.mem_univ, true_and] at ha\n      obtain ⟨i, rfl⟩ := ha\n      exact hc i\n    have h5 : (Finset.univ.image (fun i : Fin 5 => (i : ℕ))).card = 5 := by\n      rw [Finset.card_image_of_injective _ Fin.val_injective]; simp\n    have := Finset.card_le_card hsub\n    omega\n  obtain ⟨i, hi⟩ := hex\n  have hagree : ∀ j ∈ S, (List.ofFn (n := 5) fun _ => true).getD j false =\n      (List.ofFn (n := 5) fun k => decide (k ≠ i)).getD j false := by\n    intro j hj\n    have hji : j ≠ (i : ℕ) := fun hc => hi (hc ▸ hj)\n    by_cases hj5 : j < 5\n    · simp only [List.getD_eq_getElem?_getD, List.getElem?_ofFn, hj5,\n        dite_true, Option.getD_some]\n      have : (⟨j, hj5⟩ : Fin 5) ≠ i := fun hc => hji (by rw [← hc])\n      simp [this]\n    · rw [List.getD_eq_default _ _ (by simp; omega), List.getD_eq_default _ _ (by simp; omega)]\n  have e := hag (List.ofFn (n := 5) fun _ => true) (List.ofFn (n := 5) fun k => decide (k ≠ i))\n    (List.length_ofFn) (List.length_ofFn) hagree o (List.mem_singleton_self o)\n  have h1 := h (fun _ => true)\n  have h2 := h (fun k => decide (k ≠ i))\n  have e1 : Circuit.eval ⟨gates, o⟩ (List.ofFn (n := 5) fun _ => true) =\n      (W gates (List.ofFn (n := 5) fun _ => true)).getD o false := rfl\n  have e2 : Circuit.eval ⟨gates, o⟩ (List.ofFn (n := 5) fun k => decide (k ≠ i)) =\n      (W gates (List.ofFn (n := 5) fun k => decide (k ≠ i))).getD o false := rfl\n  rw [← e1, ← e2, h1, h2] at e\n  exact key i e\n\n/-- The four-AND implementation. -/\ndef andChain : List Gate :=\n  [⟨GateOp.and, [0, 1]⟩, ⟨GateOp.and, [5, 2]⟩, ⟨GateOp.and, [6, 3]⟩, ⟨GateOp.and, [7, 4]⟩]\n\ntheorem andChain_eval : ∀ x : Fin 5 → Bool, Circuit.eval ⟨andChain, 8⟩ (List.ofFn x) =\n    Nat.testBit 0x80000000 (∑ i : Fin 5, if x i then 2 ^ (i : ℕ) else 0) := by\n  decide\n\n/-- L-meta-1415 restricted to the first mask `T = 0x80000000`. -/\ntheorem l_meta_1415_mask_80000000 :\n    ∀ (gates : List PEqualNP.CircuitLowerBounds.Gate) (o : ℕ), (∀ g ∈ gates, (g.op = PEqualNP.CircuitLowerBounds.GateOp.and ∨ g.op = PEqualNP.CircuitLowerBounds.GateOp.or ∨ g.op = PEqualNP.CircuitLowerBounds.GateOp.not) ∧ g.inputs.length ≤ 2) → (∀ i j : Fin gates.length, (gates.get i).op = PEqualNP.CircuitLowerBounds.GateOp.not → (gates.get j).op = PEqualNP.CircuitLowerBounds.GateOp.not → i = j) → (∀ x : Fin 5 → Bool, PEqualNP.CircuitLowerBounds.Circuit.eval ⟨gates, o⟩ (List.ofFn x) = Nat.testBit 0x80000000 (∑ i : Fin 5, if x i then 2 ^ (i : ℕ) else 0)) → ∃ (gates' : List PEqualNP.CircuitLowerBounds.Gate) (o' : ℕ), (∀ g ∈ gates', (g.op = PEqualNP.CircuitLowerBounds.GateOp.and ∨ g.op = PEqualNP.CircuitLowerBounds.GateOp.or) ∧ g.inputs.length ≤ 2) ∧ gates'.length ≤ gates.length ∧ ∀ x : Fin 5 → Bool, PEqualNP.CircuitLowerBounds.Circuit.eval ⟨gates', o'⟩ (List.ofFn x) = Nat.testBit 0x80000000 (∑ i : Fin 5, if x i then 2 ^ (i : ℕ) else 0) := by\n  intro gates o hops _hnot heval\n  refine ⟨andChain, 8, ?_, ?_, andChain_eval⟩\n  · intro g hg\n    simp [andChain] at hg\n    rcases hg with rfl | rfl | rfl | rfl <;> simp\n  · by_contra hc\n    push Not at hc\n    have hlen : gates.length ≤ 3 := by simp [andChain] at hc; omega\n    exact no_three gates o (fun g hg => (hops g hg).2) hlen heval\n\nend PEqualNP.MetaComplexity.LMeta1415Mask80000000\n",
 "validation": "helper-built",
 "remaining": "The other nine masks of shard 01 (0x80808000, 0x88808000, 0x88808080, 0xa8808000, 0xa8808080, 0xe8808000, 0x88888880, 0xa8808880, 0xa888a000). Each needs its monotone (AND/OR) formula size compared with a lower bound on AND/OR/NOT circuits with at most one NOT: first, for T = 0x80808000, a monotone implementation and a proof that no AND/OR/NOT list with at most one NOT and fewer gates computes it. Then all ten cases are combined in lean/PEqualNP/Outside/L_meta_1415.lean (module PEqualNP.Outside.L_meta_1415, import PEqualNP.Defs) and checked with tools/check-lean.mjs. The `cone` lemma here can be reused for the essential-input part of those bounds.",
 "sources": [
  "https://data.pequalnp.com/data/desk/gaps.json",
  "https://github.com/brilliant-hq/pequalnp-proofs/tree/e3b1828a4423909b34c8d8184be1e208451c631a",
  "https://raw.githubusercontent.com/brilliant-hq/pequalnp-proofs/e3b1828a4423909b34c8d8184be1e208451c631a/lean/PEqualNP/Defs/CircuitLowerBounds.lean"
 ]
}