Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Jones unknot combined scratch (public, to be deprecated)

Definition
JUTestPub_all

by LG · Nov 17, 2026 · Mathlib 0df444a (Lean v4.33.1)

knot-theory
Definition code
import Mathlib
import Definitions.Def_ManolescuPiccirillo_PD
import Definitions.Def_ManolescuPiccirillo_Kirby
import Definitions.Def_ManolescuPiccirillo_Lee1
open Classical
noncomputable section
namespace JonesUnknot
open ManolescuPiccirillo

abbrev Dart (D : PD) := Fin D.crossings.length × Fin 4
def dartLabel (D : PD) (d : Dart D) : ℕ := D.crossings.get d.1 d.2
def edgePartner (D : PD) (d : Dart D) : Dart D :=
  if h : ∃ e : Dart D, e ≠ d ∧ dartLabel D e = dartLabel D d then Classical.choose h else d
def rotate (D : PD) (d : Dart D) : Dart D := (d.1, d.2 + 1)
def faceSucc (D : PD) (d : Dart D) : Dart D := rotate D (edgePartner D d)
def faceGraph (D : PD) : SimpleGraph (Dart D) :=
  SimpleGraph.fromRel (fun d e => faceSucc D d = e ∧ d ≠ e)
def faceCount (D : PD) : ℕ :=
  if D.crossings = [] then 2 else Fintype.card (faceGraph D).ConnectedComponent
def Planar (D : PD) : Prop := faceCount D = D.numCrossings + 2
def strandPair (D : PD) (d : Dart D) : Dart D := (d.1, d.2 + 2)
def strandSucc (D : PD) (d : Dart D) : Dart D := edgePartner D (strandPair D d)
def strandGraph (D : PD) : SimpleGraph (Dart D) :=
  SimpleGraph.fromRel (fun d e => strandSucc D d = e ∧ d ≠ e)
def overIn3 (D : PD) (c : Fin D.crossings.length) : Prop :=
  Relation.ReflTransGen (strandGraph D).Adj (c, 0) (c, 3)
def crossingSign (D : PD) (c : Fin D.crossings.length) : ℤ :=
  if overIn3 D c then 1 else -1
def writhe (D : PD) : ℤ := ∑ c : Fin D.crossings.length, crossingSign D c

abbrev LP := AddMonoidAlgebra ℤ ℤ
def delta : LP := -AddMonoidAlgebra.single 2 1 - AddMonoidAlgebra.single (-2) 1
def stateLoops (D : PD) (s : Fin D.numCrossings → Bool) : ℕ :=
  if D.crossings = [] then 1 else Fintype.card (D.stateGraph s).ConnectedComponent
def kauffmanBracket (D : PD) : LP :=
  ∑ s : Fin D.numCrossings → Bool,
    AddMonoidAlgebra.single ((2 * D.numTrue s : ℤ) - D.numCrossings) 1 *
      delta ^ (stateLoops D s - 1)
def jonesA (D : PD) : LP :=
  AddMonoidAlgebra.single (-3 * writhe D) (if Even (writhe D) then 1 else -1) *
    kauffmanBracket D

def seifertPairs (D : PD) : List (ℕ × ℕ) :=
  (List.ofFn (fun i : Fin D.crossings.length =>
    let c := D.crossings.get i
    if overIn3 D i then [(c 0, c 1), (c 2, c 3)] else [(c 0, c 3), (c 1, c 2)])).flatMap id
def seifertPaired (D : PD) (x y : ℕ) : Prop :=
  (x, y) ∈ seifertPairs D ∨ (y, x) ∈ seifertPairs D
def seifertGraph (D : PD) : SimpleGraph D.labels :=
  SimpleGraph.fromRel (fun x y => seifertPaired D x.val y.val ∧ x ≠ y)
def seifertCircles (D : PD) : ℕ :=
  if D.crossings = [] then 1 else Fintype.card (seifertGraph D).ConnectedComponent
def seifertAlgGenus (D : PD) : ℕ := (D.numCrossings - seifertCircles D + 1) / 2
def seifertGenus (D : PD) : ℕ :=
  sInf {g : ℕ | ∃ D', D.ReidemeisterEquiv D' ∧ seifertAlgGenus D' = g}
def Reduced (D : PD) : Prop :=
  ¬ ∃ D', (D.R1 D' ∨ D.R2 D') ∧ D'.numCrossings < D.numCrossings
def IsInDart (D : PD) (d : Dart D) : Prop :=
  d.2 = 0 ∨ (d.2 = 1 ∧ ¬ overIn3 D d.1) ∨ (d.2 = 3 ∧ overIn3 D d.1)
def Alternating (D : PD) : Prop :=
  ∀ d : Dart D, IsInDart D d → ((d.2 = 0) ≠ ((strandSucc D d).2 = 0))

end JonesUnknot

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