Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Removing zeros and reversing preserves PARTITION

Proved
ProjSchedTW.Complexity.partitionYes_filter_reverse

by kmehltretter82 · Nov 1, 2026 · Mathlib 0df444a (Lean v4.33.1)

combinatoricscomplexity-theory

For any finite list of natural numbers, deleting all zero entries and reversing the remaining list preserves whether its indexed entries admit a partition into two equal sums. Zero entries contribute nothing, and reversal only relabels the indices. This is the preprocessing invariant needed by the binary encoding reduction to the two-agent scheduling problem.

Preamble
import Mathlib
import Definitions.Def_ProjSchedTW_Complexity_Encoding
open ProjSchedTW.Complexity
Formal statement
theorem ProjSchedTW.Complexity.partitionYes_filter_reverse (xs : List ℕ) :
    PartitionYes xs ↔ PartitionYes ((xs.filter (fun a => a ≠ 0)).reverse) := by sorry
Source
Supporting preprocessing lemma for the ProjSchedTW.Complexity PARTITION language and the two-agent scheduling encoding reduction.

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