Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Finite Planar Clockwise Successor Sectors

Open
FinitePlanarClockwiseSuccessorSectors

by moona3k · Oct 4, 2026 · Mathlib 0df444a (Lean v4.33.1)

crossing-consequencestrellis-port

Let ι\iotaι be a nonempty finite set, let p∈R2p\in\mathbb R^2p∈R2, let ρ>0\rho>0ρ>0, and assign to every i∈ιi\in\iotai∈ι a nonzero direction ui∈R2u_i\in\mathbb R^2ui​∈R2. Assume distinct indices determine distinct positive rays: if uj=tuiu_j=t u_iuj​=tui​ for some t>0t>0t>0, then j=ij=ij=i. Then there are a permutation next⁡\operatorname{next}next of ι\iotaι, a full clockwise turn T=2πT=2\piT=2π, positive clockwise turns T(i,j)∈(0,T]T(i,j)\in(0,T]T(i,j)∈(0,T], and sets Σi⊂R2\Sigma_i\subset\mathbb R^2Σi​⊂R2 with the following properties.

The full turn occurs exactly on the same germ,

T(i,j)=T⟺j=i,T(i,j)=T \quad\Longleftrightarrow\quad j=i,T(i,j)=T⟺j=i,

next⁡(i)\operatorname{next}(i)next(i) has minimal positive clockwise turn from iii, and

next⁡(i)=i⟺i is the only element of ι. \operatorname{next}(i)=i \quad\Longleftrightarrow\quad \text{$i$ is the only element of $\iota$}.next(i)=i⟺i is the only element of ι.

If iii is the only germ, then

Σi=B(p,ρ)∖({p+tui:t>0}∪{p}).\Sigma_i= B(p,\rho)\setminus \bigl(\{p+t u_i:t>0\}\cup\{p\}\bigr).Σi​=B(p,ρ)∖({p+tui​:t>0}∪{p}).

Otherwise there are real numbers ci,sic_i,s_ici​,si​, with si≠0s_i\ne0si​=0 or ci<0c_i<0ci​<0, such that

unext⁡(i)=ciui−sirot⁡90(ui).u_{\operatorname{next}(i)} =c_i u_i-s_i\operatorname{rot}_{90}(u_i).unext(i)​=ci​ui​−si​rot90​(ui​).

Writing

Φi(x,y)=p+xui+yrot⁡90(ui),\Phi_i(x,y)=p+xu_i+y\operatorname{rot}_{90}(u_i),Φi​(x,y)=p+xui​+yrot90​(ui​),

the sector Σi\Sigma_iΣi​ is

{Φi{(x,y):x2+y2<(ρ/∥ui∥)2, y<0, ciy+six>0},si>0,Φi{(x,y):x2+y2<(ρ/∥ui∥)2, (y<0 or ciy+six>0)},si<0,Φi{(x,y):x2+y2<(ρ/∥ui∥)2, y<0},si=0.\begin{cases} \Phi_i\{(x,y):x^2+y^2<(\rho/\|u_i\|)^2,\ y<0,\ c_i y+s_i x>0\}, & s_i>0,\\ \Phi_i\{(x,y):x^2+y^2<(\rho/\|u_i\|)^2,\ (y<0\text{ or }c_i y+s_i x>0)\}, & s_i<0,\\ \Phi_i\{(x,y):x^2+y^2<(\rho/\|u_i\|)^2,\ y<0\}, & s_i=0. \end{cases}⎩⎨⎧​Φi​{(x,y):x2+y2<(ρ/∥ui​∥)2, y<0, ci​y+si​x>0},Φi​{(x,y):x2+y2<(ρ/∥ui​∥)2, (y<0 or ci​y+si​x>0)},Φi​{(x,y):x2+y2<(ρ/∥ui​∥)2, y<0},​si​>0,si​<0,si​=0.​

Each Σi\Sigma_iΣi​ is open and connected, is contained in B(p,ρ)B(p,\rho)B(p,ρ), and is disjoint from every positive ray {p+tuj:t>0}\{p+t u_j:t>0\}{p+tuj​:t>0}. Finally, every point of B(p,ρ)∖{p}B(p,\rho)\setminus\{p\}B(p,ρ)∖{p} which lies on none of the positive rays {p+tuj:t>0}\{p+t u_j:t>0\}{p+tuj​:t>0} belongs to at least one of the sectors Σi\Sigma_iΣi​.

Formalization Note This node is ported from the Trellis formalization of the crossing lemma and its consequences (wpegden/crossing-consequences, commit 8769d142, W. Pegden, Apache-2.0); the statement is the Trellis node FinitePlanarClockwiseSuccessorSectors.

Preamble
import Mathlib.Tactic
import Mathlib.Algebra.Group.Fin.Basic
import Mathlib.Analysis.InnerProductSpace.PiL2
import Mathlib.Analysis.SpecialFunctions.Pow.Real
import Mathlib.Combinatorics.SimpleGraph.Finite
import Mathlib.Data.Finset.Prod
import Mathlib.Data.Set.Finite.Basic
import Mathlib.LinearAlgebra.AffineSpace.AffineSubspace.Basic
import Mathlib.Analysis.SpecialFunctions.Complex.Arg
import Definitions.Def_PlanarRot90

open Classical
noncomputable section
Formal statement
lemma FinitePlanarClockwiseSuccessorSectors {ι : Type*} [Fintype ι] [Nonempty ι]
    [DecidableEq ι]
    (p : EuclideanSpace ℝ (Fin 2)) (ρ : ℝ)
    (u : ι → EuclideanSpace ℝ (Fin 2))
    (hρ : 0 < ρ)
    (hu : ∀ i : ι, u i ≠ 0)
    (hposRayDistinct :
      ∀ {i j : ι}, (∃ t : ℝ, 0 < t ∧ u j = t • u i) → i = j) :
    ∃ clockwiseNext : Equiv.Perm ι,
      ∃ fullClockwiseTurn : ℝ,
      ∃ clockwiseTurn : ι → ι → ℝ,
      ∃ sector : ι → Set (EuclideanSpace ℝ (Fin 2)),
        fullClockwiseTurn = 2 * Real.pi ∧
        0 < fullClockwiseTurn ∧
        (∀ i j : ι, 0 < clockwiseTurn i j) ∧
        (∀ i j : ι, clockwiseTurn i j ≤ fullClockwiseTurn) ∧
        (∀ i j : ι, clockwiseTurn i j = fullClockwiseTurn ↔ j = i) ∧
        (∀ i j : ι, j ≠ i →
          clockwiseTurn i (clockwiseNext i) ≤ clockwiseTurn i j) ∧
        (∀ i : ι, clockwiseNext i = i ↔ ∀ j : ι, j = i) ∧
        (∀ i : ι,
          if h : clockwiseNext i = i then
            sector i =
              Metric.ball p ρ \
                ({q | ∃ t : ℝ, 0 < t ∧ q = p + t • u i} ∪
                  ({p} : Set (EuclideanSpace ℝ (Fin 2))))
          else
            ∃ c s : ℝ,
              (s ≠ 0 ∨ c < 0) ∧
              u (clockwiseNext i) = c • u i - s • PlanarRot90 (u i) ∧
              sector i =
                (let base : EuclideanSpace ℝ (Fin 2) := u i
                 let baseChart : EuclideanSpace ℝ (Fin 2) →
                    EuclideanSpace ℝ (Fin 2) :=
                  fun z => p + z 0 • base + z 1 • PlanarRot90 base
                 if 0 < s then
                   baseChart ''
                    {z : EuclideanSpace ℝ (Fin 2) |
                      z 0 ^ 2 + z 1 ^ 2 < (ρ / ‖base‖) ^ 2 ∧
                      z 1 < 0 ∧ 0 < c * z 1 + s * z 0}
                 else if s < 0 then
                   baseChart ''
                    {z : EuclideanSpace ℝ (Fin 2) |
                      z 0 ^ 2 + z 1 ^ 2 < (ρ / ‖base‖) ^ 2 ∧
                      (z 1 < 0 ∨ 0 < c * z 1 + s * z 0)}
                 else
                   baseChart ''
                    {z : EuclideanSpace ℝ (Fin 2) |
                      z 0 ^ 2 + z 1 ^ 2 < (ρ / ‖base‖) ^ 2 ∧
                      z 1 < 0})) ∧
        (∀ i : ι, IsOpen (sector i) ∧ IsConnected (sector i)) ∧
        (∀ i : ι, sector i ⊆ Metric.ball p ρ) ∧
        (∀ i j : ι,
          Disjoint (sector i)
            {q | ∃ t : ℝ, 0 < t ∧ q = p + t • u j}) ∧
        (∀ q : EuclideanSpace ℝ (Fin 2),
          q ∈ Metric.ball p ρ →
            q ≠ p →
              (∀ i : ι,
                q ∉ {x | ∃ t : ℝ, 0 < t ∧ x = p + t • u i}) →
                ∃ i : ι, q ∈ sector i) := by sorry
Source
https://github.com/wpegden/crossing-consequences/blob/8769d142033fce042f502bf2857afb6b1375b5c3/Tablet/FinitePlanarClockwiseSuccessorSectors.lean#L1-L134

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