Skip to content

feat(RingTheory): etale lifting property of henselian local rings#41086

Open
erdOne wants to merge 10 commits into
leanprover-community:masterfrom
erdOne:erd1/henselianStuff
Open

feat(RingTheory): etale lifting property of henselian local rings#41086
erdOne wants to merge 10 commits into
leanprover-community:masterfrom
erdOne:erd1/henselianStuff

Conversation

@erdOne

@erdOne erdOne commented Jun 26, 2026

Copy link
Copy Markdown
Member

Open in Gitpod

@github-actions github-actions Bot added large-import Automatically added label for PRs with a significant increase in transitive imports t-ring-theory Ring theory labels Jun 26, 2026
@github-actions

github-actions Bot commented Jun 26, 2026

Copy link
Copy Markdown

PR summary a010cae47a

Import changes exceeding 2%

% File
+79.64% Mathlib.RingTheory.Henselian

Import changes for modified files

Dependency changes

File Base Count Head Count Change
Mathlib.RingTheory.Henselian 1385 2488 +1103 (+79.64%)
Import changes for all files
Files Import difference
Mathlib.RingTheory.Idempotents 1
Mathlib.RingTheory.Henselian 1103
Mathlib.RingTheory.IdempotentInstances (new file) 1456
Mathlib.RingTheory.LocalRing.RingHom.IsIntegral (new file) 1636

Declarations diff (regex)

+ HenselianLocalRing.algEquivEquiv
+ HenselianLocalRing.exist_algEquiv_residueFieldMap_eq_of_etale
+ HenselianLocalRing.exists_completeOrthogonalIdempotents_forall_isLocalRing
+ HenselianLocalRing.exists_residueFieldMap_eq_of_etale
+ HenselianLocalRing.ofId_comp_bijective
+ HenselianLocalRing.of_finite
+ HenselianLocalRing.of_finite_aux
+ IsIdempotentElem.algebraMap_corner_apply
+ IsIdempotentElem.algebraMap_corner_surjective
+ IsIdempotentElem.ker_algebraMap_corner
+ IsLocalRing.eq_of_residueFieldMap_eq
+ IsLocalRing.ofId_comp_injective
+ finrank_eq_one_iff_algebraMap_bijective
+ instance : IsLocalHom e.toAlgHom := ⟨by simp⟩
+ instance : IsLocalHom e.toAlgHom.toRingHom := ⟨by simp⟩
+ instance : IsLocalHom e.toRingEquiv.toRingHom := ⟨by simp⟩
+ instance [IsLocalRing R] [Algebra.IsIntegral R S] [Nontrivial S] :
+ instance [Module.Finite R A] : Module.Finite R he.Corner
+ instance [Module.Flat R A] : Module.Flat R he.Corner
+ instance [Module.Projective R A] : Module.Projective R he.Corner
+ instance {R R' S : Type*} [CommSemiring R] [CommSemiring R'] [Semiring S] [Algebra R S]
+ instance {R S : Type*} [CommSemiring R] [Semiring S] [Algebra R S]
- instance : IsLocalHom e.toAlgHom := by

You can run this locally as follows
## from your `mathlib4` directory:
git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci

## summary with just the declaration names:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh <optional_commit>

## more verbose report:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh long <optional_commit>

The doc-module for scripts/pr_summary/declarations_diff.sh in the mathlib-ci repository contains some details about this script.

Declarations diff (Lean)

Lean-aware diff — post-build, computed from the Lean environment (commit a010cae).

  • +20 new declarations
  • −0 removed declarations
+AlgEquiv.instIsLocalHomRingHomToAlgHom
+AlgEquiv.instIsLocalHomRingHomToRingHomToRingEquiv
+HenselianLocalRing.algEquivEquiv
+HenselianLocalRing.exist_algEquiv_residueFieldMap_eq_of_etale
+HenselianLocalRing.exists_completeOrthogonalIdempotents_forall_isLocalRing
+HenselianLocalRing.exists_residueFieldMap_eq_of_etale
+HenselianLocalRing.ofId_comp_bijective
+HenselianLocalRing.of_finite
+IsIdempotentElem.algebraMap_corner_apply
+IsIdempotentElem.algebraMap_corner_surjective
+IsIdempotentElem.ker_algebraMap_corner
+IsLocalRing.eq_of_residueFieldMap_eq
+IsLocalRing.ofId_comp_injective
+Module.finrank_eq_one_iff_algebraMap_bijective
+instAlgebraCorner
+instFiniteCorner
+instFlatCorner
+instIsLocalHomRingHomAlgebraMapOfIsLocalRingOfIsIntegralOfNontrivial
+instIsScalarTowerCorner
+instProjectiveCorner

Increase in strong tech debt: (relative, absolute) = (1.00, 0.00)
Current number Change Type (strong)
5690 1 backward.isDefEq.respectTransparency
Increase in weak tech debt: (relative, absolute) = (2.00, 0.00)
Current number Change Type (weak)
4975 2 exposed public sections

Current commit a010cae47a
Reference commit 571b8a8e54

This script lives in the mathlib-ci repository. To run it locally, from your mathlib4 directory:

git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci
../mathlib-ci/scripts/reporting/technical-debt-metrics.sh pr_summary
  • The relative value is the weighted sum of the differences with weight given by the inverse of the current value of the statistic.
  • The absolute value is the relative value divided by the total sum of the inverses of the current values (i.e. the weighted average of the differences).

Comment thread Mathlib/RingTheory/Henselian.lean Outdated
Comment thread Mathlib/RingTheory/Henselian.lean Outdated
Comment thread Mathlib/RingTheory/Henselian.lean Outdated
Comment thread Mathlib/RingTheory/Henselian.lean Outdated
Comment thread Mathlib/RingTheory/Henselian.lean Outdated
Comment thread Mathlib/RingTheory/Henselian.lean Outdated
Comment thread Mathlib/RingTheory/Henselian.lean Outdated
Comment thread Mathlib/RingTheory/Henselian.lean Outdated
Comment thread Mathlib/RingTheory/Henselian.lean Outdated
Comment thread Mathlib/RingTheory/Henselian.lean Outdated
@chrisflav chrisflav added the awaiting-author A reviewer has asked the author a question or requested changes. label Jun 27, 2026
Comment thread Mathlib/RingTheory/Idempotents.lean Outdated
Comment thread Mathlib/RingTheory/Idempotents.lean Outdated
Comment thread Mathlib/RingTheory/Idempotents.lean
erdOne and others added 4 commits June 27, 2026 12:00
@erdOne erdOne added awaiting-CI This PR does not pass CI yet. This label is automatically removed once it does. and removed awaiting-author A reviewer has asked the author a question or requested changes. labels Jun 27, 2026
@github-actions github-actions Bot removed the awaiting-CI This PR does not pass CI yet. This label is automatically removed once it does. label Jun 27, 2026
Comment thread Mathlib/RingTheory/Henselian.lean Outdated
Co-authored-by: Christian Merten <christian@merten.dev>

@chrisflav chrisflav left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!
maintainer merge

@github-actions

Copy link
Copy Markdown

🚀 Pull request has been placed on the maintainer queue by chrisflav.

@mathlib-triage mathlib-triage Bot added the maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. label Jun 27, 2026
@faenuccio faenuccio self-assigned this Jun 30, 2026
@faenuccio faenuccio added awaiting-author A reviewer has asked the author a question or requested changes. and removed maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. labels Jun 30, 2026

@faenuccio faenuccio left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've left some comments, but in particular I wonder if we don't need a Henselian folder to distinguish basic stuff from étale one.

Also, can you update the PR description? Thanks.

public import Mathlib.RingTheory.Flat.Stability
public import Mathlib.RingTheory.Idempotents

/-! # Instances on corners -/

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you improve this docstring?

Function.Surjective (algebraMap R he.Corner) :=
fun x ↦ ⟨x.1, Subtype.ext ((Subsemigroup.mem_corner_iff he).mp x.2).2⟩

lemma IsIdempotentElem.ker_algebraMap_corner [CommRing R] {e : R} (he : IsIdempotentElem e) :

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
lemma IsIdempotentElem.ker_algebraMap_corner [CommRing R] {e : R} (he : IsIdempotentElem e) :
lemma IsIdempotentElem.ker_algebraMap_corner_eq_span [CommRing R] {e : R} (he : IsIdempotentElem e) :


variable {R A B : Type*} [CommRing R] [CommRing A] [Algebra R A] [CommRing B] [Algebra R B]

attribute [local instance] Localization.AtPrime.algebraOfLiesOver in

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you explain why this is the natural place for this results? The statement has nothing to do with henselianity, AFAICT.

attribute [local instance] Localization.AtPrime.algebraOfLiesOver in
/-- If `R` is a local ring with residue field `k`, then for any étale `R`-algebra `A`,
every `A →ₐ[R] k` lifts to at most one an `A →ₐ[R] R`. -/
lemma IsLocalRing.ofId_comp_injective [Algebra.Etale R A] [IsLocalRing R] :

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't you think that this should live in the Algebra.Etale namespace?

simpa using 𝓟.hasMap.isUnit_derivative_f.map f₁

attribute [local instance] Localization.AtPrime.algebraOfLiesOver in
/-- If `R` is a Henselian local ring with residue field `k`, then for any étale `R`-algebra `A`,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add this important result to the module docstring?

· simp
· rw [ha]; simp [← hroot]

/-- Let `R` be an henselian local ring, `A, B` be local `R`-algebras.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/-- Let `R` be an henselian local ring, `A, B` be local `R`-algebras.
/-- Let `R` be a henselian local ring, `A, B` be local `R`-algebras.

· rw [ha]; simp [← hroot]

/-- Let `R` be an henselian local ring, `A, B` be local `R`-algebras.
Suppose `A` is etale and `B` is module-finite, then any `k(R)`-algebra map `k(A) → k(B)` lifts to

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Suppose `A` is etale and `B` is module-finite, then any `k(R)`-algebra map `k(A) → k(B)` lifts to
Suppose `A` is étale and `B` is module-finite, then any `k(R)`-algebra map `k(A) → k(B)` lifts to

can you also check all the other etale and add the accent?

an `R`-algebra map `A → B`.

See `HenselianLocalRing.eq_of_residueFieldMap_eq` for the uniqueness of the lift. -/
lemma HenselianLocalRing.exists_residueFieldMap_eq_of_etale [HenselianLocalRing R] [IsLocalRing A]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The name seems to suggest the existence of a residue field map, whereas it is the existence of a lift. Do you have other naming options?

have : IsLocalHom (φ.comp ψ).toRingHom := by
dsimp [AlgHom.comp_toRingHom] at hφ hψ ⊢; exact RingHom.isLocalHom_comp _ _
apply IsLocalRing.eq_of_residueFieldMap_eq
dsimp [AlgHom.comp_toRingHom] at hφ hψ ⊢ hφ' hψ'

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would squeeze this as well, no?

Then `Aut(A/R) ≃ Gal(k(A)/k(R))`.

Paired with `galRestrict`, this shows that `Gal(Frac A / Frac R) ≃* Gal(k(A)/k(R))`. -/
def HenselianLocalRing.algEquivEquiv [HenselianLocalRing R]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not algEquivMulEquiv?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting-author A reviewer has asked the author a question or requested changes. large-import Automatically added label for PRs with a significant increase in transitive imports t-ring-theory Ring theory

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants