-
Notifications
You must be signed in to change notification settings - Fork 381
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Merged by Bors] - refactor(AlgebraicGeometry): Rework Morphisms/Basic
to phase away from TFAEs
#14430
Conversation
…lib4 into erd1/morphismRework
PR summary a67d97bfc5Import changes for modified filesNo significant changes to the import graph Import changes for all files
|
…ypeclass' into erd1/morphismRework
…lib4 into erd1/morphismRework
I think I have addressed all the comments. Thanks for the swift review! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As I said earlier, I really like this change.
theorem QuasiCompact.affine_openCover_iff {X Y : Scheme.{u}} (𝒰 : Scheme.OpenCover.{u} Y) | ||
[∀ i, IsAffine (𝒰.obj i)] (f : X ⟶ Y) : | ||
QuasiCompact f ↔ ∀ i, CompactSpace (pullback f (𝒰.map i) : _) := | ||
quasiCompact_eq_affineProperty.symm ▸ QuasiCompact.affineProperty_isLocal.affine_openCover_iff f 𝒰 | ||
#align algebraic_geometry.quasi_compact.affine_open_cover_iff AlgebraicGeometry.QuasiCompact.affine_openCover_iff | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What did come out of this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks a lot!
Thanks for the swift review! |
!bench |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks 🎉
bors merge
…rom TFAEs (#14430) Previously the contents of `Morphism/Baisic` were all implementation detail that needed to be copied over to each new morphism class. In this PR we clean up the file and promote it into a proper interface of the API. We also phase away from TFAEs in favor of easier to use iff lemmas. We introduce the following two interfaces: ## `IsLocalAtTarget` - `AlgebraicGeometry.IsLocalAtTarget`: We say that `IsLocalAtTarget P` for `P : MorphismProperty Scheme` if 1. `P` respects isomorphisms. 2. If `P` holds for `f : X ⟶ Y`, then `P` holds for `f ∣_ U` for any open `U` of `Y`. 3. If `P` holds for `f ∣_ U` for an open cover `U` of `Y`, then `P` holds for `f`. For a morphism property `P` local at the target and `f : X ⟶ Y`, we provide these API lemmas: - `AlgebraicGeometry.IsLocalAtTarget.of_isPullback`: `P` is preserved under pullback along open immersions. - `AlgebraicGeometry.IsLocalAtTarget.restrict`: `P f → P (f ∣_ U)` for an open `U` of `Y`. - `AlgebraicGeometry.IsLocalAtTarget.iff_of_iSup_eq_top`: `P f ↔ ∀ i, P (f ∣_ U i)` for a family `U i` of open sets covering `Y`. - `AlgebraicGeometry.IsLocalAtTarget.iff_of_openCover`: `P f ↔ ∀ i, P (𝒰.pullbackHom f i)` for `𝒰 : Y.openCover`. ## `HasAffineProperty` - `AlgebraicGeometry.HasAffineProperty`: `HasAffineProperty P Q` is a type class asserting that `P` is local at the target, and over affine schemes, it is equivalent to `Q : AffineTargetMorphismProperty`. For `HasAffineProperty P Q` and `f : X ⟶ Y`, we provide these API lemmas: - `AlgebraicGeometry.HasAffineProperty.of_isPullback`: `P` is preserved under pullback along open immersions from affine schemes. - `AlgebraicGeometry.HasAffineProperty.restrict`: `P f → Q (f ∣_ U)` for affine `U` of `Y`. - `AlgebraicGeometry.HasAffineProperty.iff_of_iSup_eq_top`: `P f ↔ ∀ i, Q (f ∣_ U i)` for a family `U i` of affine open sets covering `Y`. - `AlgebraicGeometry.HasAffineProperty.iff_of_openCover`: `P f ↔ ∀ i, P (𝒰.pullbackHom f i)` for affine open covers `𝒰` of `Y`. - `AlgebraicGeometry.HasAffineProperty.stableUnderBaseChange_mk`: If `Q` is stable under affine base change, then `P` is stable under arbitrary base change. Co-authored-by: Andrew Yang <[email protected]> Co-authored-by: Joël Riou <[email protected]>
Let's wait for the benchmarking to finish. AG is a finicky area currently. bors r- |
Canceled. |
Here are the benchmark results for commit a67d97b. Benchmark Metric Change
=============================================================
- ~Mathlib.AlgebraicGeometry.Cover.Open instructions 31.8% |
Seems minor. I will see if I can track that down later. bors merge |
…rom TFAEs (#14430) Previously the contents of `Morphism/Baisic` were all implementation detail that needed to be copied over to each new morphism class. In this PR we clean up the file and promote it into a proper interface of the API. We also phase away from TFAEs in favor of easier to use iff lemmas. We introduce the following two interfaces: ## `IsLocalAtTarget` - `AlgebraicGeometry.IsLocalAtTarget`: We say that `IsLocalAtTarget P` for `P : MorphismProperty Scheme` if 1. `P` respects isomorphisms. 2. If `P` holds for `f : X ⟶ Y`, then `P` holds for `f ∣_ U` for any open `U` of `Y`. 3. If `P` holds for `f ∣_ U` for an open cover `U` of `Y`, then `P` holds for `f`. For a morphism property `P` local at the target and `f : X ⟶ Y`, we provide these API lemmas: - `AlgebraicGeometry.IsLocalAtTarget.of_isPullback`: `P` is preserved under pullback along open immersions. - `AlgebraicGeometry.IsLocalAtTarget.restrict`: `P f → P (f ∣_ U)` for an open `U` of `Y`. - `AlgebraicGeometry.IsLocalAtTarget.iff_of_iSup_eq_top`: `P f ↔ ∀ i, P (f ∣_ U i)` for a family `U i` of open sets covering `Y`. - `AlgebraicGeometry.IsLocalAtTarget.iff_of_openCover`: `P f ↔ ∀ i, P (𝒰.pullbackHom f i)` for `𝒰 : Y.openCover`. ## `HasAffineProperty` - `AlgebraicGeometry.HasAffineProperty`: `HasAffineProperty P Q` is a type class asserting that `P` is local at the target, and over affine schemes, it is equivalent to `Q : AffineTargetMorphismProperty`. For `HasAffineProperty P Q` and `f : X ⟶ Y`, we provide these API lemmas: - `AlgebraicGeometry.HasAffineProperty.of_isPullback`: `P` is preserved under pullback along open immersions from affine schemes. - `AlgebraicGeometry.HasAffineProperty.restrict`: `P f → Q (f ∣_ U)` for affine `U` of `Y`. - `AlgebraicGeometry.HasAffineProperty.iff_of_iSup_eq_top`: `P f ↔ ∀ i, Q (f ∣_ U i)` for a family `U i` of affine open sets covering `Y`. - `AlgebraicGeometry.HasAffineProperty.iff_of_openCover`: `P f ↔ ∀ i, P (𝒰.pullbackHom f i)` for affine open covers `𝒰` of `Y`. - `AlgebraicGeometry.HasAffineProperty.stableUnderBaseChange_mk`: If `Q` is stable under affine base change, then `P` is stable under arbitrary base change. Co-authored-by: Andrew Yang <[email protected]> Co-authored-by: Joël Riou <[email protected]>
Pull request successfully merged into master. Build succeeded: |
Morphisms/Basic
to phase away from TFAEsMorphisms/Basic
to phase away from TFAEs
Previously the contents of
Morphism/Basic
were all implementation detail that needed to be copied over to each new morphism class. In this PR we clean up the file and promote it into a proper interface of the API. We also phase away from TFAEs in favor of easier to use iff lemmas. We introduce the following two interfaces:IsLocalAtTarget
AlgebraicGeometry.IsLocalAtTarget
: We say thatIsLocalAtTarget P
forP : MorphismProperty Scheme
ifP
respects isomorphisms.P
holds forf : X ⟶ Y
, thenP
holds forf ∣_ U
for any openU
ofY
.P
holds forf ∣_ U
for an open coverU
ofY
, thenP
holds forf
.For a morphism property
P
local at the target andf : X ⟶ Y
, we provide these API lemmas:AlgebraicGeometry.IsLocalAtTarget.of_isPullback
:P
is preserved under pullback along open immersions.AlgebraicGeometry.IsLocalAtTarget.restrict
:P f → P (f ∣_ U)
for an openU
ofY
.AlgebraicGeometry.IsLocalAtTarget.iff_of_iSup_eq_top
:P f ↔ ∀ i, P (f ∣_ U i)
for a familyU i
of open sets coveringY
.AlgebraicGeometry.IsLocalAtTarget.iff_of_openCover
:P f ↔ ∀ i, P (𝒰.pullbackHom f i)
for𝒰 : Y.openCover
.HasAffineProperty
AlgebraicGeometry.HasAffineProperty
:HasAffineProperty P Q
is a type class asserting thatP
is local at the target,and over affine schemes, it is equivalent to
Q : AffineTargetMorphismProperty
.For
HasAffineProperty P Q
andf : X ⟶ Y
, we provide these API lemmas:AlgebraicGeometry.HasAffineProperty.of_isPullback
:P
is preserved under pullback along open immersions from affine schemes.AlgebraicGeometry.HasAffineProperty.restrict
:P f → Q (f ∣_ U)
for affineU
ofY
.AlgebraicGeometry.HasAffineProperty.iff_of_iSup_eq_top
:P f ↔ ∀ i, Q (f ∣_ U i)
for a familyU i
of affine open sets coveringY
.AlgebraicGeometry.HasAffineProperty.iff_of_openCover
:P f ↔ ∀ i, P (𝒰.pullbackHom f i)
for affine open covers𝒰
ofY
.AlgebraicGeometry.HasAffineProperty.stableUnderBaseChange_mk
:If
Q
is stable under affine base change, thenP
is stable under arbitrary base change.