Skip to content

Commit 405fef5

Browse files
committed
chore(AlgebraicGeometry/Restrict): remove erws (#38765)
- replaces the `erw`-based argument in `isPullback_morphismRestrict` with `IsOpenImmersion.isPullback` - shortens `morphismRestrictRestrictBasicOpen` to a direct rewrite with `Scheme.Opens.ι_image_basicOpen` and `Scheme.basicOpen_res_eq` Extracted from #38415 [![Open in Gitpod](https://gitpod.io/button/open-in-gitpod.svg)](https://gitpod.io/from-referrer/)
1 parent d1fddb3 commit 405fef5

1 file changed

Lines changed: 3 additions & 17 deletions

File tree

Mathlib/AlgebraicGeometry/Restrict.lean

Lines changed: 3 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -529,13 +529,8 @@ theorem morphismRestrict_ι {X Y : Scheme.{u}} (f : X ⟶ Y) (U : Y.Opens) :
529529

530530
theorem isPullback_morphismRestrict {X Y : Scheme.{u}} (f : X ⟶ Y) (U : Y.Opens) :
531531
IsPullback (f ∣_ U) (f ⁻¹ᵁ U).ι U.ι f := by
532-
delta morphismRestrict
533-
rw [← Category.id_comp f]
534-
refine
535-
(IsPullback.of_horiz_isIso ⟨?_⟩).paste_horiz
536-
(IsPullback.of_hasPullback f (Y.ofRestrict U.isOpenEmbedding)).flip
537-
erw [pullbackRestrictIsoRestrict_inv_fst]
538-
rw [Category.comp_id]
532+
apply IsOpenImmersion.isPullback <;>
533+
simp
539534

540535
lemma isPullback_opens_inf_le {X : Scheme} {U V W : X.Opens} (hU : U ≤ W) (hV : V ≤ W) :
541536
IsPullback (X.homOfLE inf_le_left) (X.homOfLE inf_le_right) (X.homOfLE hU) (X.homOfLE hV) := by
@@ -661,16 +656,7 @@ def morphismRestrictRestrictBasicOpen {X Y : Scheme.{u}} (f : X ⟶ Y) (U : Y.Op
661656
U.toScheme.basicOpen (Y.presheaf.map (eqToHom U.isOpenEmbedding_obj_top).op r)) ≅
662657
Arrow.mk (f ∣_ Y.basicOpen r) := by
663658
refine morphismRestrictRestrict _ _ _ ≪≫ morphismRestrictEq _ ?_
664-
have e := Scheme.preimage_basicOpen U.ι r
665-
rw [Scheme.Opens.ι_app] at e
666-
rw [← U.toScheme.basicOpen_res_eq _ (eqToHom U.inclusion'_map_eq_top).op]
667-
erw [← elementwise_of% Y.presheaf.map_comp]
668-
rw [eqToHom_op, eqToHom_op, eqToHom_map, eqToHom_trans]
669-
erw [← e]
670-
ext1
671-
dsimp [Opens.map_coe]
672-
rw [Set.image_preimage_eq_inter_range, Set.inter_eq_left, Scheme.Opens.range_ι]
673-
exact Y.basicOpen_le r
659+
simp [Scheme.Opens.ι_image_basicOpen]
674660

675661
set_option backward.isDefEq.respectTransparency false in
676662
/-- The stalk map of a restriction of a morphism is isomorphic to the stalk map of the original map.

0 commit comments

Comments
 (0)