ComparatorChallenges/Superstring.lean
Explanation legend Lean4 Domain Explanation Language (L4DEL)
L4DEL explanations are a separate layer. They do not change the Lean source. Intuition is explanatory prose; numbered items are a reading path; sources link the wording back to evidence.
- L4DEL
- Lean4 Domain Explanation Language
Credit: OpenAI's pinned repository says an unreleased internal model produced the manuscripts and supporting proof artifacts. The collection builds on the mathematics community's accumulated problems, results, language, and formal libraries; each manuscript's BibTeX and bibliography are the authority for individual scholarly credit.
Project sources: Pinned openai/math documentation, Pinned formalization catalogue
11 declarations, 1 contain sorry, 0 declared as axioms
- abbrev
OAI.Superstring.Symbolline 7Also declared: OAI/Computability/Superstring/Model.lean:7 (same declaration text).
- abbrev
OAI.Superstring.Wordline 8Also declared: OAI/Computability/Superstring/Model.lean:8 (same declaration text).
- abbrev
OAI.Superstring.Instanceline 9Also declared: OAI/Computability/Superstring/Model.lean:9 (same declaration text).
- def
OAI.Superstring.encodeListPrefix markers encode the list spine, including its final boundary line 12Source documentation
Prefix markers encode the list spine, including its final boundary.
L4DEL explanation
Prefix markers encode the list spine, including its final boundary.
- This explanation is a condensed rendering of the declaration's own doc comment at the pinned source commit; consult the exact Lean statement below for authority.
Sources and attribution: Pinned Lean source (fd4aeeb2ee4f)
Also declared: OAI/Computability/Superstring/Model.lean:12 (same declaration text).
def encodeList {α : Type} (enc : α → List Bool) : List α → List Bool | [] => [true] | a :: as => false :: (enc a ++ encodeList enc as) - def
OAI.Superstring.encodeSymbolline 16Also declared: OAI/Computability/Superstring/Model.lean:16 (same declaration text).
- def
OAI.Superstring.encodeWordline 17Also declared: OAI/Computability/Superstring/Model.lean:17 (same declaration text).
- def
OAI.Superstring.encodeInstanceline 18Also declared: OAI/Computability/Superstring/Model.lean:18 (same declaration text).
- def
OAI.Superstring.IsCommonSuperstringOrdinary contiguous substring containment, including the empty word line 21Source documentation
Ordinary contiguous substring containment, including the empty word.
L4DEL explanation
Ordinary contiguous substring containment, including the empty word.
- This explanation is a condensed rendering of the declaration's own doc comment at the pinned source commit; consult the exact Lean statement below for authority.
Sources and attribution: Pinned Lean source (fd4aeeb2ee4f)
Also declared: OAI/Computability/Superstring/Model.lean:21 (same declaration text).
def IsCommonSuperstring (S : Instance) (T : Word) : Prop := …
Mentions: OAI.Superstring.Instance, OAI.Superstring.Word
- def
OAI.Superstring.optThe optimum in symbols, not in bits line 25Source documentation
The optimum in symbols, not in bits.
L4DEL explanation
The optimum in symbols, not in bits.
- This explanation is a condensed rendering of the declaration's own doc comment at the pinned source commit; consult the exact Lean statement below for authority.
Sources and attribution: Pinned Lean source (fd4aeeb2ee4f)
Also declared: OAI/Computability/Superstring/Model.lean:25 (same declaration text).
noncomputable def opt (S : Instance) : ℕ := …
Mentions: OAI.Superstring.Instance
- def
OAI.Superstring.HasPolynomialImplementationA deterministic finite-stack-machine implementation, with a polynomial bound on bit-level running time in the explicitly encoded input length line 30Source documentation
A deterministic finite-stack-machine implementation, with a polynomial bound on bit-level running time in the explicitly encoded input length.
L4DEL explanation
A deterministic finite-stack-machine implementation, with a polynomial bound on bit-level running time in the explicitly encoded input length.
- This explanation is a condensed rendering of the declaration's own doc comment at the pinned source commit; consult the exact Lean statement below for authority.
Sources and attribution: Pinned Lean source (fd4aeeb2ee4f)
Also declared: OAI/Computability/Superstring/Model.lean:30 (same declaration text).
def HasPolynomialImplementation (f : Instance → Word) : Prop := …
Mentions: OAI.Superstring.Instance, OAI.Superstring.Word
- theorem
OAI.Superstring.mainChallenge statement: A factor-two approximation for shortest common superstring sorry line 36Source documentation
The deterministic algorithm with its exact finite-alphabet bit-machine certificate, contiguous coverage, and factor-two bound in symbols.
L4DEL explanation
The shortest common superstring problem asks for the shortest string containing each input string as a contiguous substring. The formalized result gives one deterministic polynomial-time algorithm whose output is a common superstring of length at most twice the unrestricted optimum. It applies to every finite list of explicitly encoded strings, with running time measured in input bits and the approximation ratio measured in symbol length.
- This is an exact comparator target linked by the pinned repository's formalization note for this result.
- The repository's comparator configuration selects OAI.Computability.Superstring.Main as the released solution module checked against this declaration.
Sources and attribution: Pinned Lean source (fd4aeeb2ee4f)
Distinct definitions of this name: OAI/Computability/Superstring/Main.lean:57 (same statement text; different proof or body). Qualify references as OAI.Superstring.main@path.
theorem main : ∃ f : Instance → Word, HasPolynomialImplementation f ∧ ∀ S, IsCommonSuperstring S (f S) ∧ (f S).length ≤ 2 * opt S := by …Mentions: OAI.Superstring.Instance, OAI.Superstring.Word, OAI.Superstring.HasPolynomialImplementation, OAI.Superstring.IsCommonSuperstring, OAI.Superstring.opt