Sensitivity separation: Endpoint40ClosureProof2 (complete source module)
DefinitionBS2_b3ba934b_Endpoint40ClosureProof2block-sensitivitysensitivitysensitivity-first-two-20261025
Complete Lean source module Endpoint40ClosureProof2 from the two verified sensitivity separation proofs. The module supplies the definitions, auxiliary lemmas, and exact finite certificates used by its dependent modules. All original declarations and proof bodies are retained; only local import module paths are changed for Prove2Me. The final campaign goals are published separately as theorems with submitted solutions.
Definition code
import Definitions.Def_BS2_b3ba934b_Endpoint40ClosureData2
import Mathlib.Tactic.FinCases
set_option autoImplicit false
set_option Elab.async false
set_option maxRecDepth 2000000
set_option maxHeartbeats 0
namespace ThreeBoundNumeric.Endpoint40
open ThreeBoundProfiles ThreeBoundFullProfile ClosureCertificate
private theorem node_chunk_2_0 :
checkInterval (checkNode rawProfile2 nodes2) 13860 13980=true := by decide +kernel
private theorem node_chunk_2_1 :
checkInterval (checkNode rawProfile2 nodes2) 13980 14100=true := by decide +kernel
private theorem node_chunk_2_2 :
checkInterval (checkNode rawProfile2 nodes2) 14100 14220=true := by decide +kernel
private theorem node_chunk_2_3 :
checkInterval (checkNode rawProfile2 nodes2) 14220 14340=true := by decide +kernel
private theorem node_chunk_2_4 :
checkInterval (checkNode rawProfile2 nodes2) 14340 14460=true := by decide +kernel
private theorem node_chunk_2_5 :
checkInterval (checkNode rawProfile2 nodes2) 14460 14580=true := by decide +kernel
private theorem node_chunk_2_6 :
checkInterval (checkNode rawProfile2 nodes2) 14580 14700=true := by decide +kernel
private theorem node_chunk_2_7 :
checkInterval (checkNode rawProfile2 nodes2) 14700 14820=true := by decide +kernel
private theorem node_chunk_2_8 :
checkInterval (checkNode rawProfile2 nodes2) 14820 14940=true := by decide +kernel
private theorem node_chunk_2_9 :
checkInterval (checkNode rawProfile2 nodes2) 14940 15060=true := by decide +kernel
private theorem node_chunk_2_10 :
checkInterval (checkNode rawProfile2 nodes2) 15060 15180=true := by decide +kernel
private theorem node_chunk_2_11 :
checkInterval (checkNode rawProfile2 nodes2) 15180 15300=true := by decide +kernel
private theorem node_chunk_2_12 :
checkInterval (checkNode rawProfile2 nodes2) 15300 15420=true := by decide +kernel
theorem new_nodes_checked2 :
checkInterval (checkNode rawProfile2 nodes2) 13860 nodeCount2=true :=
(checkInterval_join _ 13860 14580 15420 (checkInterval_join _ 13860 14220 14580 (checkInterval_join _ 13860 13980 14220 node_chunk_2_0 (checkInterval_join _ 13980 14100 14220 node_chunk_2_1 node_chunk_2_2)) (checkInterval_join _ 14220 14340 14580 node_chunk_2_3 (checkInterval_join _ 14340 14460 14580 node_chunk_2_4 node_chunk_2_5))) (checkInterval_join _ 14580 14940 15420 (checkInterval_join _ 14580 14700 14940 node_chunk_2_6 (checkInterval_join _ 14700 14820 14940 node_chunk_2_7 node_chunk_2_8)) (checkInterval_join _ 14940 15180 15420 (checkInterval_join _ 14940 15060 15180 node_chunk_2_9 node_chunk_2_10) (checkInterval_join _ 15180 15300 15420 node_chunk_2_11 node_chunk_2_12))))
theorem nodes_pointwise_checked2 (k : ℕ) (hk : k<nodeCount2) :
checkNode rawProfile2 nodes2 k=true := by
by_cases hbase : k<13860
· simp [checkNode,nodes2,hbase]
· exact checkInterval_sound _ _ _ new_nodes_checked2 k (by omega) hk
private theorem ab_chunk_2_0 : ∀ j : Fin 40, (0 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 0 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 0 j)=true := by
decide +kernel
private theorem ab_chunk_2_1 : ∀ j : Fin 40, (1 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 1 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 1 j)=true := by
decide +kernel
private theorem ab_chunk_2_2 : ∀ j : Fin 40, (2 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 2 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 2 j)=true := by
decide +kernel
private theorem ab_chunk_2_3 : ∀ j : Fin 40, (3 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 3 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 3 j)=true := by
decide +kernel
private theorem ab_chunk_2_4 : ∀ j : Fin 40, (4 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 4 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 4 j)=true := by
decide +kernel
private theorem ab_chunk_2_5 : ∀ j : Fin 40, (5 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 5 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 5 j)=true := by
decide +kernel
private theorem ab_chunk_2_6 : ∀ j : Fin 40, (6 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 6 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 6 j)=true := by
decide +kernel
private theorem ab_chunk_2_7 : ∀ j : Fin 40, (7 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 7 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 7 j)=true := by
decide +kernel
private theorem ab_chunk_2_8 : ∀ j : Fin 40, (8 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 8 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 8 j)=true := by
decide +kernel
private theorem ab_chunk_2_9 : ∀ j : Fin 40, (9 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 9 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 9 j)=true := by
decide +kernel
private theorem ab_chunk_2_10 : ∀ j : Fin 40, (10 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 10 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 10 j)=true := by
decide +kernel
private theorem ab_chunk_2_11 : ∀ j : Fin 40, (11 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 11 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 11 j)=true := by
decide +kernel
private theorem ab_chunk_2_12 : ∀ j : Fin 40, (12 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 12 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 12 j)=true := by
decide +kernel
private theorem ab_chunk_2_13 : ∀ j : Fin 40, (13 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 13 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 13 j)=true := by
decide +kernel
private theorem ab_chunk_2_14 : ∀ j : Fin 40, (14 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 14 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 14 j)=true := by
decide +kernel
private theorem ab_chunk_2_15 : ∀ j : Fin 40, (15 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 15 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 15 j)=true := by
decide +kernel
private theorem ab_chunk_2_16 : ∀ j : Fin 40, (16 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 16 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 16 j)=true := by
decide +kernel
private theorem ab_chunk_2_17 : ∀ j : Fin 40, (17 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 17 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 17 j)=true := by
decide +kernel
private theorem ab_chunk_2_18 : ∀ j : Fin 40, (18 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 18 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 18 j)=true := by
decide +kernel
private theorem ab_chunk_2_19 : ∀ j : Fin 40, (19 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 19 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 19 j)=true := by
decide +kernel
private theorem ab_chunk_2_20 : ∀ j : Fin 40, (20 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 20 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 20 j)=true := by
decide +kernel
private theorem ab_chunk_2_21 : ∀ j : Fin 40, (21 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 21 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 21 j)=true := by
decide +kernel
private theorem ab_chunk_2_22 : ∀ j : Fin 40, (22 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 22 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 22 j)=true := by
decide +kernel
private theorem ab_chunk_2_23 : ∀ j : Fin 40, (23 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 23 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 23 j)=true := by
decide +kernel
private theorem ab_chunk_2_24 : ∀ j : Fin 40, (24 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 24 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 24 j)=true := by
decide +kernel
private theorem ab_chunk_2_25 : ∀ j : Fin 40, (25 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 25 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 25 j)=true := by
decide +kernel
private theorem ab_chunk_2_26 : ∀ j : Fin 40, (26 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 26 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 26 j)=true := by
decide +kernel
private theorem ab_chunk_2_27 : ∀ j : Fin 40, (27 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 27 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 27 j)=true := by
decide +kernel
private theorem ab_chunk_2_28 : ∀ j : Fin 40, (28 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 28 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 28 j)=true := by
decide +kernel
private theorem ab_chunk_2_29 : ∀ j : Fin 40, (29 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 29 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 29 j)=true := by
decide +kernel
private theorem ab_chunk_2_30 : ∀ j : Fin 40, (30 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 30 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 30 j)=true := by
decide +kernel
private theorem ab_chunk_2_31 : ∀ j : Fin 40, (31 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 31 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 31 j)=true := by
decide +kernel
private theorem ab_chunk_2_32 : ∀ j : Fin 40, (32 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 32 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 32 j)=true := by
decide +kernel
private theorem ab_chunk_2_33 : ∀ j : Fin 40, (33 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 33 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 33 j)=true := by
decide +kernel
private theorem ab_chunk_2_34 : ∀ j : Fin 40, (34 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 34 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 34 j)=true := by
decide +kernel
private theorem ab_chunk_2_35 : ∀ j : Fin 40, (35 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 35 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 35 j)=true := by
decide +kernel
private theorem ab_chunk_2_36 : ∀ j : Fin 40, (36 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 36 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 36 j)=true := by
decide +kernel
private theorem ab_chunk_2_37 : ∀ j : Fin 40, (37 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 37 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 37 j)=true := by
decide +kernel
private theorem ab_chunk_2_38 : ∀ j : Fin 40, (38 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 38 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 38 j)=true := by
decide +kernel
private theorem ab_chunk_2_39 : ∀ j : Fin 40, (39 : Fin 40)≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a 39 j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b 39 j)=true := by
decide +kernel
theorem ab_checked2 : ∀ i j : Fin 40, i≤j →
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.a i j)=true ∧
checkOutputAt nodes2 nodeCount2 outputIndex2 profile3 (.b i j)=true := by
intro i
fin_cases i
· exact ab_chunk_2_0
· exact ab_chunk_2_1
· exact ab_chunk_2_2
· exact ab_chunk_2_3
· exact ab_chunk_2_4
· exact ab_chunk_2_5
· exact ab_chunk_2_6
· exact ab_chunk_2_7
· exact ab_chunk_2_8
· exact ab_chunk_2_9
· exact ab_chunk_2_10
· exact ab_chunk_2_11
· exact ab_chunk_2_12
· exact ab_chunk_2_13
· exact ab_chunk_2_14
· exact ab_chunk_2_15
· exact ab_chunk_2_16
· exact ab_chunk_2_17
· exact ab_chunk_2_18
· exact ab_chunk_2_19
· exact ab_chunk_2_20
· exact ab_chunk_2_21
· exact ab_chunk_2_22
· exact ab_chunk_2_23
· exact ab_chunk_2_24
· exact ab_chunk_2_25
· exact ab_chunk_2_26
· exact ab_chunk_2_27
· exact ab_chunk_2_28
· exact ab_chunk_2_29
· exact ab_chunk_2_30
· exact ab_chunk_2_31
· exact ab_chunk_2_32
· exact ab_chunk_2_33
· exact ab_chunk_2_34
· exact ab_chunk_2_35
· exact ab_chunk_2_36
· exact ab_chunk_2_37
· exact ab_chunk_2_38
· exact ab_chunk_2_39
theorem gap_share2 (coord : Coord 40) (h : 1640≤flatIndex coord) :
profile3 coord=rawProfile2 coord := by
change (if flatIndex coord<1640 then _ else gapTable3.get (flatIndex coord)) =
(if flatIndex coord<1640 then _ else gapTable3.get (flatIndex coord))
simp only [if_neg (Nat.not_lt_of_ge h)]
theorem closure2_sound {I : Type} [Fintype I]
(F : Fin 40 → (I → Bool) → Bool) (hF : Nested F) (c : ℕ)
(hi : Upper F (scale c rawProfile2)) : Upper F (scale c profile3) := by
intro coord
cases coord with
| a i j =>
intro hij
exact outputAt_sound F hF rawProfile2 profile3 nodes2 nodeCount2 c
outputIndex2 (.a i j) hi nodes_pointwise_checked2 (ab_checked2 i j hij).1 hij
| b i j =>
intro hij
exact outputAt_sound F hF rawProfile2 profile3 nodes2 nodeCount2 c
outputIndex2 (.b i j) hi nodes_pointwise_checked2 (ab_checked2 i j hij).2 hij
| m i j =>
have hidx : 1640≤flatIndex (Coord.m i j) := by simp only [flatIndex,mIndex]; omega
simpa only [scale,gap_share2 _ hidx] using hi (.m i j)
| p j l =>
have hidx : 1640≤flatIndex (Coord.p j l) := by simp only [flatIndex,pIndex]; omega
simpa only [scale,gap_share2 _ hidx] using hi (.p j l)
| d i j l =>
have hidx : 1640≤flatIndex (Coord.d i j l) := by simp only [flatIndex,dIndex]; omega
simpa only [scale,gap_share2 _ hidx] using hi (.d i j l)
end ThreeBoundNumeric.Endpoint40
#print axioms ThreeBoundNumeric.Endpoint40.new_nodes_checked2
#print axioms ThreeBoundNumeric.Endpoint40.ab_checked2
#print axioms ThreeBoundNumeric.Endpoint40.closure2_sound
Source
Attached verified checkpoint block_sensitivity_three_bounds; lean_project/Endpoint40ClosureProof2.lean; original SHA-256 84a94c07a89b19b720455efd6cfb997f60719417fcc855594c9b3e6d3bf0bc9b; campaign https://prove2.me/campaigns/block-sensitivity-vs-sensitivity