This repository has been archived by the owner on Jul 24, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 298
[Merged by Bors] - feat(linear_algebra/trace): dual_tensor_hom is an equivalence + basis-free characterization of the trace #10372
Closed
Closed
Changes from 3 commits
Commits
Show all changes
43 commits
Select commit
Hold shift + click to select a range
da80c7e
feat(linear_algebra/trace): dual_tensor_hom is an equivalence + basis…
antoinelab01 eadcf9c
fixed typo
antoinelab01 8451a8b
Update src/linear_algebra/tensor_product_basis.lean
antoinelab01 082bf6c
Update src/linear_algebra/tensor_product_basis.lean
antoinelab01 bedb05e
Update src/linear_algebra/trace.lean
antoinelab01 6888028
added explicit inverse of dual_tensor_hom given a basis + minor changes
antoinelab01 7733e5a
removed field hypothesis from hom_dual_tensor
antoinelab01 34a1f82
minor changes
antoinelab01 1dc515d
Update src/linear_algebra/contraction.lean
antoinelab01 1bab109
.
antoinelab01 30bf95e
.
antoinelab01 3796b08
added lemma for sum of single
antoinelab01 2d0ca91
fixed line too long
antoinelab01 80b5403
second version of fintype_sum_single
antoinelab01 91a59c9
explicit equivalence given basis without field assumption
antoinelab01 2b7f981
Update src/linear_algebra/contraction.lean
antoinelab01 f879320
Update src/linear_algebra/contraction.lean
antoinelab01 97b7318
minor changes
antoinelab01 7a9be3d
Merge branch 'trace' of https://github.com/leanprover-community/mathl…
antoinelab01 521ab65
Update src/linear_algebra/contraction.lean
antoinelab01 f611861
Update src/linear_algebra/contraction.lean
antoinelab01 f5ce923
breaking some proofs into small lemmas
antoinelab01 a944d98
Add missing doc string and other minor tidy up
ocfnash ed5df7b
Update src/linear_algebra/contraction.lean
antoinelab01 15b9e1d
removed equiv lemmas
antoinelab01 7f5d67b
.
antoinelab01 59a0c0e
fixed conflicts
antoinelab01 e3195fd
fixed error in trace_eq_contract'
antoinelab01 e32e2de
fixed line too long
antoinelab01 3d09e9b
fixed linter issues
antoinelab01 eaa72d0
revert accidental modification of variables
antoinelab01 52951a5
generalized trace_eq_contract to free modules over commutative rings
antoinelab01 f21bfb9
fixed decidable_classical issues
antoinelab01 e2aaa88
integrated hom_dual_tensor in the equivalence
antoinelab01 f78dcab
modified single_one_smul
antoinelab01 966e88f
generalized the vector space statements to finite free modules
antoinelab01 f3654e5
removed trace_same
antoinelab01 ef1e848
Update src/linear_algebra/contraction.lean
antoinelab01 63cc7a6
Update src/linear_algebra/trace.lean
antoinelab01 86cadfc
Update src/linear_algebra/trace.lean
antoinelab01 7e6ea37
changed name to sum_univ_single
antoinelab01 ae0d84e
Merge branch 'master' into trace
ocfnash 126dd47
fix issue in representation_theory/basic
antoinelab01 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
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
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 | ||||
---|---|---|---|---|---|---|
@@ -1,9 +1,12 @@ | ||||||
/- | ||||||
Copyright (c) 2020 Oliver Nash. All rights reserved. | ||||||
Released under Apache 2.0 license as described in the file LICENSE. | ||||||
Authors: Oliver Nash | ||||||
Authors: Oliver Nash, Antoine Labelle | ||||||
-/ | ||||||
import linear_algebra.dual | ||||||
import linear_algebra.matrix.to_lin | ||||||
import linear_algebra.tensor_product_basis | ||||||
import linear_algebra.free_module.finite.rank | ||||||
|
||||||
/-! | ||||||
# Contractions | ||||||
|
@@ -21,8 +24,14 @@ universes u v | |||||
|
||||||
|
||||||
section contraction | ||||||
|
||||||
open tensor_product | ||||||
open linear_map | ||||||
open matrix | ||||||
open_locale tensor_product | ||||||
open_locale big_operators | ||||||
|
||||||
section | ||||||
|
||||||
variables (R : Type u) (M N : Type v) | ||||||
variables [comm_ring R] [add_comm_group M] [add_comm_group N] [module R M] [module R N] | ||||||
|
@@ -51,4 +60,45 @@ variables {R M N} | |||||
dual_tensor_hom R M N (f ⊗ₜ n) m = (f m) • n := | ||||||
by { dunfold dual_tensor_hom, rw uncurry_apply, refl, } | ||||||
|
||||||
/-- As a matrix, `dual_tensor_hom` evaluated on a basis element of `M* ⊗ N` is a matrix with a | ||||||
single one and zeros elsewhere -/ | ||||||
theorem dual_tensor_hom_basis | ||||||
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.
Suggested change
|
||||||
{m : Type*} {n : Type*} [fintype m] [fintype n] [decidable_eq m] [decidable_eq n] | ||||||
(bM : basis m R M) (bN : basis n R N) (j : m) (i : n) : | ||||||
to_matrix bM bN (dual_tensor_hom R M N (bM.coord j ⊗ₜ bN i)) = std_basis_matrix i j 1 := | ||||||
begin | ||||||
ext i' j', | ||||||
by_cases hij : (i = i' ∧ j = j'); | ||||||
simp [linear_map.to_matrix_apply, finsupp.single_eq_pi_single, hij], | ||||||
rw [and_iff_not_or_not, not_not] at hij, cases hij; simp [hij], | ||||||
end | ||||||
|
||||||
end | ||||||
|
||||||
open finite_dimensional | ||||||
variables (R : Type u) (M N : Type v) | ||||||
variables [field R] [add_comm_group M] [add_comm_group N] [module R M] [module R N] | ||||||
variables [finite_dimensional R M] | ||||||
|
||||||
theorem dual_tensor_hom_surj : function.surjective (dual_tensor_hom R M N) := | ||||||
begin | ||||||
intro f, | ||||||
have b := fin_basis R M, | ||||||
use ∑ (i : fin (finrank R M)), (b.dual_basis i) ⊗ₜ f (b i), | ||||||
ocfnash marked this conversation as resolved.
Show resolved
Hide resolved
|
||||||
ext m, simp, | ||||||
ocfnash marked this conversation as resolved.
Show resolved
Hide resolved
|
||||||
nth_rewrite_rhs 0 ←basis.sum_repr b m, simp, | ||||||
end | ||||||
|
||||||
variables [finite_dimensional R N] | ||||||
|
||||||
theorem dual_tensor_hom_inj : function.injective (dual_tensor_hom R M N) := | ||||||
(injective_iff_surjective_of_finrank_eq_finrank (by simp)).2 (dual_tensor_hom_surj R M N) | ||||||
|
||||||
noncomputable def dual_tensor_hom_equiv : (module.dual R M) ⊗[R] N ≃ₗ[R] M →ₗ[R] N := | ||||||
linear_equiv.of_bijective (dual_tensor_hom R M N) | ||||||
(dual_tensor_hom_inj R M N) (dual_tensor_hom_surj R M N) | ||||||
|
||||||
lemma dual_tensor_hom_equiv_to_lin (f : (module.dual R M) ⊗[R] N): | ||||||
ocfnash marked this conversation as resolved.
Show resolved
Hide resolved
|
||||||
(dual_tensor_hom_equiv R M N) f = (dual_tensor_hom R M N) f := rfl | ||||||
|
||||||
end contraction |
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
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.
Since the proof is
simp
, do you really need it? What happens if you remove it?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.
At any rate this lemma should include
std_basis_matrix
in its nameThere 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.
You're right, I don't really need it.