Skip to content

Commit 4c7e3f9

Browse files
kim-emclaude
andcommitted
fix(Algebra/Field): ensure Field.toGrindField.toInv is def-eq to Field.toInv
Explicitly set `inv a := a⁻¹` in `Field.toGrindField` so that `grind` can be used in contexts where there are `InvMemClass` instances around. 🤖 Generated with Claude Code Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent f9a3323 commit 4c7e3f9

2 files changed

Lines changed: 7 additions & 0 deletions

File tree

Mathlib/Algebra/Field/Basic.lean

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,7 @@ variable [Field K]
160160

161161
instance (priority := 100) Field.toGrindField [Field K] : Lean.Grind.Field K :=
162162
{ CommRing.toGrindCommRing K, ‹Field K› with
163+
inv a := a⁻¹
163164
zpow := ⟨fun a n => a^n⟩
164165
zpow_zero a := by simp
165166
zpow_succ a n := by
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
import Mathlib.FieldTheory.IntermediateField.Basic
2+
3+
example {K L : Type*} [Field K] [Field L] [Algebra K L]
4+
(E : IntermediateField K L) :
5+
(Field.toGrindField.toInv : Inv E) = InvMemClass.inv := by
6+
with_reducible_and_instances rfl

0 commit comments

Comments
 (0)