-
Notifications
You must be signed in to change notification settings - Fork 297
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(ring_theory/trace): Tr(x) is the sum of embeddings σ x into an algebraically closed field #8762
Closed
Closed
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
41c42fe
feat(field_theory/intermediate_field): generalize `algebra` instances
Vierkantor 232d8b9
Lint fix
Vierkantor af3ffa7
Fix the timeout by making some unifications fail fast
Vierkantor fdad3dd
Specialize `intermediate_field.is_scalar_tower_mid`
Vierkantor a32df1c
chore(ring_theory/power_basis): `@[simps]` `lift_equiv'`
Vierkantor f166b33
feat(field_theory): cardinality of `alg_hom`s out of a finite separab…
Vierkantor 2691f0b
Golf/speedup
Vierkantor 2fde8df
feat(ring_theory/trace): Tr(x) is the sum of embeddings σ x into an a…
Vierkantor 17ea68a
More elegant proof
Vierkantor 91372ec
Lint fix, by rearranging variables
Vierkantor 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
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
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
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
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 |
---|---|---|
|
@@ -6,9 +6,10 @@ Authors: Anne Baanen | |
|
||
import linear_algebra.bilinear_form | ||
import linear_algebra.char_poly.coeff | ||
import linear_algebra.determinant | ||
import linear_algebra.trace | ||
import field_theory.adjoin | ||
import field_theory.algebraic_closure | ||
import field_theory.primitive_element | ||
import ring_theory.power_basis | ||
|
||
/-! | ||
|
@@ -232,20 +233,29 @@ end | |
|
||
end intermediate_field.adjoin_simple | ||
|
||
lemma trace_eq_sum_roots [finite_dimensional K L] | ||
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.
|
||
{x : L} (hF : (minpoly K x).splits (algebra_map K F)) : | ||
algebra_map K F (algebra.trace K L x) = | ||
finrank K⟮x⟯ L • ((minpoly K x).map (algebra_map K _)).roots.sum := | ||
open intermediate_field | ||
|
||
variables (K) | ||
|
||
lemma trace_eq_trace_adjoin [finite_dimensional K L] (x : L) : | ||
algebra.trace K L x = finrank K⟮x⟯ L • trace K K⟮x⟯ (adjoin_simple.gen K x) := | ||
begin | ||
haveI : finite_dimensional K⟮x⟯ L := finite_dimensional.right K _ L, | ||
rw ← @trace_trace _ _ K K⟮x⟯ _ _ _ _ _ _ _ _ x, | ||
conv in x { rw ← intermediate_field.adjoin_simple.algebra_map_gen K x }, | ||
rw [trace_algebra_map, ← is_scalar_tower.algebra_map_smul K, (algebra.trace K K⟮x⟯).map_smul, | ||
smul_eq_mul, ring_hom.map_mul, ← is_scalar_tower.algebra_map_apply ℕ K _, ← smul_def, | ||
intermediate_field.adjoin_simple.trace_gen_eq_sum_roots _ hF], | ||
all_goals { apply_instance } | ||
smul_eq_mul, algebra.smul_def], | ||
apply_instance | ||
end | ||
|
||
variables {K} | ||
|
||
lemma trace_eq_sum_roots [finite_dimensional K L] | ||
{x : L} (hF : (minpoly K x).splits (algebra_map K F)) : | ||
algebra_map K F (algebra.trace K L x) = | ||
finrank K⟮x⟯ L • ((minpoly K x).map (algebra_map K _)).roots.sum := | ||
by rw [trace_eq_trace_adjoin K x, algebra.smul_def, ring_hom.map_mul, ← algebra.smul_def, | ||
intermediate_field.adjoin_simple.trace_gen_eq_sum_roots _ hF, is_scalar_tower.algebra_map_smul] | ||
|
||
end eq_sum_roots | ||
|
||
variables {F : Type*} [field F] | ||
|
@@ -268,3 +278,63 @@ begin | |
{ apply is_alg_closed.splits_codomain }, | ||
{ apply_instance } | ||
end | ||
|
||
section eq_sum_embeddings | ||
|
||
variables [algebra K F] [is_scalar_tower K L F] | ||
|
||
open algebra intermediate_field | ||
|
||
variables (F) (E : Type*) [field E] [algebra K E] | ||
|
||
lemma trace_eq_sum_embeddings_gen | ||
(pb : power_basis K L) | ||
(hE : (minpoly K pb.gen).splits (algebra_map K E)) (hfx : (minpoly K pb.gen).separable) : | ||
algebra_map K E (algebra.trace K L pb.gen) = | ||
(@@finset.univ (power_basis.alg_hom.fintype pb)).sum (λ σ, σ pb.gen) := | ||
begin | ||
letI := classical.dec_eq E, | ||
rw [pb.trace_gen_eq_sum_roots hE, fintype.sum_equiv pb.lift_equiv', finset.sum_mem_multiset, | ||
finset.sum_eq_multiset_sum, multiset.to_finset_val, | ||
multiset.erase_dup_eq_self.mpr (nodup_roots ((separable_map _).mpr hfx)), multiset.map_id], | ||
{ intro x, refl }, | ||
{ intro σ, rw [power_basis.lift_equiv'_apply_coe, id.def] } | ||
end | ||
|
||
variables [is_alg_closed E] | ||
|
||
lemma sum_embeddings_eq_finrank_mul [finite_dimensional K F] [is_separable K F] | ||
(pb : power_basis K L) : | ||
∑ σ : F →ₐ[K] E, σ (algebra_map L F pb.gen) = | ||
finrank L F • (@@finset.univ (power_basis.alg_hom.fintype pb)).sum | ||
(λ σ : L →ₐ[K] E, σ pb.gen) := | ||
begin | ||
haveI : finite_dimensional L F := finite_dimensional.right K L F, | ||
haveI : is_separable L F := is_separable_tower_top_of_is_separable K L F, | ||
letI : fintype (L →ₐ[K] E) := power_basis.alg_hom.fintype pb, | ||
letI : ∀ (f : L →ₐ[K] E), fintype (@@alg_hom L F E _ _ _ _ f.to_ring_hom.to_algebra) := | ||
_, -- will be solved by unification | ||
rw [fintype.sum_equiv alg_hom_equiv_sigma (λ (σ : F →ₐ[K] E), _) (λ σ, σ.1 pb.gen), | ||
← finset.univ_sigma_univ, finset.sum_sigma, ← finset.sum_nsmul], | ||
refine finset.sum_congr rfl (λ σ _, _), | ||
{ letI : algebra L E := σ.to_ring_hom.to_algebra, | ||
simp only [finset.sum_const, finset.card_univ], | ||
rw alg_hom.card L F E }, | ||
{ intros σ, | ||
simp only [alg_hom_equiv_sigma, equiv.coe_fn_mk, alg_hom.restrict_domain, alg_hom.comp_apply, | ||
is_scalar_tower.coe_to_alg_hom'] } | ||
end | ||
|
||
lemma trace_eq_sum_embeddings [finite_dimensional K L] [is_separable K L] | ||
{x : L} (hx : is_integral K x) : | ||
algebra_map K E (algebra.trace K L x) = ∑ σ : L →ₐ[K] E, σ x := | ||
begin | ||
rw [trace_eq_trace_adjoin K x, algebra.smul_def, ring_hom.map_mul, ← adjoin.power_basis_gen hx, | ||
trace_eq_sum_embeddings_gen E (adjoin.power_basis hx) (is_alg_closed.splits_codomain _), | ||
← algebra.smul_def, algebra_map_smul], | ||
{ exact (sum_embeddings_eq_finrank_mul L E (adjoin.power_basis hx)).symm }, | ||
{ haveI := is_separable_tower_bot_of_is_separable K K⟮x⟯ L, | ||
exact is_separable.separable K _ } | ||
end | ||
|
||
end eq_sum_embeddings |
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.
Not only is this slightly shorter, it runs noticeably faster which was useful when messing around with some instances. (See also #8761.)