Theorem: AlgebraicGeometry.IsAffineOpen.appLE_eq_away_map
File: Mathlib/AlgebraicGeometry/AffineScheme.lean

Proof steps:
state_before: X✝ Y✝ : Scheme
U✝ : X✝.Opens
hU✝ : IsAffineOpen U✝
f✝ : ↑Γ(X✝, U✝)
X Y : Scheme
f : X ⟶ Y
U : Y.Opens
hU : IsAffineOpen U
V : X.Opens
hV : IsAffineOpen V
e : V ≤ f ⁻¹ᵁ U
r : ↑Γ(Y, U)
this✝ : IsLocalization.Away r ↑Γ(Y, Y.basicOpen r) := isLocalization_basicOpen hU r
this : IsLocalization.Away ((Scheme.Hom.appLE f U V e) r) ↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)) :=
  isLocalization_basicOpen hV ((Scheme.Hom.appLE f U V e) r)
⊢ X.basicOpen ((Scheme.Hom.appLE f U V e) r) ≤ f ⁻¹ᵁ Y.basicOpen r
state_after: no goals
tactic: simp [Scheme.Hom.appLE]
state_before: X✝ Y✝ : Scheme
U✝ : X✝.Opens
hU✝ : IsAffineOpen U✝
f✝ : ↑Γ(X✝, U✝)
X Y : Scheme
f : X ⟶ Y
U : Y.Opens
hU : IsAffineOpen U
V : X.Opens
hV : IsAffineOpen V
e : V ≤ f ⁻¹ᵁ U
r : ↑Γ(Y, U)
⊢ Scheme.Hom.appLE f (Y.basicOpen r) (X.basicOpen ((Scheme.Hom.appLE f U V e) r)) ⋯ =
    IsLocalization.Away.map (↑Γ(Y, Y.basicOpen r)) (↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)))
      (Scheme.Hom.appLE f U V e) r
state_after: X✝ Y✝ : Scheme
U✝ : X✝.Opens
hU✝ : IsAffineOpen U✝
f✝ : ↑Γ(X✝, U✝)
X Y : Scheme
f : X ⟶ Y
U : Y.Opens
hU : IsAffineOpen U
V : X.Opens
hV : IsAffineOpen V
e : V ≤ f ⁻¹ᵁ U
r : ↑Γ(Y, U)
this : IsLocalization.Away r ↑Γ(Y, Y.basicOpen r) := isLocalization_basicOpen hU r
⊢ Scheme.Hom.appLE f (Y.basicOpen r) (X.basicOpen ((Scheme.Hom.appLE f U V e) r)) ⋯ =
    IsLocalization.Away.map (↑Γ(Y, Y.basicOpen r)) (↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)))
      (Scheme.Hom.appLE f U V e) r
tactic: letI := hU.isLocalization_basicOpen r
state_before: X✝ Y✝ : Scheme
U✝ : X✝.Opens
hU✝ : IsAffineOpen U✝
f✝ : ↑Γ(X✝, U✝)
X Y : Scheme
f : X ⟶ Y
U : Y.Opens
hU : IsAffineOpen U
V : X.Opens
hV : IsAffineOpen V
e : V ≤ f ⁻¹ᵁ U
r : ↑Γ(Y, U)
this : IsLocalization.Away r ↑Γ(Y, Y.basicOpen r) := isLocalization_basicOpen hU r
⊢ Scheme.Hom.appLE f (Y.basicOpen r) (X.basicOpen ((Scheme.Hom.appLE f U V e) r)) ⋯ =
    IsLocalization.Away.map (↑Γ(Y, Y.basicOpen r)) (↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)))
      (Scheme.Hom.appLE f U V e) r
state_after: X✝ Y✝ : Scheme
U✝ : X✝.Opens
hU✝ : IsAffineOpen U✝
f✝ : ↑Γ(X✝, U✝)
X Y : Scheme
f : X ⟶ Y
U : Y.Opens
hU : IsAffineOpen U
V : X.Opens
hV : IsAffineOpen V
e : V ≤ f ⁻¹ᵁ U
r : ↑Γ(Y, U)
this✝ : IsLocalization.Away r ↑Γ(Y, Y.basicOpen r) := isLocalization_basicOpen hU r
this : IsLocalization.Away ((Scheme.Hom.appLE f U V e) r) ↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)) :=
  isLocalization_basicOpen hV ((Scheme.Hom.appLE f U V e) r)
⊢ Scheme.Hom.appLE f (Y.basicOpen r) (X.basicOpen ((Scheme.Hom.appLE f U V e) r)) ⋯ =
    IsLocalization.Away.map (↑Γ(Y, Y.basicOpen r)) (↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)))
      (Scheme.Hom.appLE f U V e) r
tactic: letI := hV.isLocalization_basicOpen (f.appLE U V e r)
state_before: X✝ Y✝ : Scheme
U✝ : X✝.Opens
hU✝ : IsAffineOpen U✝
f✝ : ↑Γ(X✝, U✝)
X Y : Scheme
f : X ⟶ Y
U : Y.Opens
hU : IsAffineOpen U
V : X.Opens
hV : IsAffineOpen V
e : V ≤ f ⁻¹ᵁ U
r : ↑Γ(Y, U)
this✝ : IsLocalization.Away r ↑Γ(Y, Y.basicOpen r) := isLocalization_basicOpen hU r
this : IsLocalization.Away ((Scheme.Hom.appLE f U V e) r) ↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)) :=
  isLocalization_basicOpen hV ((Scheme.Hom.appLE f U V e) r)
⊢ Scheme.Hom.appLE f (Y.basicOpen r) (X.basicOpen ((Scheme.Hom.appLE f U V e) r)) ⋯ =
    IsLocalization.Away.map (↑Γ(Y, Y.basicOpen r)) (↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)))
      (Scheme.Hom.appLE f U V e) r
state_after: case h
X✝ Y✝ : Scheme
U✝ : X✝.Opens
hU✝ : IsAffineOpen U✝
f✝ : ↑Γ(X✝, U✝)
X Y : Scheme
f : X ⟶ Y
U : Y.Opens
hU : IsAffineOpen U
V : X.Opens
hV : IsAffineOpen V
e : V ≤ f ⁻¹ᵁ U
r : ↑Γ(Y, U)
this✝ : IsLocalization.Away r ↑Γ(Y, Y.basicOpen r) := isLocalization_basicOpen hU r
this : IsLocalization.Away ((Scheme.Hom.appLE f U V e) r) ↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)) :=
  isLocalization_basicOpen hV ((Scheme.Hom.appLE f U V e) r)
⊢ RingHom.comp (Scheme.Hom.appLE f (Y.basicOpen r) (X.basicOpen ((Scheme.Hom.appLE f U V e) r)) ⋯)
      (algebraMap ↑Γ(Y, U) ↑Γ(Y, Y.basicOpen r)) =
    (IsLocalization.Away.map (↑Γ(Y, Y.basicOpen r)) (↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)))
          (Scheme.Hom.appLE f U V e) r).comp
      (algebraMap ↑Γ(Y, U) ↑Γ(Y, Y.basicOpen r))
tactic: apply IsLocalization.ringHom_ext (.powers r)
state_before: case h
X✝ Y✝ : Scheme
U✝ : X✝.Opens
hU✝ : IsAffineOpen U✝
f✝ : ↑Γ(X✝, U✝)
X Y : Scheme
f : X ⟶ Y
U : Y.Opens
hU : IsAffineOpen U
V : X.Opens
hV : IsAffineOpen V
e : V ≤ f ⁻¹ᵁ U
r : ↑Γ(Y, U)
this✝ : IsLocalization.Away r ↑Γ(Y, Y.basicOpen r) := isLocalization_basicOpen hU r
this : IsLocalization.Away ((Scheme.Hom.appLE f U V e) r) ↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)) :=
  isLocalization_basicOpen hV ((Scheme.Hom.appLE f U V e) r)
⊢ RingHom.comp (Scheme.Hom.appLE f (Y.basicOpen r) (X.basicOpen ((Scheme.Hom.appLE f U V e) r)) ⋯)
      (algebraMap ↑Γ(Y, U) ↑Γ(Y, Y.basicOpen r)) =
    (IsLocalization.Away.map (↑Γ(Y, Y.basicOpen r)) (↑Γ(X, X.basicOpen ((Scheme.Hom.appLE f U V e) r)))
          (Scheme.Hom.appLE f U V e) r).comp
      (algebraMap ↑Γ(Y, U) ↑Γ(Y, Y.basicOpen r))
state_after: no goals
tactic: rw [← CommRingCat.comp_eq_ring_hom_comp, IsLocalization.Away.map, IsLocalization.map_comp,
    RingHom.algebraMap_toAlgebra, RingHom.algebraMap_toAlgebra, ← CommRingCat.comp_eq_ring_hom_comp,
    Scheme.Hom.appLE_map, Scheme.Hom.map_appLE]