Skip to content

Commit 9ad2225

Browse files
RaggedRclaude
andcommitted
chore: add nextPerm docstring, fix lint warnings
- Add missing documentation string for `CellularSurface.nextPerm` - Remove unused `Pi.one_apply` from two `simp` calls - Replace `show` with `change` where it transforms the goal Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 9b2c012 commit 9ad2225

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

Mathlib/Combinatorics/CellularSurface.lean

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,7 @@ theorem nextIdx_injective (f : Fin S.nF) : Function.Injective (S.nextIdx f) := b
144144
theorem nextIdx_bijective (f : Fin S.nF) : Function.Bijective (S.nextIdx f) :=
145145
Finite.injective_iff_bijective.mp (S.nextIdx_injective f)
146146

147+
/-- `nextIdx` as a permutation (equivalence) on face boundary indices. -/
147148
noncomputable def nextPerm (f : Fin S.nF) : Equiv.Perm (Fin (S.face_len f)) :=
148149
Equiv.ofBijective _ (S.nextIdx_bijective f)
149150

@@ -260,7 +261,7 @@ theorem ker_d1T_le_span_one (hconn : S.toSimpleGraph.Connected) :
260261
have hconst : ∀ u v : Fin S.nV, x u = x v := fun u v =>
261262
S.walk_preserves_ker hx (hconn.preconnected u v).some
262263
exact ⟨x ⟨0, hV⟩, funext fun v => by
263-
simp [Pi.smul_apply, Pi.one_apply, smul_eq_mul, mul_one, hconst ⟨0, hV⟩ v]⟩
264+
simp [Pi.smul_apply, smul_eq_mul, mul_one, hconst ⟨0, hV⟩ v]⟩
264265

265266
theorem ker_d1T_finrank_eq_one (hconn : S.toSimpleGraph.Connected) (hV : 0 < S.nV) :
266267
Module.finrank (ZMod 2) (LinearMap.ker S.d1ᵀ.mulVecLin) = 1 := by
@@ -383,7 +384,7 @@ theorem d2_rank_eq (hconn_dual : S.toDualSimpleGraph.Connected) (hF : 1 < S.nF)
383384
| nil => rfl
384385
| cons hadj _ ih => exact (S.ker_d2_dual_adj_eq hy htwo hadj).trans ih
385386
exact ⟨y ⟨0, hF_pos⟩, funext fun v => by
386-
simp [Pi.smul_apply, Pi.one_apply, smul_eq_mul, mul_one, hconst ⟨0, hF_pos⟩ v]⟩)
387+
simp [Pi.smul_apply, smul_eq_mul, mul_one, hconst ⟨0, hF_pos⟩ v]⟩)
387388
((Submodule.span_singleton_le_iff_mem _ _).mpr hmem)
388389
have hle := S.d2_rank_le hF_pos (S.d2_mulVec_one_of_two_sides htwo)
389390
have hge : S.nF - 1 ≤ S.d2.rank := by
@@ -474,6 +475,6 @@ theorem CellularSurface.css_k_eq_2g_from_surface (S : CellularSurface) (g : ℕ)
474475
intro T css
475476
apply css_k_eq_2g
476477
· exact S.d1_rank_eq hconn hV
477-
· show (S.d2ᵀ.rank : ℤ) = S.nF - 1
478+
· change (S.d2ᵀ.rank : ℤ) = S.nF - 1
478479
rw [rank_transpose]
479480
exact S.d2_rank_eq hconn_dual hF htwo

0 commit comments

Comments
 (0)