Skip to content
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] - feat: topology on module over topological ring #16895

Closed
wants to merge 32 commits into from

Conversation

kbuzzard
Copy link
Member

@kbuzzard kbuzzard commented Sep 17, 2024

Given a module over a topological ring, we define the module topology on this module to be the finest module making it into a topological module (i.e. the finest topology making addition and scalar multiplication continuous).

NB this PR gave rise to a discussion about whether ⨆ a ∈ s, f a or sSup (f '' s) should be the simp normal form, which was discussed on Zulip without any clear conclusion.


Open in Gitpod

I wanted this because for a finite free module it can be checked to be the product topology, and for an algebra over a commutative topological ring which is finite as a module, multiplication in the algebra is automatically continuous with this topology. I have all of these results in the FLT repo in this file. What inspired me to PR it to mathlib was Yael's question here -- this topology gives a very nice answer to that question.

Copy link

github-actions bot commented Sep 17, 2024

PR summary ef2b10cd79

Import changes for modified files

Dependency changes

File Base Count Head Count Change
Mathlib.Topology.Algebra.Module.Basic 1030 1032 +2 (+0.19%)
Import changes for all files
Files Import difference
15 files Mathlib.Topology.Algebra.InfiniteSum.Module Mathlib.LinearAlgebra.AffineSpace.ContinuousAffineEquiv Mathlib.Topology.Algebra.Module.Multilinear.Basic Mathlib.Topology.Algebra.UniformFilterBasis Mathlib.Topology.Algebra.Nonarchimedean.Bases Mathlib.Topology.Algebra.Module.LinearPMap Mathlib.Topology.Algebra.FilterBasis Mathlib.Topology.Algebra.Module.Basic Mathlib.Topology.Instances.RealVectorSpace Mathlib.Topology.Algebra.Module.WeakDual Mathlib.Topology.Algebra.Module.Alternating.Basic Mathlib.Topology.Algebra.ContinuousAffineMap Mathlib.Topology.Instances.TrivSqZeroExt Mathlib.Topology.Algebra.Module.Star Mathlib.Analysis.Convex.Exposed
2
Mathlib.Topology.Algebra.Module.ModuleTopology 1033

Declarations diff

+ IsModuleTopology
+ IsModuleTopology.toContinuousAdd
+ IsModuleTopology.toContinuousSMul
+ ModuleTopology.continuousAdd
+ ModuleTopology.continuousSMul
+ coinduced_sSup
+ eq_moduleTopology
+ induced_sInf
+ instSubsingleton
+ instance _root_.TopologicalSemiring.toIsModuleTopology : IsModuleTopology R R := by
+ instance _root_.TopologicalSemiring.toOppositeIsModuleTopology : IsModuleTopology Rᵐᵒᵖ R
+ iso
+ moduleTopology
+ moduleTopology_le
+ of_continuous_id
+ opContinuousLinearEquiv

You can run this locally as follows
## summary with just the declaration names:
./scripts/declarations_diff.sh <optional_commit>

## more verbose report:
./scripts/declarations_diff.sh long <optional_commit>

The doc-module for script/declarations_diff.sh contains some details about this script.

@kbuzzard kbuzzard added t-algebra Algebra (groups, rings, fields, etc) FLT part of the ongoing formalization of Fermat's Last Theorem labels Sep 17, 2024
Mathlib/Topology/Algebra/Module/Action.lean Outdated Show resolved Hide resolved
Mathlib/Topology/Algebra/Module/Action.lean Outdated Show resolved Hide resolved
Mathlib/Topology/Algebra/Module/Action.lean Outdated Show resolved Hide resolved
Mathlib/Topology/Algebra/Module/Action.lean Outdated Show resolved Hide resolved
Mathlib/Topology/Algebra/Module/Action.lean Outdated Show resolved Hide resolved
Mathlib/Topology/Order.lean Outdated Show resolved Hide resolved
Copy link
Member

@eric-wieser eric-wieser left a comment

Choose a reason for hiding this comment

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

bors d+

Thanks! I pushed two small golfs, feel free to merge before CI if they look fine to you. (I did test them)

Comment on lines 129 to 136
/- Proof: We need to prove that the product topology is finer than the pullback
of the module topology. But the module topology is an Inf and thus a limit,
and pullback is a right adjoint, so it preserves limits.
We must thus show that the product topology is finer than an Inf, so it suffices
to show it's a lower bound, which is not hard. All this is wrapped into
`continuousSMul_sInf`.
-/
continuousSMul_sInf <| fun _ _ ↦ by simp_all only [Set.mem_setOf_eq]
Copy link
Member

Choose a reason for hiding this comment

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

This is a long comment for a very small amount of proof!

Copy link
Member Author

@kbuzzard kbuzzard Oct 19, 2024

Choose a reason for hiding this comment

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

Yes, and in my opinion more of mathlib should look like this! The proof of continuousSMul_sInf is slightly subtle I think. The comment explains the conceptual reason why it's true.

@mathlib-bors
Copy link
Contributor

mathlib-bors bot commented Oct 19, 2024

✌️ kbuzzard can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.

@kbuzzard
Copy link
Member Author

Thanks! I pushed two small golfs, feel free to merge before CI if they look fine to you. (I did test them)

They book look great to me! Thanks!

@kbuzzard
Copy link
Member Author

bors r+

@github-actions github-actions bot added the ready-to-merge This PR has been sent to bors. label Oct 19, 2024
mathlib-bors bot pushed a commit that referenced this pull request Oct 19, 2024
Given a module over a topological ring, we define the module topology on this module to be the finest module making it into a topological module (i.e. the finest topology making addition and scalar multiplication continuous).

NB this PR gave rise to a discussion about whether `⨆ a ∈ s, f a` or `sSup (f '' s)` should be the simp normal form, which was discussed on [Zulip](https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/normal.20form.20for.20pullback.20of.20Inf.20of.20topologies/near/472676441) without any clear conclusion.



Co-authored-by: Eric Wieser <[email protected]>
@mathlib-bors
Copy link
Contributor

mathlib-bors bot commented Oct 19, 2024

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title feat: topology on module over topological ring [Merged by Bors] - feat: topology on module over topological ring Oct 19, 2024
@mathlib-bors mathlib-bors bot closed this Oct 19, 2024
@mathlib-bors mathlib-bors bot deleted the kbuzzard-action-topology branch October 19, 2024 21:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
delegated FLT part of the ongoing formalization of Fermat's Last Theorem ready-to-merge This PR has been sent to bors. t-algebra Algebra (groups, rings, fields, etc)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants