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(algebra/direct_sum/module) : coe and internal #10004
Closed
Closed
Changes from 4 commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
75d5123
feat(algebra/direct_sum/module) : coe and internal
777935e
add simp lemma and submonoid version
bfd84ad
Update src/algebra/direct_sum/module.lean
jjaassoonn c60076f
remove unnecessary `direct_sum.`
dc364a5
more `simp` lemma
984c117
Update src/algebra/direct_sum/basic.lean
jjaassoonn 441e257
Update module.lean
jjaassoonn c5f3a2b
Update src/algebra/direct_sum/basic.lean
jjaassoonn c838083
Update src/algebra/direct_sum/module.lean
jjaassoonn d12ca81
Update src/algebra/direct_sum/basic.lean
jjaassoonn 3456d8c
apply suggestions @jcommelin
81a75ab
remove unnecessary direct_sum.
File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -172,13 +172,18 @@ protected def id (M : Type v) (ι : Type* := punit) [add_comm_monoid M] [unique | |
right_inv := λ x, to_add_monoid_of _ _ _, | ||
..direct_sum.to_add_monoid (λ _, add_monoid_hom.id M) } | ||
|
||
/-- The canonical embedding from `⨁ i, A i` to `M`-/ | ||
def add_submonoid_coe {M : Type*} [decidable_eq ι] [add_comm_monoid M] | ||
(A : ι → add_submonoid M) : (⨁ i, A i) →+ M := | ||
direct_sum.to_add_monoid (λ i, (A i).subtype) | ||
|
||
/-- The `direct_sum` formed by a collection of `add_submonoid`s of `M` is said to be internal if the | ||
canonical map `(⨁ i, A i) →+ M` is bijective. | ||
|
||
See `direct_sum.add_subgroup_is_internal` for the same statement about `add_subgroup`s. -/ | ||
def add_submonoid_is_internal {M : Type*} [decidable_eq ι] [add_comm_monoid M] | ||
(A : ι → add_submonoid M) : Prop := | ||
function.bijective (direct_sum.to_add_monoid (λ i, (A i).subtype) : (⨁ i, A i) →+ M) | ||
function.bijective (direct_sum.add_submonoid_coe A) | ||
|
||
lemma add_submonoid_is_internal.supr_eq_top {M : Type*} [decidable_eq ι] [add_comm_monoid M] | ||
(A : ι → add_submonoid M) | ||
|
@@ -188,13 +193,26 @@ begin | |
exact function.bijective.surjective h, | ||
end | ||
|
||
/-- The canonical embedding from `⨁ i, A i` to `M`-/ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Idem. |
||
def add_subgroup_coe {M : Type*} [decidable_eq ι] [add_comm_group M] | ||
(A : ι → add_subgroup M) : (⨁ i, A i) →+ M := | ||
direct_sum.to_add_monoid (λ i, (A i).subtype) | ||
|
||
@[simp] lemma add_group_coe_of {M : Type*} [decidable_eq ι] [add_comm_group M] | ||
jjaassoonn marked this conversation as resolved.
Show resolved
Hide resolved
|
||
(A : ι → add_subgroup M) (i : ι) (x : A i) : | ||
direct_sum.add_subgroup_coe A (direct_sum.of (λ i, A i) i x) = x := | ||
jjaassoonn marked this conversation as resolved.
Show resolved
Hide resolved
|
||
begin | ||
eric-wieser marked this conversation as resolved.
Show resolved
Hide resolved
|
||
rw [direct_sum.add_subgroup_coe, direct_sum.to_add_monoid_of], | ||
simp only [add_subgroup.coe_subtype], | ||
end | ||
|
||
/-- The `direct_sum` formed by a collection of `add_subgroup`s of `M` is said to be internal if the | ||
canonical map `(⨁ i, A i) →+ M` is bijective. | ||
|
||
See `direct_sum.submodule_is_internal` for the same statement about `submodules`s. -/ | ||
def add_subgroup_is_internal {M : Type*} [decidable_eq ι] [add_comm_group M] | ||
(A : ι → add_subgroup M) : Prop := | ||
function.bijective (direct_sum.to_add_monoid (λ i, (A i).subtype) : (⨁ i, A i) →+ M) | ||
function.bijective (direct_sum.add_subgroup_coe A) | ||
|
||
lemma add_subgroup_is_internal.to_add_submonoid | ||
{M : Type*} [decidable_eq ι] [add_comm_group M] (A : ι → add_subgroup M) : | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
I think that this docstring should mention that the
A i
are submonoids ofM
.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.
Thank you for the suggestion