Module

Dilatations.lean

Nyll.AbelianVarieties.NeronModels.Smoothening.Dilatations
73 declarations indexed from sourceView source ↗

Global dilatations and decrease of the smoothness defect

Imports23
Imported by2

Declarations

NeronModelInfra.Dilatations.Construction.AffineCharts.mul_left_cancel_algebraMap
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section RingLevel
variable {A : Type u} [CommRing A]
open AffineDilatation
open AbelianVarieties.NOSProofs.AffineDilatationRegularity.AffineDilatation.BasicProps
  (isSMulRegular)
theorem mul_left_cancel_algebraMap (I : Ideal A) (a : A) {x y : Ring I a}
    (h : algebraMap A (Ring I a) a * x = algebraMap A (Ring I a) a * y) : x = y
NeronModelInfra.Dilatations.Construction.AffineCharts.ringHom_ext
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section RingLevel
variable {A : Type u} [CommRing A]
open AffineDilatation
open AbelianVarieties.NOSProofs.AffineDilatationRegularity.AffineDilatation.BasicProps
  (isSMulRegular)
theorem ringHom_ext {C : Type*} [CommRing C] (I : Ideal A) (a : A) (φ ψ : Ring I a →+* C)
    (hA : ∀ r : A, φ (algebraMap A (Ring I a) r) = ψ (algebraMap A (Ring I a) r))
    (hreg : ∀ c c' : C, φ (algebraMap A (Ring I a) a) * c = φ (algebraMap A (Ring I a) a) * c' →
      c = c') :
    φ = ψ
NeronModelInfra.Dilatations.Construction.AffineCharts.exists_ringHom
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section RingLevel
variable {A : Type u} [CommRing A]
open AffineDilatation
open AbelianVarieties.NOSProofs.AffineDilatationRegularity.AffineDilatation.BasicProps
  (isSMulRegular)
theorem exists_ringHom {C : Type u} [CommRing C] (I : Ideal A) (a : A) (v : A →+* C)
    (hreg : ∀ c c' : C, v a * c = v a * c' → c = c')
    (hI : ∀ g ∈ I, ∃ c : C, v g = v a * c) :
    ∃ φ : Ring I a →+* C, φ.comp (algebraMap A (Ring I a)) = v
NeronModelInfra.Dilatations.Construction.AffineCharts.algebraMap_bijective_of_isUnit
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section RingLevel
variable {A : Type u} [CommRing A]
open AffineDilatation
open AbelianVarieties.NOSProofs.AffineDilatationRegularity.AffineDilatation.BasicProps
  (isSMulRegular)
theorem algebraMap_bijective_of_isUnit (I : Ideal A) {a : A} (ha : IsUnit a) :
    Function.Bijective (algebraMap A (Ring I a))
NeronModelInfra.Dilatations.Construction.AffineCharts.exists_ringEquiv_of_eq_unit_mul
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section RingLevel
variable {A : Type u} [CommRing A]
open AffineDilatation
open AbelianVarieties.NOSProofs.AffineDilatationRegularity.AffineDilatation.BasicProps
  (isSMulRegular)
theorem exists_ringEquiv_of_eq_unit_mul (I : Ideal A) (a b : A) (u : Aˣ) (hb : b = u * a)
    (ha : a ∈ I) :
    ∃ e : Ring I a ≃+* Ring I b,
      e.toRingHom.comp (algebraMap A (Ring I a)) = algebraMap A (Ring I b)
NeronModelInfra.Dilatations.Construction.AffineCharts.nonempty_algEquiv_of_eq
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section RingLevel
variable {A : Type u} [CommRing A]
open AffineDilatation
open AbelianVarieties.NOSProofs.AffineDilatationRegularity.AffineDilatation.BasicProps
  (isSMulRegular)
theorem nonempty_algEquiv_of_eq {I I' : Ideal A} {a a' : A} (hI : I = I') (ha : a = a') :
    Nonempty (Ring I a ≃ₐ[A] Ring I' a')
NeronModelInfra.Dilatations.Construction.AffineCharts.exists_ringEquiv_of_eq
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section RingLevel
variable {A : Type u} [CommRing A]
open AffineDilatation
open AbelianVarieties.NOSProofs.AffineDilatationRegularity.AffineDilatation.BasicProps
  (isSMulRegular)
theorem exists_ringEquiv_of_eq {I I' : Ideal A} {a a' : A} (hI : I = I') (ha : a = a') :
    ∃ e : Ring I a ≃+* Ring I' a', e.toRingHom.comp (algebraMap A (Ring I a)) = algebraMap A
      (Ring I' a')
NeronModelInfra.Dilatations.Construction.AffineCharts.secTop

The global section induced by a base-ring element.

Source context 10 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
def secTop (π : R) : Γ(X, ⊤)
NeronModelInfra.Dilatations.Construction.AffineCharts.sec

The restriction of the base section to an open set.

Source context 10 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
def sec (π : R) (U : X.Opens) : Γ(X, U)
NeronModelInfra.Dilatations.Construction.AffineCharts.sec_def
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem sec_def (π : R) (U : X.Opens) : sec f π U =
    (X.presheaf.map (homOfLE le_top).op).hom (f.appTop.hom ((Scheme.ΓSpecIso (CommRingCat.of
      R)).inv.hom π))
NeronModelInfra.Dilatations.Construction.AffineCharts.toSec

The base-ring map to sections of an open set.

Source context 10 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
def toSec (U : X.Opens) : R →+* Γ(X, U)
NeronModelInfra.Dilatations.Construction.AffineCharts.toSec_apply
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem toSec_apply (π : R) (U : X.Opens) : toSec f U π = sec f π U
NeronModelInfra.Dilatations.Construction.AffineCharts.map_sec
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem map_sec (π : R) {U V : X.Opens} (i : op U ⟶ op V) :
    (X.presheaf.map i).hom (sec f π U) = sec f π V
NeronModelInfra.Dilatations.Construction.AffineCharts.mem_basicOpen_secTop_iff
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem mem_basicOpen_secTop_iff (π : R) (x : X) :
    x ∈ X.basicOpen (secTop f π) ↔ π ∉ (f x).asIdeal
NeronModelInfra.Dilatations.Construction.AffineCharts.eq_closedPoint_iff
Source context 10 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
theorem eq_closedPoint_iff {π : R} (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
    (q : PrimeSpectrum R) : q = IsLocalRing.closedPoint R ↔ π ∈ q.asIdeal
NeronModelInfra.Dilatations.Construction.AffineCharts.mem_basicOpen_secTop_iff'
Source context 10 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
theorem mem_basicOpen_secTop_iff' {π : R} (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π}) (x
  : X) :
    x ∈ X.basicOpen (secTop f π) ↔ f x ≠ IsLocalRing.closedPoint R
NeronModelInfra.Dilatations.Construction.AffineCharts.basicOpen_sec
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem basicOpen_sec (π : R) (U : X.Opens) :
    X.basicOpen (sec f π U) = U ⊓ X.basicOpen (secTop f π)
NeronModelInfra.Dilatations.Construction.AffineCharts.primeIdealOf_fromSpec
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable {U : X.Opens} (hU : IsAffineOpen U)
theorem primeIdealOf_fromSpec (q : PrimeSpectrum Γ(X, U))
    (hq : hU.fromSpec q ∈ U) : hU.primeIdealOf ⟨hU.fromSpec q, hq⟩ = q
NeronModelInfra.Dilatations.Construction.AffineCharts.fromSpec_mem
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable {U : X.Opens} (hU : IsAffineOpen U)
theorem fromSpec_mem (q : PrimeSpectrum Γ(X, U)) : hU.fromSpec q ∈ U
NeronModelInfra.Dilatations.Construction.AffineCharts.mem_basicOpen_iff_notMem
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable {U : X.Opens} (hU : IsAffineOpen U)
theorem mem_basicOpen_iff_notMem (s : Γ(X, U)) (y : X) (hy : y ∈ U) :
    y ∈ X.basicOpen s ↔ s ∉ (hU.primeIdealOf ⟨y, hy⟩).asIdeal
NeronModelInfra.Dilatations.Construction.AffineCharts.sec_mem_asIdeal_iff
Source context 11 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable {U : X.Opens} (hU : IsAffineOpen U)
theorem sec_mem_asIdeal_iff {π : R} (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π}) (y : X)
  (hy : y ∈ U) :
    sec f π U ∈ (hU.primeIdealOf ⟨y, hy⟩).asIdeal ↔ f y = IsLocalRing.closedPoint R
NeronModelInfra.Dilatations.Construction.AffineCharts.idealY

The reduced ideal sheaf cutting out the closed center.

Source context 12 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable {U : X.Opens} (hU : IsAffineOpen U)
variable (Y : Set X) (hY : IsClosed Y)
def idealY : X.IdealSheafData
NeronModelInfra.Dilatations.Construction.AffineCharts.idealY_ideal
Source context 12 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable {U : X.Opens} (hU : IsAffineOpen U)
variable (Y : Set X) (hY : IsClosed Y)
theorem idealY_ideal (V : X.affineOpens) :
    (idealY Y hY).ideal V = PrimeSpectrum.vanishingIdeal (V.2.fromSpec ⁻¹' Y)
NeronModelInfra.Dilatations.Construction.AffineCharts.idealY_ideal'
Source context 12 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable {U : X.Opens} (hU : IsAffineOpen U)
variable (Y : Set X) (hY : IsClosed Y)
theorem idealY_ideal' : (idealY Y hY).ideal ⟨U, hU⟩ = PrimeSpectrum.vanishingIdeal (hU.fromSpec
  ⁻¹' Y)
NeronModelInfra.Dilatations.Construction.AffineCharts.mem_iff_ideal_le
Source context 12 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable {U : X.Opens} (hU : IsAffineOpen U)
variable (Y : Set X) (hY : IsClosed Y)
theorem mem_iff_ideal_le (y : X) (hy : y ∈ U) :
    y ∈ Y ↔ (idealY Y hY).ideal ⟨U, hU⟩ ≤ (hU.primeIdealOf ⟨y, hy⟩).asIdeal
NeronModelInfra.Dilatations.Construction.AffineCharts.vanishingIdeal_image_eq
Source context 12 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable {U : X.Opens} (hU : IsAffineOpen U)
variable (Y : Set X) (hY : IsClosed Y)
theorem vanishingIdeal_image_eq :
    PrimeSpectrum.vanishingIdeal ((fun y : U => hU.primeIdealOf y) '' {y : U | (y : X) ∈ Y}) =
      (idealY Y hY).ideal ⟨U, hU⟩ := by
  rw [idealY_ideal']
  congr 1
  ext q
  constructor
  · rintro ⟨y, hy, rfl⟩
    change hU.fromSpec (hU.primeIdealOf y) ∈ Y
    rw [IsAffineOpen.fromSpec_primeIdealOf]; exact hy
  · intro hq
    exact ⟨⟨hU.fromSpec q, fromSpec_mem hU q⟩, hq, primeIdealOf_fromSpec hU q _⟩
NeronModelInfra.Dilatations.Construction.AffineCharts.sec_mem_ideal
Source context 14 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Dictionary
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable {U : X.Opens} (hU : IsAffineOpen U)
variable (Y : Set X) (hY : IsClosed Y)
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hYs
theorem sec_mem_ideal {π : R} (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π}) :
    sec f π U ∈ (idealY Y hY).ideal ⟨U, hU⟩
NeronModelInfra.Dilatations.Construction.AffineCharts.idl

The ideal of the center on an affine chart.

Source context 13 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
abbrev idl (U : X.AffineZariskiSite) : Ideal Γ(X, U.1)
NeronModelInfra.Dilatations.Construction.AffineCharts.objRing

The dilatation ring on an affine chart.

Source context 13 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
abbrev objRing (U : X.AffineZariskiSite) : Type u
NeronModelInfra.Dilatations.Construction.AffineCharts.res

Restriction of affine sections.

Source context 13 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
abbrev res {V U : X.AffineZariskiSite} (h : V ≤ U) : Γ(X, U.1) →+* Γ(X, V.1)
NeronModelInfra.Dilatations.Construction.AffineCharts.res_sec
Source context 14 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem res_sec {V U : X.AffineZariskiSite} (h : V ≤ U) : res h (sec f π U.1) = sec f π V.1
NeronModelInfra.Dilatations.Construction.AffineCharts.idl_map
Source context 13 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
theorem idl_map {V U : X.AffineZariskiSite} (h : V ≤ U) : (idl Y hY U).map (res h) = idl Y hY V
NeronModelInfra.Dilatations.Construction.AffineCharts.exists_transition
Source context 14 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem exists_transition {V U : X.AffineZariskiSite} (h : V ≤ U) :
    ∃ φ : objRing f Y hY π U →+* objRing f Y hY π V,
      φ.comp (algebraMap _ _) = (algebraMap _ (objRing f Y hY π V)).comp (res h)
NeronModelInfra.Dilatations.Construction.AffineCharts.transition

The unique transition map between dilatation rings.

Source context 13 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
def transition {V U : X.AffineZariskiSite} (h : V ≤ U) : objRing f Y hY π U →+* objRing f Y hY π
  V
NeronModelInfra.Dilatations.Construction.AffineCharts.transition_algebraMap
Source context 14 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem transition_algebraMap {V U : X.AffineZariskiSite} (h : V ≤ U) (g : Γ(X, U.1)) :
    transition f Y hY π h (algebraMap _ _ g) = algebraMap _ _ (res h g)
NeronModelInfra.Dilatations.Construction.AffineCharts.transition_unique
Source context 14 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem transition_unique {V U : X.AffineZariskiSite} (h : V ≤ U)
    (φ : objRing f Y hY π U →+* objRing f Y hY π V)
    (hφ : ∀ g, φ (algebraMap _ _ g) = algebraMap _ _ (res h g)) : φ = transition f Y hY π h
NeronModelInfra.Dilatations.Construction.AffineCharts.transition_refl
Source context 14 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem transition_refl (U : X.AffineZariskiSite) : transition f Y hY π (le_refl U) = RingHom.id
  _
NeronModelInfra.Dilatations.Construction.AffineCharts.transition_trans
Source context 14 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
omit [IsDomain R] [IsDiscreteValuationRing R] in
theorem transition_trans {W V U : X.AffineZariskiSite} (h : W ≤ V) (h' : V ≤ U) :
    (transition f Y hY π h).comp (transition f Y hY π h') = transition f Y hY π (h.trans h')
NeronModelInfra.Dilatations.Construction.AffineCharts.diagram

The diagram of dilatation rings on the affine site.

Source context 13 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
def diagram : X.AffineZariskiSiteᵒᵖ ⥤ CommRingCat.{u} where
  obj U := CommRingCat.of (objRing f Y hY π (unop U))
  map {U V} i := CommRingCat.ofHom (transition f Y hY π i.unop.le)
  map_id U := by
    ext1
    exact transition_refl f Y hY π (unop U)
  map_comp {U V W} i j := by
    ext1
    exact (transition_trans f Y hY π j.unop.le i.unop.le).symm
NeronModelInfra.Dilatations.Construction.AffineCharts.toDiagram

The structural natural transformation to dilatation rings.

Source context 13 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
def toDiagram : (toOpensFunctor X).op ⋙ X.presheaf ⟶ diagram f Y hY π where
  app U := CommRingCat.ofHom (algebraMap Γ(X, (unop U).1) (objRing f Y hY π (unop U)))
  naturality {U V} i := by
    ext g
    exact (transition_algebraMap f Y hY π i.unop.le g).symm
NeronModelInfra.Dilatations.Construction.AffineCharts.sec_mem_idl
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem sec_mem_idl (U : X.AffineZariskiSite) : sec f π U.1 ∈ idl Y hY U
NeronModelInfra.Dilatations.Construction.AffineCharts.coequifibered
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem coequifibered : (toDiagram f Y hY π).Coequifibered
NeronModelInfra.Dilatations.Construction.AffineCharts.glueData

Gluing data for the affine dilatation charts.

Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
def glueData : (directedCover X).RelativeGluingData
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
instance : ((glueData f Y hY hπ hYs).functor ⋙ Scheme.forget).IsLocallyDirected
NeronModelInfra.Dilatations.Construction.AffineCharts.D

The global dilatation obtained by gluing affine charts.

Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
def D : Scheme.{u}
NeronModelInfra.Dilatations.Construction.AffineCharts.p

The structural morphism of the global dilatation.

Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
def p : D f Y hY hπ hYs ⟶ X
NeronModelInfra.Dilatations.Construction.AffineCharts.chart

The chart map into the global dilatation.

Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
def chart (U : X.AffineZariskiSite) : Spec (CommRingCat.of (objRing f Y hY π U)) ⟶ D f Y hY hπ
  hYs
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
instance (U : X.AffineZariskiSite) : IsOpenImmersion (chart f Y hY hπ hYs U)
NeronModelInfra.Dilatations.Construction.AffineCharts.chart_def
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem chart_def (U : X.AffineZariskiSite) :
    chart f Y hY hπ hYs U = colimit.ι (glueData f Y hY hπ hYs).functor U
NeronModelInfra.Dilatations.Construction.AffineCharts.chart_p
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem chart_p (U : X.AffineZariskiSite) :
    chart f Y hY hπ hYs U ≫ p f Y hY hπ hYs =
      Spec.map (CommRingCat.ofHom (algebraMap Γ(X, U.1) (objRing f Y hY π U))) ≫ U.2.fromSpec
NeronModelInfra.Dilatations.Construction.AffineCharts.preimage_p
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem preimage_p (U : X.AffineZariskiSite) :
    p f Y hY hπ hYs ⁻¹ᵁ U.1 = (chart f Y hY hπ hYs U).opensRange
NeronModelInfra.Dilatations.Construction.AffineCharts.isPullback_chart
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem isPullback_chart (U : X.AffineZariskiSite) :
    IsPullback (Spec.map (CommRingCat.ofHom (algebraMap Γ(X, U.1) (objRing f Y hY π U))) ≫
      U.2.isoSpec.inv)
      (chart f Y hY hπ hYs U) U.1.ι (p f Y hY hπ hYs)
NeronModelInfra.Dilatations.Construction.AffineCharts.restrict_iff
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem restrict_iff (P : MorphismProperty Scheme.{u}) [P.RespectsIso] (U : X.AffineZariskiSite) :
    P (p f Y hY hπ hYs ∣_ U.1) ↔
      P (Spec.map (CommRingCat.ofHom (algebraMap Γ(X, U.1) (objRing f Y hY π U))))
NeronModelInfra.Dilatations.Construction.AffineCharts.isAffineHom_p
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
instance isAffineHom_p : IsAffineHom (p f Y hY hπ hYs)
NeronModelInfra.Dilatations.Construction.AffineCharts.locallyOfFiniteType_p
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem locallyOfFiniteType_p [LocallyOfFiniteType f] : LocallyOfFiniteType (p f Y hY hπ hYs)
NeronModelInfra.Dilatations.Construction.AffineCharts.isUnit_sec
Source context 18 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
omit hYs in
theorem isUnit_sec {U : X.Opens} (hU : ∀ x ∈ U, f x ≠ IsLocalRing.closedPoint R) : IsUnit (sec f
  π U)
NeronModelInfra.Dilatations.Construction.AffineCharts.isIso_restrict_affine
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem isIso_restrict_affine (U : X.AffineZariskiSite) (hU : ∀ x ∈ U.1, f x ≠
  IsLocalRing.closedPoint R) :
    IsIso (p f Y hY hπ hYs ∣_ U.1)
NeronModelInfra.Dilatations.Construction.AffineCharts.isIso_restrict
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem isIso_restrict (W : X.Opens) (hW : ∀ x ∈ W, f x ≠ IsLocalRing.closedPoint R) :
    IsIso (p f Y hY hπ hYs ∣_ W)
NeronModelInfra.Dilatations.Construction.AffineCharts.apply_mem
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem apply_mem (d : D f Y hY hπ hYs) (hd : f (p f Y hY hπ hYs d) = IsLocalRing.closedPoint R) :
    p f Y hY hπ hYs d ∈ Y
NeronModelInfra.Dilatations.Construction.AffineCharts.exists_specIso
Source context 18 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
omit hπ hYs in
theorem exists_specIso {A B B' : Type u} [CommRing A] [CommRing B] [CommRing B'] [Algebra A B]
    [Algebra A B'] (E : B ≃+* B') (hE : E.toRingHom.comp (algebraMap A B) = algebraMap A B') :
    ∃ e : Spec (CommRingCat.of B) ≅ Spec (CommRingCat.of B'),
      e.hom ≫ Spec.map (CommRingCat.ofHom (algebraMap A B')) = Spec.map (CommRingCat.ofHom
        (algebraMap A B))
NeronModelInfra.Dilatations.Construction.AffineCharts.exists_chartIso
Source context 17 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.Construction
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite
universe u
noncomputable section
namespace AffineCharts
section Global
open _root_.AlgebraicGeometry.Scheme.AffineZariskiSite
open _root_.AffineDilatation
variable {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
variable {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R))
variable (Y : Set X) (hY : IsClosed Y) (π : R)
variable {π}
variable (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
variable (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R)
include hπ hYs
theorem exists_chartIso (U : X.Opens) (hU : IsAffineOpen U) (ϖ : R)
    (hϖ : IsLocalRing.maximalIdeal R = Ideal.span {ϖ}) :
    ∃ e : (↑(p f Y hY hπ hYs ⁻¹ᵁ U) : Scheme.{u}) ≅
        Spec (CommRingCat.of (AffineDilatation.Ring
          (PrimeSpectrum.vanishingIdeal ((fun y : U => hU.primeIdealOf y) '' {y : U | (y : X) ∈
            Y}))
          ((X.presheaf.map (homOfLE le_top).op).hom
            (f.appTop.hom ((Scheme.ΓSpecIso (CommRingCat.of R)).inv.hom ϖ))))),
      (p f Y hY hπ hYs ⁻¹ᵁ U).ι ≫ p f Y hY hπ hYs = e.hom ≫
        Spec.map (CommRingCat.ofHom (algebraMap Γ(X, U) (AffineDilatation.Ring
          (PrimeSpectrum.vanishingIdeal ((fun y : U => hU.primeIdealOf y) '' {y : U | (y : X) ∈
            Y}))
          ((X.presheaf.map (homOfLE le_top).op).hom
            (f.appTop.hom ((Scheme.ΓSpecIso (CommRingCat.of R)).inv.hom ϖ)))))) ≫ hU.fromSpec := by
  let U' : X.AffineZariskiSite := ⟨U, hU⟩
  let e₁ : (↑(p f Y hY hπ hYs ⁻¹ᵁ U) : Scheme.{u}) ≅ Spec (CommRingCat.of (objRing f Y hY π U')) :=
    IsOpenImmersion.isoOfRangeEq (p f Y hY hπ hYs ⁻¹ᵁ U).ι (chart f Y hY hπ hYs U') (by
      rw [Scheme.Opens.range_ι, ← Scheme.Hom.coe_opensRange]
      exact congrArg SetLike.coe (preimage_p f Y hY hπ hYs U'))
  have he₁ : e₁.hom ≫ chart f Y hY hπ hYs U' = (p f Y hY hπ hYs ⁻¹ᵁ U).ι :=
    IsOpenImmersion.isoOfRangeEq_hom_fac _ _ _
  have hassoc : Associated π ϖ := by
    rw [← Ideal.span_singleton_eq_span_singleton, ← hπ, ← hϖ]
  obtain ⟨u, hu⟩ := hassoc
  have hb : sec f ϖ U = (Units.map (toSec f U).toMonoidHom u : Γ(X, U)ˣ) * sec f π U := by
    rw [← toSec_apply, ← toSec_apply, ← hu, map_mul, mul_comm]; rfl
  obtain ⟨e', he'⟩ := exists_ringEquiv_of_eq_unit_mul (idl Y hY U') (sec f π U) (sec f ϖ U) _ hb
    (sec_mem_idl f Y hY hπ hYs U')
  obtain ⟨e'', he''⟩ := exists_ringEquiv_of_eq (A := Γ(X, U)) (a := sec f ϖ U) (a' := sec f ϖ U)
    (vanishingIdeal_image_eq hU Y hY).symm rfl
  let E : objRing f Y hY π U' ≃+* AffineDilatation.Ring
      (PrimeSpectrum.vanishingIdeal ((fun y : U => hU.primeIdealOf y) '' {y : U | (y : X) ∈ Y}))
      (sec f ϖ U) := e'.trans e''
  have hE : E.toRingHom.comp (algebraMap Γ(X, U) (objRing f Y hY π U')) = algebraMap _ _ := by
    have hEt : E.toRingHom = e''.toRingHom.comp e'.toRingHom := RingHom.ext fun x => rfl
    rw [hEt, RingHom.comp_assoc, he', he'']
  obtain ⟨e₂, he₂⟩ := exists_specIso (A := Γ(X, U)) E hE
  refine ⟨e₁ ≪≫ e₂, ?_⟩
  change (p f Y hY hπ hYs ⁻¹ᵁ U).ι ≫ p f Y hY hπ hYs =
    (e₁.hom ≫ e₂.hom) ≫ _ ≫ hU.fromSpec
  rw [← he₁, Category.assoc]
  have hp : chart f Y hY hπ hYs U' ≫ p f Y hY hπ hYs =
      Spec.map (CommRingCat.ofHom (algebraMap Γ(X, U) (objRing f Y hY π U'))) ≫
        hU.fromSpec := chart_p f Y hY hπ hYs U'
  rw [hp, Category.assoc]
  exact congrArg (e₁.hom ≫ ·)
    ((congrArg (· ≫ hU.fromSpec) he₂).symm.trans (Category.assoc _ _ _))
NeronModelInfra.exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed
Source context 5 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry Opposite Dilatations.Construction
universe u
theorem exists_isAffineHom_isIso_morphismRestrict_iso_affineDilatation_of_isClosed
    {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
    {X : Scheme.{u}} (f : X ⟶ Spec (CommRingCat.of R)) [LocallyOfFiniteType f]
    (Y : Set X) (hY : IsClosed Y) (hYs : ∀ y ∈ Y, f y = IsLocalRing.closedPoint R) :
    ∃ (D : Scheme.{u}) (p : D ⟶ X),
      IsAffineHom p ∧ LocallyOfFiniteType p ∧
      (∀ W : X.Opens, (∀ x ∈ W, f x ≠ IsLocalRing.closedPoint R) → IsIso (p ∣_ W)) ∧
      (∀ d : D, f (p d) = IsLocalRing.closedPoint R → p d ∈ Y) ∧
      (∀ (U : X.Opens) (hU : IsAffineOpen U) (π : R),
        IsLocalRing.maximalIdeal R = Ideal.span {π} →
        ∃ e : (↑(p ⁻¹ᵁ U) : Scheme.{u}) ≅
            Spec (CommRingCat.of (AffineDilatation.Ring
              (PrimeSpectrum.vanishingIdeal ((fun y : U => hU.primeIdealOf y) '' {y : U | (y :
                X) ∈ Y}))
              ((X.presheaf.map (homOfLE le_top).op).hom
                (f.appTop.hom ((Scheme.ΓSpecIso (CommRingCat.of R)).inv.hom π))))),
          (p ⁻¹ᵁ U).ι ≫ p = e.hom ≫
            Spec.map (CommRingCat.ofHom (algebraMap Γ(X, U) (AffineDilatation.Ring
              (PrimeSpectrum.vanishingIdeal ((fun y : U => hU.primeIdealOf y) '' {y : U | (y :
                X) ∈ Y}))
              ((X.presheaf.map (homOfLE le_top).op).hom
                (f.appTop.hom ((Scheme.ΓSpecIso (CommRingCat.of R)).inv.hom π)))))) ≫
                  hU.fromSpec) := by
  obtain ⟨π, hπirr⟩ := IsDiscreteValuationRing.exists_irreducible R
  have hπ : IsLocalRing.maximalIdeal R = Ideal.span {π} := hπirr.maximalIdeal_eq
  exact ⟨_, AffineCharts.p f Y hY hπ hYs, AffineCharts.isAffineHom_p f Y hY hπ hYs,
    AffineCharts.locallyOfFiniteType_p f Y hY hπ hYs, AffineCharts.isIso_restrict f Y hY hπ hYs,
    AffineCharts.apply_mem f Y hY hπ hYs, AffineCharts.exists_chartIso f Y hY hπ hYs⟩
NeronModelInfra.Dilatations.DefectDecrease.JacobiLength.smoothnessDefect_Spec_eq
Source context 9 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
noncomputable section
namespace JacobiLength
open NeronModelInfra.SmootheningBounds.NeronSmootheningBound
  (globalAlgebra globalPointAlgebra smoothnessDefect_eq_length_torsion_global
    algebraMap_globalPointAlgebra_globalAlgebra length_torsion_eq_of_equiv)
theorem smoothnessDefect_Spec_eq {R : Type u} [CommRing R] {A : Type u} [CommRing A] [Algebra R A]
    {R' : Type u} [CommRing R'] [IsLocalRing R'] (φ : A →+* R') :
    let : Algebra A R' := φ.toAlgebra
    smoothnessDefect (Spec.map (CommRingCat.ofHom (algebraMap R A))) (Spec.map
      (CommRingCat.ofHom φ)) =
      Module.length R' (Submodule.torsion R' (R' ⊗[A] Ω[A⁄R])) := by
  intro iAR'
  rw [smoothnessDefect_eq_length_torsion_global]
  set Γ' : Type u := Γ(Spec (CommRingCat.of A), ⊤) with hΓ
  let iRΓ : Algebra R Γ(Spec (CommRingCat.of A), ⊤) :=
    globalAlgebra (Spec.map (CommRingCat.ofHom (algebraMap R A)))
  let iΓR' : Algebra Γ(Spec (CommRingCat.of A), ⊤) R' := globalPointAlgebra (Spec.map
    (CommRingCat.ofHom φ))
  let iΓA : Algebra Γ(Spec (CommRingCat.of A), ⊤) A := (Scheme.ΓSpecIso (CommRingCat.of
    A)).hom.hom.toAlgebra
  have : IsScalarTower R Γ(Spec (CommRingCat.of A), ⊤) A := IsScalarTower.of_algebraMap_eq' (by
    apply RingHom.ext; intro r
    change algebraMap R A r = (Scheme.ΓSpecIso (CommRingCat.of A)).hom.hom
      ((Spec.map (CommRingCat.ofHom (algebraMap R A))).appTop.hom
        ((Scheme.ΓSpecIso (CommRingCat.of R)).inv.hom r))
    rw [← CommRingCat.comp_apply, Scheme.ΓSpecIso_naturality, CommRingCat.comp_apply,
      ← CommRingCat.comp_apply (Scheme.ΓSpecIso (CommRingCat.of R)).inv, Iso.inv_hom_id]
    rfl)
  have : IsScalarTower Γ(Spec (CommRingCat.of A), ⊤) A R' := IsScalarTower.of_algebraMap_eq' (by
    change ((Scheme.stalkClosedPointTo (Spec.map (CommRingCat.ofHom φ))).hom.comp
      ((Spec (CommRingCat.of A)).presheaf.germ ⊤ _ trivial).hom) =
      φ.comp (Scheme.ΓSpecIso (CommRingCat.of A)).hom.hom
    rw [← CommRingCat.hom_comp, Scheme.germ_stalkClosedPointTo_Spec]
    rfl)
  have : IsLocalization.Away (1 : Γ(Spec (CommRingCat.of A), ⊤)) A :=
    IsLocalization.away_of_isUnit_of_bijective _ isUnit_one
      (ConcreteCategory.bijective_of_isIso (Scheme.ΓSpecIso (CommRingCat.of A)).hom)
  have : Algebra.FormallyEtale Γ(Spec (CommRingCat.of A), ⊤) A :=
    Algebra.FormallyEtale.of_isLocalization (Submonoid.powers (1 : Γ(Spec (CommRingCat.of A), ⊤)))
  let e₁ : A ⊗[Γ(Spec (CommRingCat.of A), ⊤)] Ω[Γ(Spec (CommRingCat.of A), ⊤)⁄R] ≃ₗ[A] Ω[A⁄R] :=
    KaehlerDifferential.tensorKaehlerEquivOfFormallyEtale R Γ(Spec (CommRingCat.of A), ⊤) A
  let e₂ := (e₁.symm.baseChange A R' _ _)
  let e₃ := TensorProduct.AlgebraTensorModule.cancelBaseChange Γ(Spec (CommRingCat.of A), ⊤) A
    R' R'
    Ω[Γ(Spec (CommRingCat.of A), ⊤)⁄R]
  exact (NeronModelInfra.SmootheningBounds.NeronSmootheningBound.length_torsion_eq_of_equiv
    (e₂.trans e₃)).symm
NeronModelInfra.Dilatations.DefectDecrease.JacobiLength.length_torsion_baseChange_kaehler_eq_of_formallyEtale
Source context 9 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
noncomputable section
namespace JacobiLength
open NeronModelInfra.SmootheningBounds.NeronSmootheningBound
  (globalAlgebra globalPointAlgebra smoothnessDefect_eq_length_torsion_global
    algebraMap_globalPointAlgebra_globalAlgebra length_torsion_eq_of_equiv)
theorem length_torsion_baseChange_kaehler_eq_of_formallyEtale
    (R : Type u) [CommRing R] (A S R' : Type u) [CommRing A] [CommRing S] [CommRing R']
    [Algebra R A] [Algebra R S] [Algebra A S] [IsScalarTower R A S]
    [Algebra A R'] [Algebra S R'] [IsScalarTower A S R'] [Algebra.FormallyEtale A S] :
    Module.length R' (Submodule.torsion R' (R' ⊗[S] Ω[S⁄R])) =
      Module.length R' (Submodule.torsion R' (R' ⊗[A] Ω[A⁄R]))
NeronModelInfra.Dilatations.DefectDecrease.JacobiLength.length_torsion_quotient_mono_of_forall_exists_smul_mem
Source context 9 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
noncomputable section
namespace JacobiLength
open NeronModelInfra.SmootheningBounds.NeronSmootheningBound
  (globalAlgebra globalPointAlgebra smoothnessDefect_eq_length_torsion_global
    algebraMap_globalPointAlgebra_globalAlgebra length_torsion_eq_of_equiv)
theorem length_torsion_quotient_mono_of_forall_exists_smul_mem
    {S : Type u} [CommRing S] [IsDomain S] {M : Type u} [AddCommGroup M] [Module S M]
    (N₁ N₂ : Submodule S M) (hle : N₁ ≤ N₂) (htor : ∀ x ∈ N₂, ∃ s : S, s ≠ 0 ∧ s • x ∈ N₁) :
    Module.length S (Submodule.torsion S (M ⧸ N₂)) ≤ Module.length S (Submodule.torsion S (M ⧸
      N₁))
NeronModelInfra.Dilatations.DefectDecrease.JacobiLength.one_tmul_smul_eq
Source context 9 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
noncomputable section
namespace JacobiLength
open NeronModelInfra.SmootheningBounds.NeronSmootheningBound
  (globalAlgebra globalPointAlgebra smoothnessDefect_eq_length_torsion_global
    algebraMap_globalPointAlgebra_globalAlgebra length_torsion_eq_of_equiv)
theorem one_tmul_smul_eq {S T : Type u} [CommRing S] [CommRing T] [Algebra S T] {M : Type u}
  [AddCommGroup M]
    [Module S M] (c : S) (m : M) :
    ((1 : T) ⊗ₜ[S] (c • m) : T ⊗[S] M) = algebraMap S T c • ((1 : T) ⊗ₜ[S] m)
NeronModelInfra.Dilatations.DefectDecrease.JacobiLength.length_torsion_add_one_le_of_diagonal_map
Source context 9 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
noncomputable section
namespace JacobiLength
open NeronModelInfra.SmootheningBounds.NeronSmootheningBound
  (globalAlgebra globalPointAlgebra smoothnessDefect_eq_length_torsion_global
    algebraMap_globalPointAlgebra_globalAlgebra length_torsion_eq_of_equiv)
theorem length_torsion_add_one_le_of_diagonal_map
    {R' : Type u} [CommRing R'] [IsDomain R'] [IsDiscreteValuationRing R']
    (π' : R') (hπ'irr : Irreducible π') (r n : ℕ)
    {M M' : Type u} [AddCommGroup M] [Module R' M] [AddCommGroup M'] [Module R' M']
    (N : Submodule R' M) (N'' : Submodule R' M')
    (κ : M ≃ₗ[R'] ((Fin r → R') × (Fin n → R')))
    (κ' : M' ≃ₗ[R'] ((Fin r → R') × (Fin n → R')))
    (hNcDm : (N.map κ.toLinearMap).map
        ((LinearMap.id : (Fin r → R') →ₗ[R'] (Fin r → R')).prodMap
          (π' • (LinearMap.id : (Fin n → R') →ₗ[R'] (Fin n → R')))) =
        (Ideal.span {π' ^ 2} : Ideal R') • N''.map κ'.toLinearMap) :
    Module.length R' (Submodule.torsion R' (M' ⧸ N'')) + 1 ≤
      max 1 (Module.length R' (Submodule.torsion R' (M ⧸ N)))
NeronModelInfra.Dilatations.DefectDecrease.JacobiLength.center_comap_saturated
Source context 9 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
noncomputable section
namespace JacobiLength
open NeronModelInfra.SmootheningBounds.NeronSmootheningBound
  (globalAlgebra globalPointAlgebra smoothnessDefect_eq_length_torsion_global
    algebraMap_globalPointAlgebra_globalAlgebra length_torsion_eq_of_equiv)
theorem center_comap_saturated
    {R A C Ag : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
    [CommRing A] [CommRing C] [CommRing Ag] [Algebra R A] [Algebra R C]
    [Algebra R Ag] [Algebra A Ag] [Algebra C Ag]
    [IsScalarTower R A Ag] [IsScalarTower R C Ag]
    (g : A) [IsLocalization.Away g Ag] (J : Ideal A) (JC : Ideal C)
    (hJC : Ideal.comap (algebraMap C Ag) (J.map (algebraMap A Ag)) = JC)
    (hN : ∀ g₀ : A,
      (∀ (R'' : Type u) [CommRing R''] [IsDomain R''] [IsDiscreteValuationRing R'']
        [Algebra R R''] [IsLocalHom (algebraMap R R'')], IsIndexOneExtension R R'' →
        ∀ c : A →ₐ[R] R'', J ≤ (IsLocalRing.maximalIdeal R'').comap c →
          g₀ ∈ (IsLocalRing.maximalIdeal R'').comap c) → g₀ ∈ J) :
    ∀ g₀ : C,
      (∀ (R'' : Type u) [CommRing R''] [IsDomain R''] [IsDiscreteValuationRing R''] [Algebra R R'']
        [IsLocalHom (algebraMap R R'')], IsIndexOneExtension R R'' →
        ∀ c : C →ₐ[R] R'', RingHom.ker (algebraMap C Ag) ≤ RingHom.ker c.toRingHom →
          JC ≤ (IsLocalRing.maximalIdeal R'').comap c → g₀ ∈ (IsLocalRing.maximalIdeal
            R'').comap c) →
      g₀ ∈ JC
NeronModelInfra.Dilatations.DefectDecrease.JacobiLength.length_torsion_kaehler_quotient_le

Saturating divided relations can only decrease the torsion length of differentials.

Source context 9 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
noncomputable section
namespace JacobiLength
open NeronModelInfra.SmootheningBounds.NeronSmootheningBound
  (globalAlgebra globalPointAlgebra smoothnessDefect_eq_length_torsion_global
    algebraMap_globalPointAlgebra_globalAlgebra length_torsion_eq_of_equiv)
theorem length_torsion_kaehler_quotient_le
    {R C C' B S : Type u} [CommRing R] [CommRing C] [CommRing C'] [CommRing B]
    [CommRing S] [IsDomain S] [Algebra R C'] [Algebra C C'] [Algebra C' S]
    (I : Ideal C) (π : R) (θ : C' →+* B) (fp : I → C')
    (hfp : ∀ f : I, (algebraMap R C' π) ^ 2 * fp f = algebraMap C C' (f : C))
    (hθι : ∀ f : I, θ (algebraMap C C' (f : C)) = 0)
    (hθfp : ∀ f : I, θ (fp f) = 0)
    (hθk : ∀ x, θ x = 0 → ∃ ν : ℕ,
      (algebraMap R C' π) ^ ν * x ∈ I.map (algebraMap C C'))
    (hπne : algebraMap C' S (algebraMap R C' π) ≠ 0)
    (hzero : ∀ x, θ x = 0 → algebraMap C' S x = 0) :
    Module.length S (Submodule.torsion S
      ((S ⊗[C'] Ω[C'⁄R]) ⧸ Submodule.span S
        (Set.range fun x : RingHom.ker θ => (1 : S) ⊗ₜ[C'] D R C' (x : C')))) ≤
    Module.length S (Submodule.torsion S
      ((S ⊗[C'] Ω[C'⁄R]) ⧸ Submodule.span S
        (Set.range fun f : I => (1 : S) ⊗ₜ[C'] D R C' (fp f)))) := by
  let N'full : Submodule S (S ⊗[C'] Ω[C'⁄R]) :=
    Submodule.span S (Set.range fun x : RingHom.ker θ => (1 : S) ⊗ₜ[C'] D R C' (x : C'))
  let N'' : Submodule S (S ⊗[C'] Ω[C'⁄R]) :=
    Submodule.span S (Set.range fun f : I => (1 : S) ⊗ₜ[C'] D R C' (fp f))
  let πS : S := algebraMap C' S (algebraMap R C' π)
  have hπS : algebraMap C' S (algebraMap R C' π) = πS := rfl
  have hN''le : N'' ≤ N'full := by
    refine Submodule.span_le.mpr ?_
    rintro _ ⟨f, rfl⟩
    exact Submodule.subset_span ⟨⟨fp f, RingHom.mem_ker.mpr (hθfp f)⟩, rfl⟩
  have htmul : ∀ (c : C') (m : Ω[C'⁄R]),
      ((1 : S) ⊗ₜ[C'] (c • m) : S ⊗[C'] Ω[C'⁄R]) = algebraMap C' S c • ((1 : S) ⊗ₜ[C'] m) :=
    fun c m => one_tmul_smul_eq c m
  have hπsq : (algebraMap R C' π) ^ 2 = algebraMap R C' (π ^ 2) := (map_pow _ _ _).symm
  have hIC' : ∀ x ∈ I.map (algebraMap C C'),
      θ x = 0 ∧ ((1 : S) ⊗ₜ[C'] D R C' x) ∈ N'' := by
    intro x hx
    refine Submodule.span_induction (p := fun x _ => θ x = 0 ∧ ((1 : S) ⊗ₜ[C'] D R C' x) ∈
      N'') ?_ ?_ ?_ ?_ hx
    · rintro _ ⟨f, hf, rfl⟩
      refine ⟨hθι ⟨f, hf⟩, ?_⟩
      rw [← hfp ⟨f, hf⟩, Derivation.leibniz, hπsq, Derivation.map_algebraMap, smul_zero,
        add_zero, htmul]
      exact N''.smul_mem _ (Submodule.subset_span ⟨⟨f, hf⟩, rfl⟩)
    · exact ⟨map_zero _, by rw [map_zero, TensorProduct.tmul_zero]; exact Submodule.zero_mem _⟩
    · rintro x y - - ⟨hx0, hx⟩ ⟨hy0, hy⟩
      refine ⟨by rw [map_add, hx0, hy0, add_zero], ?_⟩
      rw [map_add, TensorProduct.tmul_add]
      exact N''.add_mem hx hy
    · rintro c x - ⟨hx0, hx⟩
      refine ⟨by rw [smul_eq_mul, map_mul, hx0, mul_zero], ?_⟩
      rw [smul_eq_mul, Derivation.leibniz, TensorProduct.tmul_add, htmul, htmul]
      have hψx : algebraMap C' S x = 0 := hzero x hx0
      rw [hψx, zero_smul, add_zero]
      exact N''.smul_mem _ hx
  have htors : ∀ x ∈ N'full, ∃ s : S, s ≠ 0 ∧ s • x ∈ N'' := by
    intro x hx
    refine Submodule.span_induction (p := fun x _ => ∃ s : S, s ≠ 0 ∧ s • x ∈ N'') ?_ ?_ ?_ ?_ hx
    · rintro _ ⟨⟨f', hf'⟩, rfl⟩
      have h0 : θ f' = 0 := RingHom.mem_ker.mp hf'
      obtain ⟨ν, hν⟩ := hθk f' h0
      refine ⟨πS ^ ν, pow_ne_zero ν hπne, ?_⟩
      have h1 := (hIC' _ hν).2
      rw [Derivation.leibniz, TensorProduct.tmul_add, htmul, htmul, map_pow, hπS] at h1
      have h2 : (D R C') ((algebraMap R _ π) ^ ν) = 0 := by
        rw [← map_pow]; exact Derivation.map_algebraMap _ _
      rw [h2, TensorProduct.tmul_zero, smul_zero, add_zero] at h1
      simpa only using h1
    · exact ⟨1, one_ne_zero, by rw [smul_zero]; exact Submodule.zero_mem _⟩
    · rintro x y - - ⟨s, hs, hsx⟩ ⟨t, ht, hty⟩
      refine ⟨s * t, mul_ne_zero hs ht, ?_⟩
      rw [smul_add]
      exact N''.add_mem (by rw [mul_comm, mul_smul]; exact N''.smul_mem t hsx)
        (by rw [mul_smul]; exact N''.smul_mem s hty)
    · rintro a x - ⟨s, hs, hsx⟩
      refine ⟨s, hs, ?_⟩
      rw [smul_comm]
      exact N''.smul_mem _ hsx
  exact length_torsion_quotient_mono_of_forall_exists_smul_mem N'' N'full hN''le htors
NeronModelInfra.Dilatations.DefectDecrease.JacobiLength.length_torsion_kaehler_quotients_add_one_le

Dividing the normal coordinates by a uniformizer strictly lowers the torsion defect.

Source context 9 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
noncomputable section
namespace JacobiLength
open NeronModelInfra.SmootheningBounds.NeronSmootheningBound
  (globalAlgebra globalPointAlgebra smoothnessDefect_eq_length_torsion_global
    algebraMap_globalPointAlgebra_globalAlgebra length_torsion_eq_of_equiv)
theorem length_torsion_kaehler_quotients_add_one_le
    {R C C' S : Type u} [CommRing R] [CommRing C] [CommRing C']
    [CommRing S] [IsDomain S] [IsDiscreteValuationRing S]
    [Algebra R C] [Algebra R C'] [Algebra C C'] [IsScalarTower R C C']
    [Algebra C S] [Algebra C' S] [IsScalarTower C C' S]
    (π : R) (πS : S) (hπirr : Irreducible πS)
    (hπS : algebraMap C' S (algebraMap R C' π) = πS) (r n : ℕ)
    (b : Module.Basis (Fin r ⊕ Fin n) C Ω[C⁄R])
    (b' : Module.Basis (Fin r ⊕ Fin n) C' Ω[C'⁄R])
    (hmap_y : ∀ i, KaehlerDifferential.map R R C C' (b (Sum.inl i)) = b' (Sum.inl i))
    (hmap_z : ∀ j, KaehlerDifferential.map R R C C' (b (Sum.inr j)) =
      algebraMap R C' π • b' (Sum.inr j))
    (I : Ideal C) (fp : I → C')
    (hfp : ∀ f : I, (algebraMap R C' π) ^ 2 * fp f = algebraMap C C' (f : C)) :
    Module.length S (Submodule.torsion S
      ((S ⊗[C'] Ω[C'⁄R]) ⧸ Submodule.span S
        (Set.range fun f : I => (1 : S) ⊗ₜ[C'] D R C' (fp f)))) + 1 ≤
    max 1 (Module.length S (Submodule.torsion S
      ((S ⊗[C] Ω[C⁄R]) ⧸ Submodule.span S
        (Set.range fun f : I => (1 : S) ⊗ₜ[C] D R C (f : C))))) := by
  classical
  let N : Submodule S (S ⊗[C] Ω[C⁄R]) :=
    Submodule.span S (Set.range fun f : I => (1 : S) ⊗ₜ[C] D R C (f : C))
  let N'' : Submodule S (S ⊗[C'] Ω[C'⁄R]) :=
    Submodule.span S (Set.range fun f : I => (1 : S) ⊗ₜ[C'] D R C' (fp f))
  have htmul : ∀ (c : C') (m : Ω[C'⁄R]),
      ((1 : S) ⊗ₜ[C'] (c • m) : S ⊗[C'] Ω[C'⁄R]) =
        algebraMap C' S c • ((1 : S) ⊗ₜ[C'] m) := fun c m => one_tmul_smul_eq c m
  have hπsq : (algebraMap R C' π) ^ 2 = algebraMap R C' (π ^ 2) := (map_pow _ _ _).symm
  let bF := Algebra.TensorProduct.basis S b
  let bF' := Algebra.TensorProduct.basis S b'
  let e0 : (Fin r ⊕ Fin n → S) ≃ₗ[S] ((Fin r → S) × (Fin n → S)) :=
    LinearEquiv.sumArrowLequivProdArrow (Fin r) (Fin n) S S
  let κ : (S ⊗[C] Ω[C⁄R]) ≃ₗ[S] ((Fin r → S) × (Fin n → S)) := bF.equivFun.trans e0
  let κ' : (S ⊗[C'] Ω[C'⁄R]) ≃ₗ[S] ((Fin r → S) × (Fin n → S)) := bF'.equivFun.trans e0
  let Dm : ((Fin r → S) × (Fin n → S)) →ₗ[S] ((Fin r → S) × (Fin n → S)) := (LinearMap.id :
    (Fin r → S) →ₗ[S] (Fin r → S)).prodMap
    (πS • (LinearMap.id : (Fin n → S) →ₗ[S] (Fin n → S)))
  have he0 : ∀ f : Fin r ⊕ Fin n → S, e0 f = (fun i => f (Sum.inl i), fun j => f (Sum.inr j)) :=
    fun f => rfl
  have hDmap : ∀ (u : Fin r → S) (w : Fin n → S), Dm (u, w) = (u, πS • w) := fun u w => rfl
  let Φ : (S ⊗[C] Ω[C⁄R]) →ₗ[S] (S ⊗[C'] Ω[C'⁄R]) :=
    ((KaehlerDifferential.mapBaseChange R C C').baseChange S).comp
      (TensorProduct.AlgebraTensorModule.cancelBaseChange C C' S S Ω[C⁄R]).symm.toLinearMap
  have hΦ : ∀ m : Ω[C⁄R], Φ ((1 : S) ⊗ₜ[C] m) = (1 : S) ⊗ₜ[C'] KaehlerDifferential.map R R C
    C' m := by
    intro m
    change ((KaehlerDifferential.mapBaseChange R C C').baseChange S)
      ((TensorProduct.AlgebraTensorModule.cancelBaseChange C C' S S Ω[C⁄R]).symm ((1 : S)
        ⊗ₜ[C] m)) = _
    rw [TensorProduct.AlgebraTensorModule.cancelBaseChange_symm_tmul, LinearMap.baseChange_tmul,
      KaehlerDifferential.mapBaseChange_tmul]
    exact congrArg ((1 : S) ⊗ₜ[C'] ·) (one_smul C' ((KaehlerDifferential.map R R C C') m))
  have hKC : (κ'.toLinearMap.comp Φ) = Dm.comp κ.toLinearMap := by
    refine bF.ext fun k => ?_
    rcases k with i | j
    · simp only [LinearMap.comp_apply, LinearEquiv.coe_coe]
      have h1 : Φ (bF (Sum.inl i)) = bF' (Sum.inl i) := by
        rw [Algebra.TensorProduct.basis_apply, hΦ, hmap_y, (Algebra.TensorProduct.basis_apply b'
          _).symm]
      change κ' (Φ (bF (Sum.inl i))) = Dm (κ (bF (Sum.inl i)))
      rw [h1]
      change e0 (bF'.equivFun (bF' (Sum.inl i))) = Dm (e0 (bF.equivFun (bF (Sum.inl i))))
      refine Prod.ext (funext fun i' => ?_) (funext fun j' => ?_)
      · simp only [Module.Basis.equivFun_apply, Module.Basis.repr_self, he0, hDmap]
      · simp only [Module.Basis.equivFun_apply, Module.Basis.repr_self, he0, hDmap]
        simp only [Finsupp.single_apply, Sum.inl_ne_inr, ite_false, Pi.smul_apply, smul_zero]
    · simp only [LinearMap.comp_apply, LinearEquiv.coe_coe]
      have h1 : Φ (bF (Sum.inr j)) = πS • bF' (Sum.inr j) := by
        rw [Algebra.TensorProduct.basis_apply, hΦ, hmap_z, htmul, hπS,
          (Algebra.TensorProduct.basis_apply b' _).symm]
      change κ' (Φ (bF (Sum.inr j))) = Dm (κ (bF (Sum.inr j)))
      rw [h1, map_smul]
      change πS • e0 (bF'.equivFun (bF' (Sum.inr j))) = Dm (e0 (bF.equivFun (bF (Sum.inr j))))
      refine Prod.ext (funext fun i' => ?_) (funext fun j' => ?_)
      · simp only [Module.Basis.equivFun_apply, Module.Basis.repr_self, he0, hDmap]
        simp only [Finsupp.single_apply, Sum.inr_ne_inl, ite_false, Prod.smul_fst,
          Pi.smul_apply, smul_zero]
      · simp only [Module.Basis.equivFun_apply, Module.Basis.repr_self, he0, hDmap]
        rfl
  let I2 : Ideal S := Ideal.span {πS ^ 2}
  have hΦgen : ∀ f : I,
      Φ ((1 : S) ⊗ₜ[C] D R C (f : C)) = (πS ^ 2) • ((1 : S) ⊗ₜ[C'] D R C' (fp f)) := by
    intro f
    rw [hΦ, KaehlerDifferential.map_D, ← hfp f, Derivation.leibniz, hπsq,
      Derivation.map_algebraMap, smul_zero,
      add_zero, ← hπsq, htmul, map_pow, hπS]
  have hNΦ : N.map Φ = I2 • N'' := by
    apply le_antisymm
    · rw [Submodule.map_span, Submodule.span_le]
      rintro _ ⟨_, ⟨f, rfl⟩, rfl⟩
      rw [hΦgen]
      exact Submodule.smul_mem_smul (Ideal.mem_span_singleton_self _) (Submodule.subset_span ⟨f,
        rfl⟩)
    · rw [Submodule.smul_le]
      rintro a ha x hx
      obtain ⟨t, rfl⟩ := Ideal.mem_span_singleton'.mp ha
      rw [mul_smul]
      refine Submodule.smul_mem _ t ?_
      have hle : N'' ≤ (N.map Φ).comap ((πS ^ 2) • LinearMap.id) := by
        refine Submodule.span_le.mpr ?_
        rintro _ ⟨f, rfl⟩
        change ((1 : S) ⊗ₜ[C'] D R C' (fp f)) ∈ Submodule.comap ((πS ^ 2) • LinearMap.id)
          (N.map Φ)
        rw [Submodule.mem_comap, LinearMap.smul_apply, LinearMap.id_apply, ← hΦgen]
        exact Submodule.mem_map_of_mem (Submodule.subset_span ⟨f, rfl⟩)
      simpa only [Submodule.mem_comap, LinearMap.smul_apply, LinearMap.id_apply] using hle hx
  have hNcDm : (N.map κ.toLinearMap).map Dm = I2 • N''.map κ'.toLinearMap := by
    rw [← Submodule.map_comp, ← hKC, Submodule.map_comp, hNΦ, Submodule.map_smul'']
  exact length_torsion_add_one_le_of_diagonal_map πS hπirr r n N N'' κ κ' hNcDm
NeronModelInfra.Dilatations.DefectDecrease.JacobiLength.exists_compatible_localization_point

Compatible points lift to the localized dilatation and agree on the localized base.

Source context 9 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
noncomputable section
namespace JacobiLength
open NeronModelInfra.SmootheningBounds.NeronSmootheningBound
  (globalAlgebra globalPointAlgebra smoothnessDefect_eq_length_torsion_global
    algebraMap_globalPointAlgebra_globalAlgebra length_torsion_eq_of_equiv)
theorem exists_compatible_localization_point
    {A Ag A' B S : Type u} [CommRing A] [CommRing Ag] [CommRing A'] [CommRing B]
    [CommRing S] [Algebra A Ag] [Algebra A A'] [Algebra A B] [Algebra A' B]
    [Algebra Ag B] [IsScalarTower A Ag B] (g : A) [IsLocalization.Away g Ag]
    [IsLocalization (Algebra.algebraMapSubmonoid A' (Submonoid.powers g)) B]
    (φ : A →+* S) (φg : Ag →+* S) (φ' : A' →+* S) (hg : IsUnit (φ g))
    (hφg : ∀ a, φg (algebraMap A Ag a) = φ a)
    (hφ' : ∀ a, φ' (algebraMap A A' a) = φ a)
    (hA : (algebraMap A' B).comp (algebraMap A A') = algebraMap A B) :
    ∃ φB : B →+* S, (∀ a', φB (algebraMap A' B a') = φ' a') ∧
      φB.comp (algebraMap Ag B) = φg
NeronModelInfra.Dilatations.DefectDecrease.JacobiLength.length_torsion_decrease_of_smooth_presentation

A smooth presentation with quadratic relations decreases the differential torsion length.

Source context 9 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
noncomputable section
namespace JacobiLength
open NeronModelInfra.SmootheningBounds.NeronSmootheningBound
  (globalAlgebra globalPointAlgebra smoothnessDefect_eq_length_torsion_global
    algebraMap_globalPointAlgebra_globalAlgebra length_torsion_eq_of_equiv)
theorem length_torsion_decrease_of_smooth_presentation
    {R C A C' B S : Type u} [CommRing R] [CommRing C] [CommRing A] [CommRing C']
    [CommRing B] [CommRing S] [IsDomain S] [IsDiscreteValuationRing S]
    [Algebra R C] [Algebra R A] [Algebra C A] [IsScalarTower R C A]
    [Algebra R C'] [Algebra C C'] [IsScalarTower R C C']
    [Algebra R B] [Algebra C' B] [IsScalarTower R C' B]
    [Algebra C S] [Algebra A S] [IsScalarTower C A S]
    [Algebra C' S] [Algebra B S] [IsScalarTower C' B S] [IsScalarTower C C' S]
    (π : R) (πS : S) (hπirr : Irreducible πS)
    (hπS : algebraMap C' S (algebraMap R C' π) = πS)
    (J : Ideal C) (hIJ2 : RingHom.ker (algebraMap C A) ≤ J ^ 2)
    (hJmap : J.map (algebraMap C C') = Ideal.span {algebraMap R C' π})
    (hreg : ∀ x : B, algebraMap C' B (algebraMap R C' π) ^ 2 * x = 0 → x = 0)
    (hkill : ∀ f : RingHom.ker (algebraMap C A), algebraMap C' B (algebraMap C C' (f : C)) = 0)
    (hker : ∀ x, algebraMap C' B x = 0 ↔ ∃ ν : ℕ, (algebraMap R C' π) ^ ν * x ∈
      (RingHom.ker (algebraMap C A)).map (algebraMap C C'))
    (hsurj : Function.Surjective (algebraMap C A))
    (hsurj' : Function.Surjective (algebraMap C' B))
    (r n : ℕ) (b : Module.Basis (Fin r ⊕ Fin n) C Ω[C⁄R])
    (b' : Module.Basis (Fin r ⊕ Fin n) C' Ω[C'⁄R])
    (hmap_y : ∀ i, KaehlerDifferential.map R R C C' (b (Sum.inl i)) = b' (Sum.inl i))
    (hmap_z : ∀ j, KaehlerDifferential.map R R C C' (b (Sum.inr j)) =
      algebraMap R C' π • b' (Sum.inr j)) :
    Module.length S (Submodule.torsion S (S ⊗[B] Ω[B⁄R])) + 1 ≤
      max 1 (Module.length S (Submodule.torsion S (S ⊗[A] Ω[A⁄R])))
NeronModelInfra.smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus
Source context 7 commands

Surrounding namespaces, section variables, and local commands at this declaration.

@[expose] public section
section
/-
Anthropic FLT upstream notice: Copyright 2026 Anthropic, PBC.
Released under Apache 2.0 license as described in the file LICENSE.
Adapted Anthropic FLT source (pinned revision):
https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/P2M/Sol/S_NeronModelInfra_smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus.lean
Upstream NOTICE: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/NOTICE
Upstream per-file ATTRIBUTION: https://github.com/anthropics/fermats-last-theorem/blob/6e837e75355538c7f80bab5b956861e86c4eacc2/ATTRIBUTION.md
Copies of these notices are retained in the AbelianVarieties directory.
Existing upstream author/copyright comments in the source are retained below.

Local adaptation and maintenance: Naganori Yamaguchi (https://github.com/n-yamaguchi-0729).
AI assistance in local adaptation and maintenance: OpenAI Codex.
-/
namespace NeronModelInfra.Dilatations.DefectDecrease
open CategoryTheory CategoryTheory.Limits AlgebraicGeometry NeronModelInfra TensorProduct
universe u
open KaehlerDifferential IsLocalRing
open JacobiLength in
theorem
  _root_.NeronModelInfra.smoothnessDefect_affineDilatation_add_one_le_of_isSmoothAt_of_mem_freeLocus
    {R : Type u} [CommRing R] [IsDomain R] [IsDiscreteValuationRing R]
    (π : R) (hπ : IsLocalRing.maximalIdeal R = Ideal.span {π})
    {A : Type u} [CommRing A] [Algebra R A] [Algebra.FiniteType R A]
    (J : Ideal A) (hπJ : algebraMap R A π ∈ J)
    [Algebra (IsLocalRing.ResidueField R) (A ⧸ J)] [IsScalarTower R (IsLocalRing.ResidueField R)
      (A ⧸ J)]
    (hN : ∀ g : A,
      (∀ (R'' : Type u) [CommRing R''] [IsDomain R''] [IsDiscreteValuationRing R''] [Algebra R R'']
        [IsLocalHom (algebraMap R R'')], IsIndexOneExtension R R'' →
        ∀ c : A →ₐ[R] R'', J ≤ (IsLocalRing.maximalIdeal R'').comap c →
          g ∈ (IsLocalRing.maximalIdeal R'').comap c) → g ∈ J)
    (R' : Type u) [CommRing R'] [IsDomain R'] [IsDiscreteValuationRing R'] [Algebra R R']
    [IsLocalHom (algebraMap R R')] (hR' : IsIndexOneExtension R R')
    (φ : A →ₐ[R] R') (_ : PrimeSpectrum.comap φ.toRingHom (⊥ : PrimeSpectrum R') ∈
      Algebra.smoothLocus R A)
    (𝔮 : Ideal (A ⧸ J)) [𝔮.IsPrime] (h𝔮 : 𝔮.comap (Ideal.Quotient.mk J) =
      (IsLocalRing.maximalIdeal R').comap φ)
    (hsmooth : Algebra.IsSmoothAt (IsLocalRing.ResidueField R) 𝔮)
    (hfree : (⟨𝔮, ‹_›⟩ : PrimeSpectrum (A ⧸ J)) ∈
      Module.freeLocus (A ⧸ J) ((A ⧸ J) ⊗[A] Ω[A⁄R]))
    (φ' : AffineDilatation.Ring J (algebraMap R A π) →ₐ[R] R')
    (hφ' : ∀ a : A, φ' (algebraMap A (AffineDilatation.Ring J (algebraMap R A π)) a) = φ a) :
    smoothnessDefect
        (Spec.map (CommRingCat.ofHom (algebraMap R (AffineDilatation.Ring J (algebraMap R A π)))))
        (Spec.map (CommRingCat.ofHom φ'.toRingHom)) + 1 ≤
      max 1 (smoothnessDefect (Spec.map (CommRingCat.ofHom (algebraMap R A)))
        (Spec.map (CommRingCat.ofHom φ.toRingHom)))