ring_theory.is_adjoin_root
⟷
Mathlib.RingTheory.IsAdjoinRoot
The following section lists changes to this file in mathlib3 and mathlib4 that occured after the initial port. Most recent changes are shown first. Hovering over a commit will show all commits associated with the same mathlib3 commit.
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(last sync)
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -3,7 +3,7 @@ Copyright (c) 2022 Anne Baanen. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen
-/
-import Data.Polynomial.AlgebraMap
+import Algebra.Polynomial.AlgebraMap
import FieldTheory.Minpoly.IsIntegrallyClosed
import RingTheory.PowerBasis
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -241,7 +241,7 @@ variable {T : Type _} [CommRing T] {i : R →+* T} {x : T} (hx : f.eval₂ i x =
theorem eval₂_repr_eq_eval₂_of_map_eq (h : IsAdjoinRoot S f) (z : S) (w : R[X])
(hzw : h.map w = z) : (h.repr z).eval₂ i x = w.eval₂ i x :=
by
- rw [eq_comm, ← sub_eq_zero, ← h.map_repr z, ← map_sub, h.map_eq_zero_iff] at hzw
+ rw [eq_comm, ← sub_eq_zero, ← h.map_repr z, ← map_sub, h.map_eq_zero_iff] at hzw
obtain ⟨y, hy⟩ := hzw
rw [← sub_eq_zero, ← eval₂_sub, hy, eval₂_mul, hx, MulZeroClass.zero_mul]
#align is_adjoin_root.eval₂_repr_eq_eval₂_of_map_eq IsAdjoinRoot.eval₂_repr_eq_eval₂_of_map_eq
mathlib commit https://github.com/leanprover-community/mathlib/commit/ce64cd319bb6b3e82f31c2d38e79080d377be451
@@ -3,9 +3,9 @@ Copyright (c) 2022 Anne Baanen. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen
-/
-import Mathbin.Data.Polynomial.AlgebraMap
-import Mathbin.FieldTheory.Minpoly.IsIntegrallyClosed
-import Mathbin.RingTheory.PowerBasis
+import Data.Polynomial.AlgebraMap
+import FieldTheory.Minpoly.IsIntegrallyClosed
+import RingTheory.PowerBasis
#align_import ring_theory.is_adjoin_root from "leanprover-community/mathlib"@"f2ad3645af9effcdb587637dc28a6074edc813f9"
mathlib commit https://github.com/leanprover-community/mathlib/commit/8ea5598db6caeddde6cb734aa179cc2408dbd345
@@ -2,16 +2,13 @@
Copyright (c) 2022 Anne Baanen. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen
-
-! This file was ported from Lean 3 source module ring_theory.is_adjoin_root
-! leanprover-community/mathlib commit f2ad3645af9effcdb587637dc28a6074edc813f9
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathbin.Data.Polynomial.AlgebraMap
import Mathbin.FieldTheory.Minpoly.IsIntegrallyClosed
import Mathbin.RingTheory.PowerBasis
+#align_import ring_theory.is_adjoin_root from "leanprover-community/mathlib"@"f2ad3645af9effcdb587637dc28a6074edc813f9"
+
/-!
# A predicate on adjoining roots of polynomial
mathlib commit https://github.com/leanprover-community/mathlib/commit/d30d31261cdb4d2f5e612eabc3c4bf45556350d5
@@ -918,7 +918,7 @@ open AdjoinRoot IsAdjoinRoot minpoly PowerBasis IsAdjoinRootMonic Algebra
#print Algebra.adjoin.powerBasis'_minpoly_gen /-
theorem Algebra.adjoin.powerBasis'_minpoly_gen [IsDomain R] [IsDomain S] [NoZeroSMulDivisors R S]
[IsIntegrallyClosed R] {x : S} (hx' : IsIntegral R x) :
- minpoly R x = minpoly R (minpoly.Algebra.adjoin.powerBasis' hx').gen :=
+ minpoly R x = minpoly R (Algebra.adjoin.powerBasis' hx').gen :=
by
haveI := is_domain_of_prime (prime_of_is_integrally_closed hx')
haveI :=
mathlib commit https://github.com/leanprover-community/mathlib/commit/f2ad3645af9effcdb587637dc28a6074edc813f9
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen
! This file was ported from Lean 3 source module ring_theory.is_adjoin_root
-! leanprover-community/mathlib commit f7fc89d5d5ff1db2d1242c7bb0e9062ce47ef47c
+! leanprover-community/mathlib commit f2ad3645af9effcdb587637dc28a6074edc813f9
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
@@ -15,6 +15,9 @@ import Mathbin.RingTheory.PowerBasis
/-!
# A predicate on adjoining roots of polynomial
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
+
This file defines a predicate `is_adjoin_root S f`, which states that the ring `S` can be
constructed by adjoining a specified root of the polynomial `f : R[X]` to `R`.
This predicate is useful when the same ring can be generated by adjoining the root of different
mathlib commit https://github.com/leanprover-community/mathlib/commit/2a0ce625dbb0ffbc7d1316597de0b25c1ec75303
@@ -74,6 +74,7 @@ section MoveMe
end MoveMe
+#print IsAdjoinRoot /-
-- This class doesn't really make sense on a predicate
/-- `is_adjoin_root S f` states that the ring `S` can be constructed by adjoining a specified root
of the polynomial `f : R[X]` to `R`.
@@ -92,7 +93,9 @@ structure IsAdjoinRoot {R : Type u} (S : Type v) [CommSemiring R] [Semiring S] [
ker_map : RingHom.ker map = Ideal.span {f}
algebraMap_eq : algebraMap R S = map.comp Polynomial.C
#align is_adjoin_root IsAdjoinRoot
+-/
+#print IsAdjoinRootMonic /-
-- This class doesn't really make sense on a predicate
/-- `is_adjoin_root_monic S f` states that the ring `S` can be constructed by adjoining a specified
root of the monic polynomial `f : R[X]` to `R`.
@@ -109,6 +112,7 @@ structure IsAdjoinRootMonic {R : Type u} (S : Type v) [CommSemiring R] [Semiring
(f : R[X]) extends IsAdjoinRoot S f where
Monic : Monic f
#align is_adjoin_root_monic IsAdjoinRootMonic
+-/
section Ring
@@ -116,38 +120,53 @@ variable {R : Type u} {S : Type v} [CommRing R] [Ring S] {f : R[X]} [Algebra R S
namespace IsAdjoinRoot
+#print IsAdjoinRoot.root /-
/-- `(h : is_adjoin_root S f).root` is the root of `f` that can be adjoined to generate `S`. -/
def root (h : IsAdjoinRoot S f) : S :=
h.map X
#align is_adjoin_root.root IsAdjoinRoot.root
+-/
+#print IsAdjoinRoot.subsingleton /-
theorem subsingleton (h : IsAdjoinRoot S f) [Subsingleton R] : Subsingleton S :=
h.map_surjective.Subsingleton
#align is_adjoin_root.subsingleton IsAdjoinRoot.subsingleton
+-/
+#print IsAdjoinRoot.algebraMap_apply /-
theorem algebraMap_apply (h : IsAdjoinRoot S f) (x : R) :
algebraMap R S x = h.map (Polynomial.C x) := by rw [h.algebra_map_eq, RingHom.comp_apply]
#align is_adjoin_root.algebra_map_apply IsAdjoinRoot.algebraMap_apply
+-/
+#print IsAdjoinRoot.mem_ker_map /-
@[simp]
theorem mem_ker_map (h : IsAdjoinRoot S f) {p} : p ∈ RingHom.ker h.map ↔ f ∣ p := by
rw [h.ker_map, Ideal.mem_span_singleton]
#align is_adjoin_root.mem_ker_map IsAdjoinRoot.mem_ker_map
+-/
+#print IsAdjoinRoot.map_eq_zero_iff /-
theorem map_eq_zero_iff (h : IsAdjoinRoot S f) {p} : h.map p = 0 ↔ f ∣ p := by
rw [← h.mem_ker_map, RingHom.mem_ker]
#align is_adjoin_root.map_eq_zero_iff IsAdjoinRoot.map_eq_zero_iff
+-/
+#print IsAdjoinRoot.map_X /-
@[simp]
-theorem map_x (h : IsAdjoinRoot S f) : h.map X = h.root :=
+theorem map_X (h : IsAdjoinRoot S f) : h.map X = h.root :=
rfl
-#align is_adjoin_root.map_X IsAdjoinRoot.map_x
+#align is_adjoin_root.map_X IsAdjoinRoot.map_X
+-/
+#print IsAdjoinRoot.map_self /-
@[simp]
theorem map_self (h : IsAdjoinRoot S f) : h.map f = 0 :=
h.map_eq_zero_iff.mpr dvd_rfl
#align is_adjoin_root.map_self IsAdjoinRoot.map_self
+-/
+#print IsAdjoinRoot.aeval_eq /-
@[simp]
theorem aeval_eq (h : IsAdjoinRoot S f) (p : R[X]) : aeval h.root p = h.map p :=
Polynomial.induction_on p (fun x => by rw [aeval_C, h.algebra_map_apply])
@@ -155,11 +174,15 @@ theorem aeval_eq (h : IsAdjoinRoot S f) (p : R[X]) : aeval h.root p = h.map p :=
rw [AlgHom.map_mul, aeval_C, AlgHom.map_pow, aeval_X, RingHom.map_mul, ← h.algebra_map_apply,
RingHom.map_pow, map_X]
#align is_adjoin_root.aeval_eq IsAdjoinRoot.aeval_eq
+-/
+#print IsAdjoinRoot.aeval_root /-
@[simp]
theorem aeval_root (h : IsAdjoinRoot S f) : aeval h.root f = 0 := by rw [aeval_eq, map_self]
#align is_adjoin_root.aeval_root IsAdjoinRoot.aeval_root
+-/
+#print IsAdjoinRoot.repr /-
/-- Choose an arbitrary representative so that `h.map (h.repr x) = x`.
If `f` is monic, use `is_adjoin_root_monic.mod_by_monic_hom` for a unique choice of representative.
@@ -167,22 +190,30 @@ If `f` is monic, use `is_adjoin_root_monic.mod_by_monic_hom` for a unique choice
def repr (h : IsAdjoinRoot S f) (x : S) : R[X] :=
(h.map_surjective x).some
#align is_adjoin_root.repr IsAdjoinRoot.repr
+-/
+#print IsAdjoinRoot.map_repr /-
theorem map_repr (h : IsAdjoinRoot S f) (x : S) : h.map (h.repr x) = x :=
(h.map_surjective x).choose_spec
#align is_adjoin_root.map_repr IsAdjoinRoot.map_repr
+-/
+#print IsAdjoinRoot.repr_zero_mem_span /-
/-- `repr` preserves zero, up to multiples of `f` -/
theorem repr_zero_mem_span (h : IsAdjoinRoot S f) : h.repr 0 ∈ Ideal.span ({f} : Set R[X]) := by
rw [← h.ker_map, RingHom.mem_ker, h.map_repr]
#align is_adjoin_root.repr_zero_mem_span IsAdjoinRoot.repr_zero_mem_span
+-/
+#print IsAdjoinRoot.repr_add_sub_repr_add_repr_mem_span /-
/-- `repr` preserves addition, up to multiples of `f` -/
theorem repr_add_sub_repr_add_repr_mem_span (h : IsAdjoinRoot S f) (x y : S) :
h.repr (x + y) - (h.repr x + h.repr y) ∈ Ideal.span ({f} : Set R[X]) := by
rw [← h.ker_map, RingHom.mem_ker, map_sub, h.map_repr, map_add, h.map_repr, h.map_repr, sub_self]
#align is_adjoin_root.repr_add_sub_repr_add_repr_mem_span IsAdjoinRoot.repr_add_sub_repr_add_repr_mem_span
+-/
+#print IsAdjoinRoot.ext_map /-
/-- Extensionality of the `is_adjoin_root` structure itself. See `is_adjoin_root_monic.ext_elem`
for extensionality of the ring elements. -/
theorem ext_map (h h' : IsAdjoinRoot S f) (eq : ∀ x, h.map x = h'.map x) : h = h' :=
@@ -190,18 +221,22 @@ theorem ext_map (h h' : IsAdjoinRoot S f) (eq : ∀ x, h.map x = h'.map x) : h =
cases h; cases h'; congr
exact RingHom.ext Eq
#align is_adjoin_root.ext_map IsAdjoinRoot.ext_map
+-/
+#print IsAdjoinRoot.ext /-
/-- Extensionality of the `is_adjoin_root` structure itself. See `is_adjoin_root_monic.ext_elem`
for extensionality of the ring elements. -/
@[ext]
theorem ext (h h' : IsAdjoinRoot S f) (eq : h.root = h'.root) : h = h' :=
h.ext_map h' fun x => by rw [← h.aeval_eq, ← h'.aeval_eq, Eq]
#align is_adjoin_root.ext IsAdjoinRoot.ext
+-/
section lift
variable {T : Type _} [CommRing T] {i : R →+* T} {x : T} (hx : f.eval₂ i x = 0)
+#print IsAdjoinRoot.eval₂_repr_eq_eval₂_of_map_eq /-
/-- Auxiliary lemma for `is_adjoin_root.lift` -/
theorem eval₂_repr_eq_eval₂_of_map_eq (h : IsAdjoinRoot S f) (z : S) (w : R[X])
(hzw : h.map w = z) : (h.repr z).eval₂ i x = w.eval₂ i x :=
@@ -210,9 +245,11 @@ theorem eval₂_repr_eq_eval₂_of_map_eq (h : IsAdjoinRoot S f) (z : S) (w : R[
obtain ⟨y, hy⟩ := hzw
rw [← sub_eq_zero, ← eval₂_sub, hy, eval₂_mul, hx, MulZeroClass.zero_mul]
#align is_adjoin_root.eval₂_repr_eq_eval₂_of_map_eq IsAdjoinRoot.eval₂_repr_eq_eval₂_of_map_eq
+-/
variable (i x)
+#print IsAdjoinRoot.lift /-
-- To match `adjoin_root.lift`
/-- Lift a ring homomorphism `R →+* T` to `S →+* T` by specifying a root `x` of `f` in `T`,
where `S` is given by adjoining a root of `f` to `R`. -/
@@ -230,24 +267,32 @@ def lift (h : IsAdjoinRoot S f) : S →+* T
rw [h.eval₂_repr_eq_eval₂_of_map_eq hx _ (h.repr z * h.repr w), eval₂_mul]
· rw [map_mul, map_repr, map_repr]
#align is_adjoin_root.lift IsAdjoinRoot.lift
+-/
variable {i x}
+#print IsAdjoinRoot.lift_map /-
@[simp]
theorem lift_map (h : IsAdjoinRoot S f) (z : R[X]) : h.lift i x hx (h.map z) = z.eval₂ i x := by
rw [lift, RingHom.coe_mk, h.eval₂_repr_eq_eval₂_of_map_eq hx _ _ rfl]
#align is_adjoin_root.lift_map IsAdjoinRoot.lift_map
+-/
+#print IsAdjoinRoot.lift_root /-
@[simp]
theorem lift_root (h : IsAdjoinRoot S f) : h.lift i x hx h.root = x := by
rw [← h.map_X, lift_map, eval₂_X]
#align is_adjoin_root.lift_root IsAdjoinRoot.lift_root
+-/
+#print IsAdjoinRoot.lift_algebraMap /-
@[simp]
theorem lift_algebraMap (h : IsAdjoinRoot S f) (a : R) : h.lift i x hx (algebraMap R S a) = i a :=
by rw [h.algebra_map_apply, lift_map, eval₂_C]
#align is_adjoin_root.lift_algebra_map IsAdjoinRoot.lift_algebraMap
+-/
+#print IsAdjoinRoot.apply_eq_lift /-
/-- Auxiliary lemma for `apply_eq_lift` -/
theorem apply_eq_lift (h : IsAdjoinRoot S f) (g : S →+* T) (hmap : ∀ a, g (algebraMap R S a) = i a)
(hroot : g h.root = x) (a : S) : g a = h.lift i x hx a :=
@@ -256,52 +301,67 @@ theorem apply_eq_lift (h : IsAdjoinRoot S f) (g : S →+* T) (hmap : ∀ a, g (a
simp only [map_sum, map_mul, map_pow, h.map_X, hroot, ← h.algebra_map_apply, hmap, lift_root,
lift_algebra_map]
#align is_adjoin_root.apply_eq_lift IsAdjoinRoot.apply_eq_lift
+-/
+#print IsAdjoinRoot.eq_lift /-
/-- Unicity of `lift`: a map that agrees on `R` and `h.root` agrees with `lift` everywhere. -/
theorem eq_lift (h : IsAdjoinRoot S f) (g : S →+* T) (hmap : ∀ a, g (algebraMap R S a) = i a)
(hroot : g h.root = x) : g = h.lift i x hx :=
RingHom.ext (h.apply_eq_lift hx g hmap hroot)
#align is_adjoin_root.eq_lift IsAdjoinRoot.eq_lift
+-/
variable [Algebra R T] (hx' : aeval x f = 0)
variable (x)
+#print IsAdjoinRoot.liftHom /-
-- To match `adjoin_root.lift_hom`
/-- Lift the algebra map `R → T` to `S →ₐ[R] T` by specifying a root `x` of `f` in `T`,
where `S` is given by adjoining a root of `f` to `R`. -/
def liftHom (h : IsAdjoinRoot S f) : S →ₐ[R] T :=
{ h.lift (algebraMap R T) x hx' with commutes' := fun a => h.lift_algebraMap hx' a }
#align is_adjoin_root.lift_hom IsAdjoinRoot.liftHom
+-/
variable {x}
+#print IsAdjoinRoot.coe_liftHom /-
@[simp]
theorem coe_liftHom (h : IsAdjoinRoot S f) :
(h.liftHom x hx' : S →+* T) = h.lift (algebraMap R T) x hx' :=
rfl
#align is_adjoin_root.coe_lift_hom IsAdjoinRoot.coe_liftHom
+-/
+#print IsAdjoinRoot.lift_algebraMap_apply /-
theorem lift_algebraMap_apply (h : IsAdjoinRoot S f) (z : S) :
h.lift (algebraMap R T) x hx' z = h.liftHom x hx' z :=
rfl
#align is_adjoin_root.lift_algebra_map_apply IsAdjoinRoot.lift_algebraMap_apply
+-/
+#print IsAdjoinRoot.liftHom_map /-
@[simp]
theorem liftHom_map (h : IsAdjoinRoot S f) (z : R[X]) : h.liftHom x hx' (h.map z) = aeval x z := by
rw [← lift_algebra_map_apply, lift_map, aeval_def]
#align is_adjoin_root.lift_hom_map IsAdjoinRoot.liftHom_map
+-/
+#print IsAdjoinRoot.liftHom_root /-
@[simp]
theorem liftHom_root (h : IsAdjoinRoot S f) : h.liftHom x hx' h.root = x := by
rw [← lift_algebra_map_apply, lift_root]
#align is_adjoin_root.lift_hom_root IsAdjoinRoot.liftHom_root
+-/
+#print IsAdjoinRoot.eq_liftHom /-
/-- Unicity of `lift_hom`: a map that agrees on `h.root` agrees with `lift_hom` everywhere. -/
theorem eq_liftHom (h : IsAdjoinRoot S f) (g : S →ₐ[R] T) (hroot : g h.root = x) :
g = h.liftHom x hx' :=
AlgHom.ext (h.apply_eq_lift hx' g g.commutes hroot)
#align is_adjoin_root.eq_lift_hom IsAdjoinRoot.eq_liftHom
+-/
end lift
@@ -311,6 +371,7 @@ namespace AdjoinRoot
variable (f)
+#print AdjoinRoot.isAdjoinRoot /-
/-- `adjoin_root f` is indeed given by adjoining a root of `f`. -/
protected def isAdjoinRoot : IsAdjoinRoot (AdjoinRoot f) f
where
@@ -322,34 +383,45 @@ protected def isAdjoinRoot : IsAdjoinRoot (AdjoinRoot f) f
← dvd_add_left (dvd_refl f), sub_add_cancel]
algebraMap_eq := AdjoinRoot.algebraMap_eq f
#align adjoin_root.is_adjoin_root AdjoinRoot.isAdjoinRoot
+-/
+#print AdjoinRoot.isAdjoinRootMonic /-
/-- `adjoin_root f` is indeed given by adjoining a root of `f`. If `f` is monic this is more
powerful than `adjoin_root.is_adjoin_root`. -/
protected def isAdjoinRootMonic (hf : Monic f) : IsAdjoinRootMonic (AdjoinRoot f) f :=
{ AdjoinRoot.isAdjoinRoot f with Monic := hf }
#align adjoin_root.is_adjoin_root_monic AdjoinRoot.isAdjoinRootMonic
+-/
+#print AdjoinRoot.isAdjoinRoot_map_eq_mk /-
@[simp]
theorem isAdjoinRoot_map_eq_mk : (AdjoinRoot.isAdjoinRoot f).map = AdjoinRoot.mk f :=
rfl
#align adjoin_root.is_adjoin_root_map_eq_mk AdjoinRoot.isAdjoinRoot_map_eq_mk
+-/
+#print AdjoinRoot.isAdjoinRootMonic_map_eq_mk /-
@[simp]
theorem isAdjoinRootMonic_map_eq_mk (hf : f.Monic) :
(AdjoinRoot.isAdjoinRootMonic f hf).map = AdjoinRoot.mk f :=
rfl
#align adjoin_root.is_adjoin_root_monic_map_eq_mk AdjoinRoot.isAdjoinRootMonic_map_eq_mk
+-/
+#print AdjoinRoot.isAdjoinRoot_root_eq_root /-
@[simp]
theorem isAdjoinRoot_root_eq_root : (AdjoinRoot.isAdjoinRoot f).root = AdjoinRoot.root f := by
simp only [IsAdjoinRoot.root, AdjoinRoot.root, AdjoinRoot.isAdjoinRoot_map_eq_mk]
#align adjoin_root.is_adjoin_root_root_eq_root AdjoinRoot.isAdjoinRoot_root_eq_root
+-/
+#print AdjoinRoot.isAdjoinRootMonic_root_eq_root /-
@[simp]
theorem isAdjoinRootMonic_root_eq_root (hf : Monic f) :
(AdjoinRoot.isAdjoinRootMonic f hf).root = AdjoinRoot.root f := by
simp only [IsAdjoinRoot.root, AdjoinRoot.root, AdjoinRoot.isAdjoinRootMonic_map_eq_mk]
#align adjoin_root.is_adjoin_root_monic_root_eq_root AdjoinRoot.isAdjoinRootMonic_root_eq_root
+-/
end AdjoinRoot
@@ -357,18 +429,23 @@ namespace IsAdjoinRootMonic
open IsAdjoinRoot
+#print IsAdjoinRootMonic.map_modByMonic /-
theorem map_modByMonic (h : IsAdjoinRootMonic S f) (g : R[X]) : h.map (g %ₘ f) = h.map g :=
by
rw [← RingHom.sub_mem_ker_iff, mem_ker_map, mod_by_monic_eq_sub_mul_div _ h.monic, sub_right_comm,
sub_self, zero_sub, dvd_neg]
exact ⟨_, rfl⟩
#align is_adjoin_root_monic.map_mod_by_monic IsAdjoinRootMonic.map_modByMonic
+-/
+#print IsAdjoinRootMonic.modByMonic_repr_map /-
theorem modByMonic_repr_map (h : IsAdjoinRootMonic S f) (g : R[X]) :
h.repr (h.map g) %ₘ f = g %ₘ f :=
modByMonic_eq_of_dvd_sub h.Monic <| by rw [← h.mem_ker_map, RingHom.sub_mem_ker_iff, map_repr]
#align is_adjoin_root_monic.mod_by_monic_repr_map IsAdjoinRootMonic.modByMonic_repr_map
+-/
+#print IsAdjoinRootMonic.modByMonicHom /-
/-- `is_adjoin_root.mod_by_monic_hom` sends the equivalence class of `f` mod `g` to `f %ₘ g`. -/
def modByMonicHom (h : IsAdjoinRootMonic S f) : S →ₗ[R] R[X]
where
@@ -380,18 +457,24 @@ def modByMonicHom (h : IsAdjoinRootMonic S f) : S →ₗ[R] R[X]
rw [RingHom.id_apply, ← h.map_repr x, Algebra.smul_def, h.algebra_map_apply, ← map_mul,
h.mod_by_monic_repr_map, ← smul_eq_C_mul, smul_mod_by_monic, h.map_repr]
#align is_adjoin_root_monic.mod_by_monic_hom IsAdjoinRootMonic.modByMonicHom
+-/
+#print IsAdjoinRootMonic.modByMonicHom_map /-
@[simp]
theorem modByMonicHom_map (h : IsAdjoinRootMonic S f) (g : R[X]) :
h.modByMonicHom (h.map g) = g %ₘ f :=
h.modByMonic_repr_map g
#align is_adjoin_root_monic.mod_by_monic_hom_map IsAdjoinRootMonic.modByMonicHom_map
+-/
+#print IsAdjoinRootMonic.map_modByMonicHom /-
@[simp]
theorem map_modByMonicHom (h : IsAdjoinRootMonic S f) (x : S) : h.map (h.modByMonicHom x) = x := by
rw [mod_by_monic_hom, LinearMap.coe_mk, map_mod_by_monic, map_repr]
#align is_adjoin_root_monic.map_mod_by_monic_hom IsAdjoinRootMonic.map_modByMonicHom
+-/
+#print IsAdjoinRootMonic.modByMonicHom_root_pow /-
@[simp]
theorem modByMonicHom_root_pow (h : IsAdjoinRootMonic S f) {n : ℕ} (hdeg : n < natDegree f) :
h.modByMonicHom (h.root ^ n) = X ^ n :=
@@ -401,12 +484,16 @@ theorem modByMonicHom_root_pow (h : IsAdjoinRootMonic S f) {n : ℕ} (hdeg : n <
contrapose! hdeg
simpa [nat_degree_le_iff_degree_le] using hdeg
#align is_adjoin_root_monic.mod_by_monic_hom_root_pow IsAdjoinRootMonic.modByMonicHom_root_pow
+-/
+#print IsAdjoinRootMonic.modByMonicHom_root /-
@[simp]
theorem modByMonicHom_root (h : IsAdjoinRootMonic S f) (hdeg : 1 < natDegree f) :
h.modByMonicHom h.root = X := by simpa using mod_by_monic_hom_root_pow h hdeg
#align is_adjoin_root_monic.mod_by_monic_hom_root IsAdjoinRootMonic.modByMonicHom_root
+-/
+#print IsAdjoinRootMonic.basis /-
/-- The basis on `S` generated by powers of `h.root`.
Auxiliary definition for `is_adjoin_root_monic.power_basis`. -/
@@ -448,7 +535,9 @@ def basis (h : IsAdjoinRootMonic S f) : Basis (Fin (natDegree f)) R S :=
simp only [map_smul, Finsupp.comapDomain_smul_of_injective Fin.val_injective,
RingHom.id_apply, to_finsupp_smul] }
#align is_adjoin_root_monic.basis IsAdjoinRootMonic.basis
+-/
+#print IsAdjoinRootMonic.basis_apply /-
@[simp]
theorem basis_apply (h : IsAdjoinRootMonic S f) (i) : h.Basis i = h.root ^ (i : ℕ) :=
Basis.apply_eq_iff.mpr <|
@@ -462,17 +551,23 @@ theorem basis_apply (h : IsAdjoinRootMonic S f) (i) : h.Basis i = h.root ^ (i :
· rw [X_pow_eq_monomial, to_finsupp_monomial, Finsupp.single_apply_left Fin.val_injective]
· exact i.is_lt
#align is_adjoin_root_monic.basis_apply IsAdjoinRootMonic.basis_apply
+-/
+#print IsAdjoinRootMonic.deg_pos /-
theorem deg_pos [Nontrivial S] (h : IsAdjoinRootMonic S f) : 0 < natDegree f :=
by
rcases h.basis.index_nonempty with ⟨⟨i, hi⟩⟩
exact (Nat.zero_le _).trans_lt hi
#align is_adjoin_root_monic.deg_pos IsAdjoinRootMonic.deg_pos
+-/
+#print IsAdjoinRootMonic.deg_ne_zero /-
theorem deg_ne_zero [Nontrivial S] (h : IsAdjoinRootMonic S f) : natDegree f ≠ 0 :=
h.deg_pos.ne'
#align is_adjoin_root_monic.deg_ne_zero IsAdjoinRootMonic.deg_ne_zero
+-/
+#print IsAdjoinRootMonic.powerBasis /-
/-- If `f` is monic, the powers of `h.root` form a basis. -/
@[simps gen dim Basis]
def powerBasis (h : IsAdjoinRootMonic S f) : PowerBasis R S
@@ -482,7 +577,9 @@ def powerBasis (h : IsAdjoinRootMonic S f) : PowerBasis R S
Basis := h.Basis
basis_eq_pow := h.basis_apply
#align is_adjoin_root_monic.power_basis IsAdjoinRootMonic.powerBasis
+-/
+#print IsAdjoinRootMonic.basis_repr /-
@[simp]
theorem basis_repr (h : IsAdjoinRootMonic S f) (x : S) (i : Fin (natDegree f)) :
h.Basis.repr x i = (h.modByMonicHom x).coeff (i : ℕ) :=
@@ -490,18 +587,24 @@ theorem basis_repr (h : IsAdjoinRootMonic S f) (x : S) (i : Fin (natDegree f)) :
change (h.mod_by_monic_hom x).toFinsupp.comapDomain coe (fin.coe_injective.inj_on _) i = _
rw [Finsupp.comapDomain_apply, Polynomial.toFinsupp_apply]
#align is_adjoin_root_monic.basis_repr IsAdjoinRootMonic.basis_repr
+-/
+#print IsAdjoinRootMonic.basis_one /-
theorem basis_one (h : IsAdjoinRootMonic S f) (hdeg : 1 < natDegree f) :
h.Basis ⟨1, hdeg⟩ = h.root := by rw [h.basis_apply, Fin.val_mk, pow_one]
#align is_adjoin_root_monic.basis_one IsAdjoinRootMonic.basis_one
+-/
+#print IsAdjoinRootMonic.liftPolyₗ /-
/-- `is_adjoin_root_monic.lift_polyₗ` lifts a linear map on polynomials to a linear map on `S`. -/
@[simps]
def liftPolyₗ {T : Type _} [AddCommGroup T] [Module R T] (h : IsAdjoinRootMonic S f)
(g : R[X] →ₗ[R] T) : S →ₗ[R] T :=
g.comp h.modByMonicHom
#align is_adjoin_root_monic.lift_polyₗ IsAdjoinRootMonic.liftPolyₗ
+-/
+#print IsAdjoinRootMonic.coeff /-
/-- `is_adjoin_root_monic.coeff h x i` is the `i`th coefficient of the representative of `x : S`.
-/
def coeff (h : IsAdjoinRootMonic S f) : S →ₗ[R] ℕ → R :=
@@ -510,7 +613,9 @@ def coeff (h : IsAdjoinRootMonic S f) : S →ₗ[R] ℕ → R :=
map_add' := fun p q => funext (Polynomial.coeff_add p q)
map_smul' := fun c p => funext (Polynomial.coeff_smul c p) }
#align is_adjoin_root_monic.coeff IsAdjoinRootMonic.coeff
+-/
+#print IsAdjoinRootMonic.coeff_apply_lt /-
theorem coeff_apply_lt (h : IsAdjoinRootMonic S f) (z : S) (i : ℕ) (hi : i < natDegree f) :
h.coeff z i = h.Basis.repr z ⟨i, hi⟩ :=
by
@@ -518,12 +623,16 @@ theorem coeff_apply_lt (h : IsAdjoinRootMonic S f) (z : S) (i : ℕ) (hi : i < n
LinearEquiv.coe_coe, lift_polyₗ_apply, LinearMap.coe_mk, h.basis_repr]
rfl
#align is_adjoin_root_monic.coeff_apply_lt IsAdjoinRootMonic.coeff_apply_lt
+-/
+#print IsAdjoinRootMonic.coeff_apply_coe /-
theorem coeff_apply_coe (h : IsAdjoinRootMonic S f) (z : S) (i : Fin (natDegree f)) :
h.coeff z i = h.Basis.repr z i :=
h.coeff_apply_lt z i i.Prop
#align is_adjoin_root_monic.coeff_apply_coe IsAdjoinRootMonic.coeff_apply_coe
+-/
+#print IsAdjoinRootMonic.coeff_apply_le /-
theorem coeff_apply_le (h : IsAdjoinRootMonic S f) (z : S) (i : ℕ) (hi : natDegree f ≤ i) :
h.coeff z i = 0 :=
by
@@ -534,7 +643,9 @@ theorem coeff_apply_le (h : IsAdjoinRootMonic S f) (z : S) (i : ℕ) (hi : natDe
Polynomial.coeff_eq_zero_of_degree_lt
((degree_mod_by_monic_lt _ h.monic).trans_le (Polynomial.degree_le_of_natDegree_le hi))
#align is_adjoin_root_monic.coeff_apply_le IsAdjoinRootMonic.coeff_apply_le
+-/
+#print IsAdjoinRootMonic.coeff_apply /-
theorem coeff_apply (h : IsAdjoinRootMonic S f) (z : S) (i : ℕ) :
h.coeff z i = if hi : i < natDegree f then h.Basis.repr z ⟨i, hi⟩ else 0 :=
by
@@ -542,7 +653,9 @@ theorem coeff_apply (h : IsAdjoinRootMonic S f) (z : S) (i : ℕ) :
· exact h.coeff_apply_lt z i hi
· exact h.coeff_apply_le z i (le_of_not_lt hi)
#align is_adjoin_root_monic.coeff_apply IsAdjoinRootMonic.coeff_apply
+-/
+#print IsAdjoinRootMonic.coeff_root_pow /-
theorem coeff_root_pow (h : IsAdjoinRootMonic S f) {n} (hn : n < natDegree f) :
h.coeff (h.root ^ n) = Pi.single n 1 := by
ext i
@@ -560,15 +673,21 @@ theorem coeff_root_pow (h : IsAdjoinRootMonic S f) {n} (hn : n < natDegree f) :
rintro rfl
simpa [hi] using hn
#align is_adjoin_root_monic.coeff_root_pow IsAdjoinRootMonic.coeff_root_pow
+-/
+#print IsAdjoinRootMonic.coeff_one /-
theorem coeff_one [Nontrivial S] (h : IsAdjoinRootMonic S f) : h.coeff 1 = Pi.single 0 1 := by
rw [← h.coeff_root_pow h.deg_pos, pow_zero]
#align is_adjoin_root_monic.coeff_one IsAdjoinRootMonic.coeff_one
+-/
+#print IsAdjoinRootMonic.coeff_root /-
theorem coeff_root (h : IsAdjoinRootMonic S f) (hdeg : 1 < natDegree f) :
h.coeff h.root = Pi.single 1 1 := by rw [← h.coeff_root_pow hdeg, pow_one]
#align is_adjoin_root_monic.coeff_root IsAdjoinRootMonic.coeff_root
+-/
+#print IsAdjoinRootMonic.coeff_algebraMap /-
theorem coeff_algebraMap [Nontrivial S] (h : IsAdjoinRootMonic S f) (x : R) :
h.coeff (algebraMap R S x) = Pi.single 0 x :=
by
@@ -578,7 +697,9 @@ theorem coeff_algebraMap [Nontrivial S] (h : IsAdjoinRootMonic S f) (x : R) :
intros
simp
#align is_adjoin_root_monic.coeff_algebra_map IsAdjoinRootMonic.coeff_algebraMap
+-/
+#print IsAdjoinRootMonic.ext_elem /-
theorem ext_elem (h : IsAdjoinRootMonic S f) ⦃x y : S⦄
(hxy : ∀ i < natDegree f, h.coeff x i = h.coeff y i) : x = y :=
EquivLike.injective h.Basis.equivFun <|
@@ -587,19 +708,26 @@ theorem ext_elem (h : IsAdjoinRootMonic S f) ⦃x y : S⦄
rw [Basis.equivFun_apply, ← h.coeff_apply_coe, Basis.equivFun_apply, ← h.coeff_apply_coe,
hxy i i.prop]
#align is_adjoin_root_monic.ext_elem IsAdjoinRootMonic.ext_elem
+-/
+#print IsAdjoinRootMonic.ext_elem_iff /-
theorem ext_elem_iff (h : IsAdjoinRootMonic S f) {x y : S} :
x = y ↔ ∀ i < natDegree f, h.coeff x i = h.coeff y i :=
⟨fun hxy i hi => hxy ▸ rfl, fun hxy => h.ext_elem hxy⟩
#align is_adjoin_root_monic.ext_elem_iff IsAdjoinRootMonic.ext_elem_iff
+-/
+#print IsAdjoinRootMonic.coeff_injective /-
theorem coeff_injective (h : IsAdjoinRootMonic S f) : Function.Injective h.coeff := fun x y hxy =>
h.ext_elem fun i hi => hxy ▸ rfl
#align is_adjoin_root_monic.coeff_injective IsAdjoinRootMonic.coeff_injective
+-/
+#print IsAdjoinRootMonic.isIntegral_root /-
theorem isIntegral_root (h : IsAdjoinRootMonic S f) : IsIntegral R h.root :=
⟨f, h.Monic, h.aeval_root⟩
#align is_adjoin_root_monic.is_integral_root IsAdjoinRootMonic.isIntegral_root
+-/
end IsAdjoinRootMonic
@@ -613,16 +741,20 @@ namespace IsAdjoinRoot
section lift
+#print IsAdjoinRoot.lift_self_apply /-
@[simp]
theorem lift_self_apply (h : IsAdjoinRoot S f) (x : S) :
h.lift (algebraMap R S) h.root h.aeval_root x = x := by
rw [← h.map_repr x, lift_map, ← aeval_def, h.aeval_eq]
#align is_adjoin_root.lift_self_apply IsAdjoinRoot.lift_self_apply
+-/
+#print IsAdjoinRoot.lift_self /-
theorem lift_self (h : IsAdjoinRoot S f) :
h.lift (algebraMap R S) h.root h.aeval_root = RingHom.id S :=
RingHom.ext h.lift_self_apply
#align is_adjoin_root.lift_self IsAdjoinRoot.lift_self
+-/
end lift
@@ -630,6 +762,7 @@ section Equiv
variable {T : Type _} [CommRing T] [Algebra R T]
+#print IsAdjoinRoot.aequiv /-
/-- Adjoining a root gives a unique ring up to algebra isomorphism.
This is the converse of `is_adjoin_root.of_equiv`: this turns an `is_adjoin_root` into an
@@ -644,52 +777,70 @@ def aequiv (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f) : S ≃ₐ[R] T :=
left_inv := fun x => by rw [← h.map_repr x, lift_hom_map, aeval_eq, lift_hom_map, aeval_eq]
right_inv := fun x => by rw [← h'.map_repr x, lift_hom_map, aeval_eq, lift_hom_map, aeval_eq] }
#align is_adjoin_root.aequiv IsAdjoinRoot.aequiv
+-/
+#print IsAdjoinRoot.aequiv_map /-
@[simp]
theorem aequiv_map (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f) (z : R[X]) :
h.aequiv h' (h.map z) = h'.map z := by rw [aequiv, AlgEquiv.coe_mk, lift_hom_map, aeval_eq]
#align is_adjoin_root.aequiv_map IsAdjoinRoot.aequiv_map
+-/
+#print IsAdjoinRoot.aequiv_root /-
@[simp]
theorem aequiv_root (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f) : h.aequiv h' h.root = h'.root :=
by rw [aequiv, AlgEquiv.coe_mk, lift_hom_root]
#align is_adjoin_root.aequiv_root IsAdjoinRoot.aequiv_root
+-/
+#print IsAdjoinRoot.aequiv_self /-
@[simp]
theorem aequiv_self (h : IsAdjoinRoot S f) : h.aequiv h = AlgEquiv.refl := by ext a;
exact h.lift_self_apply a
#align is_adjoin_root.aequiv_self IsAdjoinRoot.aequiv_self
+-/
+#print IsAdjoinRoot.aequiv_symm /-
@[simp]
theorem aequiv_symm (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f) :
(h.aequiv h').symm = h'.aequiv h := by ext; rfl
#align is_adjoin_root.aequiv_symm IsAdjoinRoot.aequiv_symm
+-/
+#print IsAdjoinRoot.lift_aequiv /-
@[simp]
theorem lift_aequiv {U : Type _} [CommRing U] (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f)
(i : R →+* U) (x hx z) : h'.lift i x hx (h.aequiv h' z) = h.lift i x hx z := by
rw [← h.map_repr z, aequiv_map, lift_map, lift_map]
#align is_adjoin_root.lift_aequiv IsAdjoinRoot.lift_aequiv
+-/
+#print IsAdjoinRoot.liftHom_aequiv /-
@[simp]
theorem liftHom_aequiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot T f) (x : U) (hx z) : h'.liftHom x hx (h.aequiv h' z) = h.liftHom x hx z :=
h.lift_aequiv h' _ _ hx _
#align is_adjoin_root.lift_hom_aequiv IsAdjoinRoot.liftHom_aequiv
+-/
+#print IsAdjoinRoot.aequiv_aequiv /-
@[simp]
theorem aequiv_aequiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot T f) (h'' : IsAdjoinRoot U f) (x) :
(h'.aequiv h'') (h.aequiv h' x) = h.aequiv h'' x :=
h.liftHom_aequiv _ _ h''.aeval_root _
#align is_adjoin_root.aequiv_aequiv IsAdjoinRoot.aequiv_aequiv
+-/
+#print IsAdjoinRoot.aequiv_trans /-
@[simp]
theorem aequiv_trans {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot T f) (h'' : IsAdjoinRoot U f) :
(h.aequiv h').trans (h'.aequiv h'') = h.aequiv h'' := by ext z; exact h.aequiv_aequiv h' h'' z
#align is_adjoin_root.aequiv_trans IsAdjoinRoot.aequiv_trans
+-/
+#print IsAdjoinRoot.ofEquiv /-
/-- Transfer `is_adjoin_root` across an algebra isomorphism.
This is the converse of `is_adjoin_root.aequiv`: this turns an `alg_equiv` into an `is_adjoin_root`,
@@ -707,18 +858,24 @@ def ofEquiv (h : IsAdjoinRoot S f) (e : S ≃ₐ[R] T) : IsAdjoinRoot T f
simp only [AlgEquiv.commutes, RingHom.comp_apply, AlgEquiv.coe_ringEquiv,
RingEquiv.coe_toRingHom, ← h.algebra_map_apply]
#align is_adjoin_root.of_equiv IsAdjoinRoot.ofEquiv
+-/
+#print IsAdjoinRoot.ofEquiv_root /-
@[simp]
theorem ofEquiv_root (h : IsAdjoinRoot S f) (e : S ≃ₐ[R] T) : (h.of_equiv e).root = e h.root :=
rfl
#align is_adjoin_root.of_equiv_root IsAdjoinRoot.ofEquiv_root
+-/
+#print IsAdjoinRoot.aequiv_ofEquiv /-
@[simp]
theorem aequiv_ofEquiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot T f) (e : T ≃ₐ[R] U) : h.aequiv (h'.of_equiv e) = (h.aequiv h').trans e := by
ext a <;> rw [← h.map_repr a, aequiv_map, AlgEquiv.trans_apply, aequiv_map, of_equiv_map_apply]
#align is_adjoin_root.aequiv_of_equiv IsAdjoinRoot.aequiv_ofEquiv
+-/
+#print IsAdjoinRoot.ofEquiv_aequiv /-
@[simp]
theorem ofEquiv_aequiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot U f) (e : S ≃ₐ[R] T) :
@@ -727,6 +884,7 @@ theorem ofEquiv_aequiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot
rw [← (h.of_equiv e).map_repr a, aequiv_map, AlgEquiv.trans_apply, of_equiv_map_apply,
e.symm_apply_apply, aequiv_map]
#align is_adjoin_root.of_equiv_aequiv IsAdjoinRoot.ofEquiv_aequiv
+-/
end Equiv
@@ -734,6 +892,7 @@ end IsAdjoinRoot
namespace IsAdjoinRootMonic
+#print IsAdjoinRootMonic.minpoly_eq /-
theorem minpoly_eq [IsDomain R] [IsDomain S] [NoZeroSMulDivisors R S] [IsIntegrallyClosed R]
(h : IsAdjoinRootMonic S f) (hirr : Irreducible f) : minpoly R h.root = f :=
let ⟨q, hq⟩ := minpoly.isIntegrallyClosed_dvd h.isIntegral_root h.aeval_root
@@ -745,6 +904,7 @@ theorem minpoly_eq [IsDomain R] [IsDomain S] [NoZeroSMulDivisors R S] [IsIntegra
(hirr.is_unit_or_is_unit hq).resolve_left <| minpoly.not_isUnit R h.root <;>
rw [mul_one]
#align is_adjoin_root_monic.minpoly_eq IsAdjoinRootMonic.minpoly_eq
+-/
end IsAdjoinRootMonic
@@ -752,6 +912,7 @@ section Algebra
open AdjoinRoot IsAdjoinRoot minpoly PowerBasis IsAdjoinRootMonic Algebra
+#print Algebra.adjoin.powerBasis'_minpoly_gen /-
theorem Algebra.adjoin.powerBasis'_minpoly_gen [IsDomain R] [IsDomain S] [NoZeroSMulDivisors R S]
[IsIntegrallyClosed R] {x : S} (hx' : IsIntegral R x) :
minpoly R x = minpoly R (minpoly.Algebra.adjoin.powerBasis' hx').gen :=
@@ -764,6 +925,7 @@ theorem Algebra.adjoin.powerBasis'_minpoly_gen [IsDomain R] [IsDomain S] [NoZero
is_adjoin_root_monic_root_eq_root _ (monic hx'), minpoly_eq]
exact Irreducible hx'
#align algebra.adjoin.power_basis'_minpoly_gen Algebra.adjoin.powerBasis'_minpoly_gen
+-/
end Algebra
mathlib commit https://github.com/leanprover-community/mathlib/commit/2a0ce625dbb0ffbc7d1316597de0b25c1ec75303
@@ -754,7 +754,7 @@ open AdjoinRoot IsAdjoinRoot minpoly PowerBasis IsAdjoinRootMonic Algebra
theorem Algebra.adjoin.powerBasis'_minpoly_gen [IsDomain R] [IsDomain S] [NoZeroSMulDivisors R S]
[IsIntegrallyClosed R] {x : S} (hx' : IsIntegral R x) :
- minpoly R x = minpoly R (Algebra.adjoin.powerBasis' hx').gen :=
+ minpoly R x = minpoly R (minpoly.Algebra.adjoin.powerBasis' hx').gen :=
by
haveI := is_domain_of_prime (prime_of_is_integrally_closed hx')
haveI :=
mathlib commit https://github.com/leanprover-community/mathlib/commit/9fb8964792b4237dac6200193a0d533f1b3f7423
@@ -202,8 +202,6 @@ section lift
variable {T : Type _} [CommRing T] {i : R →+* T} {x : T} (hx : f.eval₂ i x = 0)
-include hx
-
/-- Auxiliary lemma for `is_adjoin_root.lift` -/
theorem eval₂_repr_eq_eval₂_of_map_eq (h : IsAdjoinRoot S f) (z : S) (w : R[X])
(hzw : h.map w = z) : (h.repr z).eval₂ i x = w.eval₂ i x :=
@@ -267,8 +265,6 @@ theorem eq_lift (h : IsAdjoinRoot S f) (g : S →+* T) (hmap : ∀ a, g (algebra
variable [Algebra R T] (hx' : aeval x f = 0)
-omit hx
-
variable (x)
-- To match `adjoin_root.lift_hom`
mathlib commit https://github.com/leanprover-community/mathlib/commit/7e5137f579de09a059a5ce98f364a04e221aabf0
@@ -560,7 +560,6 @@ theorem coeff_root_pow (h : IsAdjoinRootMonic S f) {n} (hn : n < natDegree f) :
rw [h.basis.repr_self, ← Finsupp.single_eq_pi_single,
Finsupp.single_apply_left Fin.val_injective]
_ = Pi.single n 1 i := by rw [Fin.val_mk, Fin.val_mk]
-
· refine' (Pi.single_eq_of_ne _ (1 : (fun _ => R) _)).symm
rintro rfl
simpa [hi] using hn
mathlib commit https://github.com/leanprover-community/mathlib/commit/5f25c089cb34db4db112556f23c50d12da81b297
@@ -744,7 +744,8 @@ theorem minpoly_eq [IsDomain R] [IsDomain S] [NoZeroSMulDivisors R S] [IsIntegra
let ⟨q, hq⟩ := minpoly.isIntegrallyClosed_dvd h.isIntegral_root h.aeval_root
symm <|
eq_of_monic_of_associated h.Monic (minpoly.monic h.isIntegral_root) <| by
- convert Associated.mul_left (minpoly R h.root) <|
+ convert
+ Associated.mul_left (minpoly R h.root) <|
associated_one_iff_isUnit.2 <|
(hirr.is_unit_or_is_unit hq).resolve_left <| minpoly.not_isUnit R h.root <;>
rw [mul_one]
mathlib commit https://github.com/leanprover-community/mathlib/commit/cca40788df1b8755d5baf17ab2f27dacc2e17acb
@@ -86,7 +86,7 @@ This is not a typeclass because the choice of root given `S` and `f` is not uniq
-/
@[nolint has_nonempty_instance]
structure IsAdjoinRoot {R : Type u} (S : Type v) [CommSemiring R] [Semiring S] [Algebra R S]
- (f : R[X]) : Type max u v where
+ (f : R[X]) : Type max u v where
map : R[X] →+* S
map_surjective : Function.Surjective map
ker_map : RingHom.ker map = Ideal.span {f}
@@ -106,7 +106,7 @@ Bundling `monic` into this structure is very useful when working with explicit `
-/
@[nolint has_nonempty_instance]
structure IsAdjoinRootMonic {R : Type u} (S : Type v) [CommSemiring R] [Semiring S] [Algebra R S]
- (f : R[X]) extends IsAdjoinRoot S f where
+ (f : R[X]) extends IsAdjoinRoot S f where
Monic : Monic f
#align is_adjoin_root_monic IsAdjoinRootMonic
@@ -208,7 +208,7 @@ include hx
theorem eval₂_repr_eq_eval₂_of_map_eq (h : IsAdjoinRoot S f) (z : S) (w : R[X])
(hzw : h.map w = z) : (h.repr z).eval₂ i x = w.eval₂ i x :=
by
- rw [eq_comm, ← sub_eq_zero, ← h.map_repr z, ← map_sub, h.map_eq_zero_iff] at hzw
+ rw [eq_comm, ← sub_eq_zero, ← h.map_repr z, ← map_sub, h.map_eq_zero_iff] at hzw
obtain ⟨y, hy⟩ := hzw
rw [← sub_eq_zero, ← eval₂_sub, hy, eval₂_mul, hx, MulZeroClass.zero_mul]
#align is_adjoin_root.eval₂_repr_eq_eval₂_of_map_eq IsAdjoinRoot.eval₂_repr_eq_eval₂_of_map_eq
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -62,7 +62,7 @@ Using `is_adjoin_root` to map out of `S`:
-/
-open Polynomial
+open scoped Polynomial
open Polynomial
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -661,17 +661,13 @@ theorem aequiv_root (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f) : h.aequiv h'
#align is_adjoin_root.aequiv_root IsAdjoinRoot.aequiv_root
@[simp]
-theorem aequiv_self (h : IsAdjoinRoot S f) : h.aequiv h = AlgEquiv.refl :=
- by
- ext a
+theorem aequiv_self (h : IsAdjoinRoot S f) : h.aequiv h = AlgEquiv.refl := by ext a;
exact h.lift_self_apply a
#align is_adjoin_root.aequiv_self IsAdjoinRoot.aequiv_self
@[simp]
theorem aequiv_symm (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f) :
- (h.aequiv h').symm = h'.aequiv h := by
- ext
- rfl
+ (h.aequiv h').symm = h'.aequiv h := by ext; rfl
#align is_adjoin_root.aequiv_symm IsAdjoinRoot.aequiv_symm
@[simp]
@@ -696,10 +692,7 @@ theorem aequiv_aequiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot
@[simp]
theorem aequiv_trans {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot T f) (h'' : IsAdjoinRoot U f) :
- (h.aequiv h').trans (h'.aequiv h'') = h.aequiv h'' :=
- by
- ext z
- exact h.aequiv_aequiv h' h'' z
+ (h.aequiv h').trans (h'.aequiv h'') = h.aequiv h'' := by ext z; exact h.aequiv_aequiv h' h'' z
#align is_adjoin_root.aequiv_trans IsAdjoinRoot.aequiv_trans
/-- Transfer `is_adjoin_root` across an algebra isomorphism.
mathlib commit https://github.com/leanprover-community/mathlib/commit/57e09a1296bfb4330ddf6624f1028ba186117d82
@@ -415,7 +415,7 @@ theorem modByMonicHom_root (h : IsAdjoinRootMonic S f) (hdeg : 1 < natDegree f)
Auxiliary definition for `is_adjoin_root_monic.power_basis`. -/
def basis (h : IsAdjoinRootMonic S f) : Basis (Fin (natDegree f)) R S :=
- Basis.of_repr
+ Basis.ofRepr
{ toFun := fun x => (h.modByMonicHom x).toFinsupp.comapDomain coe (Fin.val_injective.InjOn _)
invFun := fun g => h.map (ofFinsupp (g.mapDomain coe))
left_inv := fun x => by
mathlib commit https://github.com/leanprover-community/mathlib/commit/ce7e9d53d4bbc38065db3b595cd5bd73c323bc1d
@@ -751,8 +751,7 @@ theorem minpoly_eq [IsDomain R] [IsDomain S] [NoZeroSMulDivisors R S] [IsIntegra
let ⟨q, hq⟩ := minpoly.isIntegrallyClosed_dvd h.isIntegral_root h.aeval_root
symm <|
eq_of_monic_of_associated h.Monic (minpoly.monic h.isIntegral_root) <| by
- convert
- Associated.mul_left (minpoly R h.root) <|
+ convert Associated.mul_left (minpoly R h.root) <|
associated_one_iff_isUnit.2 <|
(hirr.is_unit_or_is_unit hq).resolve_left <| minpoly.not_isUnit R h.root <;>
rw [mul_one]
mathlib commit https://github.com/leanprover-community/mathlib/commit/3180fab693e2cee3bff62675571264cb8778b212
@@ -210,7 +210,7 @@ theorem eval₂_repr_eq_eval₂_of_map_eq (h : IsAdjoinRoot S f) (z : S) (w : R[
by
rw [eq_comm, ← sub_eq_zero, ← h.map_repr z, ← map_sub, h.map_eq_zero_iff] at hzw
obtain ⟨y, hy⟩ := hzw
- rw [← sub_eq_zero, ← eval₂_sub, hy, eval₂_mul, hx, zero_mul]
+ rw [← sub_eq_zero, ← eval₂_sub, hy, eval₂_mul, hx, MulZeroClass.zero_mul]
#align is_adjoin_root.eval₂_repr_eq_eval₂_of_map_eq IsAdjoinRoot.eval₂_repr_eq_eval₂_of_map_eq
variable (i x)
mathlib commit https://github.com/leanprover-community/mathlib/commit/38f16f960f5006c6c0c2bac7b0aba5273188f4e5
@@ -254,7 +254,7 @@ theorem lift_algebraMap (h : IsAdjoinRoot S f) (a : R) : h.lift i x hx (algebraM
theorem apply_eq_lift (h : IsAdjoinRoot S f) (g : S →+* T) (hmap : ∀ a, g (algebraMap R S a) = i a)
(hroot : g h.root = x) (a : S) : g a = h.lift i x hx a :=
by
- rw [← h.map_repr a, Polynomial.as_sum_range_c_mul_x_pow (h.repr a)]
+ rw [← h.map_repr a, Polynomial.as_sum_range_C_mul_X_pow (h.repr a)]
simp only [map_sum, map_mul, map_pow, h.map_X, hroot, ← h.algebra_map_apply, hmap, lift_root,
lift_algebra_map]
#align is_adjoin_root.apply_eq_lift IsAdjoinRoot.apply_eq_lift
mathlib commit https://github.com/leanprover-community/mathlib/commit/38f16f960f5006c6c0c2bac7b0aba5273188f4e5
@@ -90,7 +90,7 @@ structure IsAdjoinRoot {R : Type u} (S : Type v) [CommSemiring R] [Semiring S] [
map : R[X] →+* S
map_surjective : Function.Surjective map
ker_map : RingHom.ker map = Ideal.span {f}
- algebraMap_eq : algebraMap R S = map.comp Polynomial.c
+ algebraMap_eq : algebraMap R S = map.comp Polynomial.C
#align is_adjoin_root IsAdjoinRoot
-- This class doesn't really make sense on a predicate
@@ -118,7 +118,7 @@ namespace IsAdjoinRoot
/-- `(h : is_adjoin_root S f).root` is the root of `f` that can be adjoined to generate `S`. -/
def root (h : IsAdjoinRoot S f) : S :=
- h.map x
+ h.map X
#align is_adjoin_root.root IsAdjoinRoot.root
theorem subsingleton (h : IsAdjoinRoot S f) [Subsingleton R] : Subsingleton S :=
@@ -126,7 +126,7 @@ theorem subsingleton (h : IsAdjoinRoot S f) [Subsingleton R] : Subsingleton S :=
#align is_adjoin_root.subsingleton IsAdjoinRoot.subsingleton
theorem algebraMap_apply (h : IsAdjoinRoot S f) (x : R) :
- algebraMap R S x = h.map (Polynomial.c x) := by rw [h.algebra_map_eq, RingHom.comp_apply]
+ algebraMap R S x = h.map (Polynomial.C x) := by rw [h.algebra_map_eq, RingHom.comp_apply]
#align is_adjoin_root.algebra_map_apply IsAdjoinRoot.algebraMap_apply
@[simp]
@@ -139,7 +139,7 @@ theorem map_eq_zero_iff (h : IsAdjoinRoot S f) {p} : h.map p = 0 ↔ f ∣ p :=
#align is_adjoin_root.map_eq_zero_iff IsAdjoinRoot.map_eq_zero_iff
@[simp]
-theorem map_x (h : IsAdjoinRoot S f) : h.map x = h.root :=
+theorem map_x (h : IsAdjoinRoot S f) : h.map X = h.root :=
rfl
#align is_adjoin_root.map_X IsAdjoinRoot.map_x
@@ -398,7 +398,7 @@ theorem map_modByMonicHom (h : IsAdjoinRootMonic S f) (x : S) : h.map (h.modByMo
@[simp]
theorem modByMonicHom_root_pow (h : IsAdjoinRootMonic S f) {n : ℕ} (hdeg : n < natDegree f) :
- h.modByMonicHom (h.root ^ n) = x ^ n :=
+ h.modByMonicHom (h.root ^ n) = X ^ n :=
by
nontriviality R
rwa [← h.map_X, ← map_pow, mod_by_monic_hom_map, mod_by_monic_eq_self_iff h.monic, degree_X_pow]
@@ -408,7 +408,7 @@ theorem modByMonicHom_root_pow (h : IsAdjoinRootMonic S f) {n : ℕ} (hdeg : n <
@[simp]
theorem modByMonicHom_root (h : IsAdjoinRootMonic S f) (hdeg : 1 < natDegree f) :
- h.modByMonicHom h.root = x := by simpa using mod_by_monic_hom_root_pow h hdeg
+ h.modByMonicHom h.root = X := by simpa using mod_by_monic_hom_root_pow h hdeg
#align is_adjoin_root_monic.mod_by_monic_hom_root IsAdjoinRootMonic.modByMonicHom_root
/-- The basis on `S` generated by powers of `h.root`.
@@ -417,7 +417,7 @@ Auxiliary definition for `is_adjoin_root_monic.power_basis`. -/
def basis (h : IsAdjoinRootMonic S f) : Basis (Fin (natDegree f)) R S :=
Basis.of_repr
{ toFun := fun x => (h.modByMonicHom x).toFinsupp.comapDomain coe (Fin.val_injective.InjOn _)
- invFun := fun g => h.map (of_finsupp (g.mapDomain coe))
+ invFun := fun g => h.map (ofFinsupp (g.mapDomain coe))
left_inv := fun x => by
cases subsingleton_or_nontrivial R
· haveI := h.subsingleton
mathlib commit https://github.com/leanprover-community/mathlib/commit/bd9851ca476957ea4549eb19b40e7b5ade9428cc
@@ -223,7 +223,7 @@ def lift (h : IsAdjoinRoot S f) : S →+* T where
rw [h.eval₂_repr_eq_eval₂_of_map_eq hx _ (h.repr z + h.repr w), eval₂_add]
· rw [map_add, map_repr, map_repr]
map_one' := by
- dsimp only -- Porting note (#10752): added `dsimp only`
+ beta_reduce -- Porting note (#12129): additional beta reduction needed
rw [h.eval₂_repr_eq_eval₂_of_map_eq hx _ _ (map_one _), eval₂_one]
map_mul' z w := by
dsimp only -- Porting note (#10752): added `dsimp only`
@@ -371,7 +371,7 @@ def modByMonicHom (h : IsAdjoinRootMonic S f) : S →ₗ[R] R[X] where
map_add' x y := by
conv_lhs =>
rw [← h.map_repr x, ← h.map_repr y, ← map_add]
- dsimp only -- Porting note (#10752): added `dsimp only`
+ beta_reduce -- Porting note (#12129): additional beta reduction needed
rw [h.modByMonic_repr_map, add_modByMonic]
map_smul' c x := by
rw [RingHom.id_apply, ← h.map_repr x, Algebra.smul_def, h.algebraMap_apply, ← map_mul]
@@ -446,7 +446,7 @@ def basis (h : IsAdjoinRootMonic S f) : Basis (Fin (natDegree f)) R S :=
rintro i rfl
exact i.prop.not_le hm
map_add' := fun x y => by
- dsimp only -- Porting note (#10752): added `dsimp only`
+ beta_reduce -- Porting note (#12129): additional beta reduction needed
rw [map_add, toFinsupp_add, Finsupp.comapDomain_add_of_injective Fin.val_injective]
-- Porting note: the original simp proof with the same lemmas does not work
-- See https://github.com/leanprover-community/mathlib4/issues/5026
@@ -83,7 +83,8 @@ and `AdjoinRoot` which constructs a new type.
This is not a typeclass because the choice of root given `S` and `f` is not unique.
-/
--- @[nolint has_nonempty_instance] -- Porting note: This linter does not exist yet.
+-- Porting note(#5171): this linter isn't ported yet.
+-- @[nolint has_nonempty_instance]
structure IsAdjoinRoot {R : Type u} (S : Type v) [CommSemiring R] [Semiring S] [Algebra R S]
(f : R[X]) : Type max u v where
map : R[X] →+* S
Data
(#11751)
Polynomial
and MvPolynomial
are algebraic objects, hence should be under Algebra
(or at least not under Data
)
@@ -4,7 +4,7 @@ Copyright (c) 2022 Anne Baanen. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen
-/
-import Mathlib.Data.Polynomial.AlgebraMap
+import Mathlib.Algebra.Polynomial.AlgebraMap
import Mathlib.FieldTheory.Minpoly.IsIntegrallyClosed
import Mathlib.RingTheory.PowerBasis
@@ -421,7 +421,7 @@ def basis (h : IsAdjoinRootMonic S f) : Basis (Fin (natDegree f)) R S :=
intro i hi
refine Set.mem_range.mpr ⟨⟨i, ?_⟩, rfl⟩
contrapose! hi
- simp only [Polynomial.toFinsupp_apply, Classical.not_not, Finsupp.mem_support_iff, Ne.def,
+ simp only [Polynomial.toFinsupp_apply, Classical.not_not, Finsupp.mem_support_iff, Ne,
modByMonicHom, LinearMap.coe_mk, Finset.mem_coe]
by_cases hx : h.toIsAdjoinRoot.repr x %ₘ f = 0
· simp [hx]
Empty lines were removed by executing the following Python script twice
import os
import re
# Loop through each file in the repository
for dir_path, dirs, files in os.walk('.'):
for filename in files:
if filename.endswith('.lean'):
file_path = os.path.join(dir_path, filename)
# Open the file and read its contents
with open(file_path, 'r') as file:
content = file.read()
# Use a regular expression to replace sequences of "variable" lines separated by empty lines
# with sequences without empty lines
modified_content = re.sub(r'(variable.*\n)\n(variable(?! .* in))', r'\1\2', content)
# Write the modified content back to the file
with open(file_path, 'w') as file:
file.write(modified_content)
@@ -264,7 +264,6 @@ theorem eq_lift (h : IsAdjoinRoot S f) (g : S →+* T) (hmap : ∀ a, g (algebra
#align is_adjoin_root.eq_lift IsAdjoinRoot.eq_lift
variable [Algebra R T] (hx' : aeval x f = 0)
-
variable (x)
-- To match `AdjoinRoot.liftHom`
@@ -235,7 +235,7 @@ variable {i x}
@[simp]
theorem lift_map (h : IsAdjoinRoot S f) (z : R[X]) : h.lift i x hx (h.map z) = z.eval₂ i x := by
rw [lift, RingHom.coe_mk]
- dsimp -- Porting note: added
+ dsimp -- Porting note (#11227):added a `dsimp`
rw [h.eval₂_repr_eq_eval₂_of_map_eq hx _ _ rfl]
#align is_adjoin_root.lift_map IsAdjoinRoot.lift_map
@@ -387,7 +387,7 @@ theorem modByMonicHom_map (h : IsAdjoinRootMonic S f) (g : R[X]) :
@[simp]
theorem map_modByMonicHom (h : IsAdjoinRootMonic S f) (x : S) : h.map (h.modByMonicHom x) = x := by
rw [modByMonicHom, LinearMap.coe_mk]
- dsimp -- Porting note: added
+ dsimp -- Porting note (#11227):added a `dsimp`
rw [map_modByMonic, map_repr]
#align is_adjoin_root_monic.map_mod_by_monic_hom IsAdjoinRootMonic.map_modByMonicHom
@@ -427,7 +427,7 @@ def basis (h : IsAdjoinRootMonic S f) : Basis (Fin (natDegree f)) R S :=
by_cases hx : h.toIsAdjoinRoot.repr x %ₘ f = 0
· simp [hx]
refine coeff_eq_zero_of_natDegree_lt (lt_of_lt_of_le ?_ hi)
- dsimp -- Porting note: added
+ dsimp -- Porting note (#11227):added a `dsimp`
rw [natDegree_lt_natDegree_iff hx]
· exact degree_modByMonic_lt _ h.Monic
right_inv := fun g => by
@@ -154,7 +154,7 @@ theorem aeval_eq (h : IsAdjoinRoot S f) (p : R[X]) : aeval h.root p = h.map p :=
RingHom.map_pow, map_X]
#align is_adjoin_root.aeval_eq IsAdjoinRoot.aeval_eq
--- @[simp] -- Porting note: simp can prove this
+-- @[simp] -- Porting note (#10618): simp can prove this
theorem aeval_root (h : IsAdjoinRoot S f) : aeval h.root f = 0 := by rw [aeval_eq, map_self]
#align is_adjoin_root.aeval_root IsAdjoinRoot.aeval_root
@@ -215,17 +215,17 @@ where `S` is given by adjoining a root of `f` to `R`. -/
def lift (h : IsAdjoinRoot S f) : S →+* T where
toFun z := (h.repr z).eval₂ i x
map_zero' := by
- dsimp only -- Porting note: added
+ dsimp only -- Porting note (#10752): added `dsimp only`
rw [h.eval₂_repr_eq_eval₂_of_map_eq hx _ _ (map_zero _), eval₂_zero]
map_add' z w := by
- dsimp only -- Porting note: added
+ dsimp only -- Porting note (#10752): added `dsimp only`
rw [h.eval₂_repr_eq_eval₂_of_map_eq hx _ (h.repr z + h.repr w), eval₂_add]
· rw [map_add, map_repr, map_repr]
map_one' := by
- dsimp only -- Porting note: added
+ dsimp only -- Porting note (#10752): added `dsimp only`
rw [h.eval₂_repr_eq_eval₂_of_map_eq hx _ _ (map_one _), eval₂_one]
map_mul' z w := by
- dsimp only -- Porting note: added
+ dsimp only -- Porting note (#10752): added `dsimp only`
rw [h.eval₂_repr_eq_eval₂_of_map_eq hx _ (h.repr z * h.repr w), eval₂_mul]
· rw [map_mul, map_repr, map_repr]
#align is_adjoin_root.lift IsAdjoinRoot.lift
@@ -371,11 +371,11 @@ def modByMonicHom (h : IsAdjoinRootMonic S f) : S →ₗ[R] R[X] where
map_add' x y := by
conv_lhs =>
rw [← h.map_repr x, ← h.map_repr y, ← map_add]
- dsimp only -- Porting note: added
+ dsimp only -- Porting note (#10752): added `dsimp only`
rw [h.modByMonic_repr_map, add_modByMonic]
map_smul' c x := by
rw [RingHom.id_apply, ← h.map_repr x, Algebra.smul_def, h.algebraMap_apply, ← map_mul]
- dsimp only -- Porting note: added
+ dsimp only -- Porting note (#10752): added `dsimp only`
rw [h.modByMonic_repr_map, ← smul_eq_C_mul, smul_modByMonic, h.map_repr]
#align is_adjoin_root_monic.mod_by_monic_hom IsAdjoinRootMonic.modByMonicHom
@@ -435,24 +435,24 @@ def basis (h : IsAdjoinRootMonic S f) : Basis (Fin (natDegree f)) R S :=
ext i
simp only [h.modByMonicHom_map, Finsupp.comapDomain_apply, Polynomial.toFinsupp_apply]
rw [(Polynomial.modByMonic_eq_self_iff h.Monic).mpr, Polynomial.coeff]
- dsimp only -- Porting note: added
+ dsimp only -- Porting note (#10752): added `dsimp only`
rw [Finsupp.mapDomain_apply Fin.val_injective]
rw [degree_eq_natDegree h.Monic.ne_zero, degree_lt_iff_coeff_zero]
intro m hm
rw [Polynomial.coeff]
- dsimp only -- Porting note: added
+ dsimp only -- Porting note (#10752): added `dsimp only`
rw [Finsupp.mapDomain_notin_range]
rw [Set.mem_range, not_exists]
rintro i rfl
exact i.prop.not_le hm
map_add' := fun x y => by
- dsimp only -- Porting note: added
+ dsimp only -- Porting note (#10752): added `dsimp only`
rw [map_add, toFinsupp_add, Finsupp.comapDomain_add_of_injective Fin.val_injective]
-- Porting note: the original simp proof with the same lemmas does not work
-- See https://github.com/leanprover-community/mathlib4/issues/5026
-- simp only [map_add, Finsupp.comapDomain_add_of_injective Fin.val_injective, toFinsupp_add]
map_smul' := fun c x => by
- dsimp only -- Porting note: added
+ dsimp only -- Porting note (#10752): added `dsimp only`
rw [map_smul, toFinsupp_smul, Finsupp.comapDomain_smul_of_injective Fin.val_injective,
RingHom.id_apply] }
-- Porting note: the original simp proof with the same lemmas does not work
@@ -557,7 +557,7 @@ theorem coeff_root_pow (h : IsAdjoinRootMonic S f) {n} (hn : n < natDegree f) :
↑(⟨i, _⟩ : Fin _) := by
rw [h.basis.repr_self, ← Finsupp.single_eq_pi_single,
Finsupp.single_apply_left Fin.val_injective]
- _ = Pi.single (f:= fun _ => R) n 1 i := by rw [Fin.val_mk, Fin.val_mk]
+ _ = Pi.single (f := fun _ => R) n 1 i := by rw [Fin.val_mk, Fin.val_mk]
· refine (Pi.single_eq_of_ne (f := fun _ => R) ?_ (1 : (fun _ => R) n)).symm
rintro rfl
simp [hi] at hn
MulZeroClass.
in mul_zero
/zero_mul
(#6682)
Search&replace MulZeroClass.mul_zero
-> mul_zero
, MulZeroClass.zero_mul
-> zero_mul
.
These were introduced by Mathport, as the full name of mul_zero
is actually MulZeroClass.mul_zero
(it's exported with the short name).
@@ -204,7 +204,7 @@ theorem eval₂_repr_eq_eval₂_of_map_eq (h : IsAdjoinRoot S f) (z : S) (w : R[
(hzw : h.map w = z) : (h.repr z).eval₂ i x = w.eval₂ i x := by
rw [eq_comm, ← sub_eq_zero, ← h.map_repr z, ← map_sub, h.map_eq_zero_iff] at hzw
obtain ⟨y, hy⟩ := hzw
- rw [← sub_eq_zero, ← eval₂_sub, hy, eval₂_mul, hx, MulZeroClass.zero_mul]
+ rw [← sub_eq_zero, ← eval₂_sub, hy, eval₂_mul, hx, zero_mul]
#align is_adjoin_root.eval₂_repr_eq_eval₂_of_map_eq IsAdjoinRoot.eval₂_repr_eq_eval₂_of_map_eq
variable (i x)
Type _
and Sort _
(#6499)
We remove all possible occurences of Type _
and Sort _
in favor of Type*
and Sort*
.
This has nice performance benefits.
@@ -197,7 +197,7 @@ theorem ext (h h' : IsAdjoinRoot S f) (eq : h.root = h'.root) : h = h' :=
section lift
-variable {T : Type _} [CommRing T] {i : R →+* T} {x : T} (hx : f.eval₂ i x = 0)
+variable {T : Type*} [CommRing T] {i : R →+* T} {x : T} (hx : f.eval₂ i x = 0)
/-- Auxiliary lemma for `IsAdjoinRoot.lift` -/
theorem eval₂_repr_eq_eval₂_of_map_eq (h : IsAdjoinRoot S f) (z : S) (w : R[X])
@@ -503,7 +503,7 @@ theorem basis_one (h : IsAdjoinRootMonic S f) (hdeg : 1 < natDegree f) :
/-- `IsAdjoinRootMonic.liftPolyₗ` lifts a linear map on polynomials to a linear map on `S`. -/
@[simps!]
-def liftPolyₗ {T : Type _} [AddCommGroup T] [Module R T] (h : IsAdjoinRootMonic S f)
+def liftPolyₗ {T : Type*} [AddCommGroup T] [Module R T] (h : IsAdjoinRootMonic S f)
(g : R[X] →ₗ[R] T) : S →ₗ[R] T :=
g.comp h.modByMonicHom
#align is_adjoin_root_monic.lift_polyₗ IsAdjoinRootMonic.liftPolyₗ
@@ -628,7 +628,7 @@ end lift
section Equiv
-variable {T : Type _} [CommRing T] [Algebra R T]
+variable {T : Type*} [CommRing T] [Algebra R T]
/-- Adjoining a root gives a unique ring up to algebra isomorphism.
@@ -664,26 +664,26 @@ theorem aequiv_symm (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f) :
#align is_adjoin_root.aequiv_symm IsAdjoinRoot.aequiv_symm
@[simp]
-theorem lift_aequiv {U : Type _} [CommRing U] (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f)
+theorem lift_aequiv {U : Type*} [CommRing U] (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f)
(i : R →+* U) (x hx z) : h'.lift i x hx (h.aequiv h' z) = h.lift i x hx z := by
rw [← h.map_repr z, aequiv_map, lift_map, lift_map]
#align is_adjoin_root.lift_aequiv IsAdjoinRoot.lift_aequiv
@[simp]
-theorem liftHom_aequiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
+theorem liftHom_aequiv {U : Type*} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot T f) (x : U) (hx z) : h'.liftHom x hx (h.aequiv h' z) = h.liftHom x hx z :=
h.lift_aequiv h' _ _ hx _
#align is_adjoin_root.lift_hom_aequiv IsAdjoinRoot.liftHom_aequiv
@[simp]
-theorem aequiv_aequiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
+theorem aequiv_aequiv {U : Type*} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot T f) (h'' : IsAdjoinRoot U f) (x) :
(h'.aequiv h'') (h.aequiv h' x) = h.aequiv h'' x :=
h.liftHom_aequiv _ _ h''.aeval_root _
#align is_adjoin_root.aequiv_aequiv IsAdjoinRoot.aequiv_aequiv
@[simp]
-theorem aequiv_trans {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
+theorem aequiv_trans {U : Type*} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot T f) (h'' : IsAdjoinRoot U f) :
(h.aequiv h').trans (h'.aequiv h'') = h.aequiv h'' := by ext z; exact h.aequiv_aequiv h' h'' z
#align is_adjoin_root.aequiv_trans IsAdjoinRoot.aequiv_trans
@@ -710,13 +710,13 @@ theorem ofEquiv_root (h : IsAdjoinRoot S f) (e : S ≃ₐ[R] T) : (h.ofEquiv e).
#align is_adjoin_root.of_equiv_root IsAdjoinRoot.ofEquiv_root
@[simp]
-theorem aequiv_ofEquiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
+theorem aequiv_ofEquiv {U : Type*} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot T f) (e : T ≃ₐ[R] U) : h.aequiv (h'.ofEquiv e) = (h.aequiv h').trans e := by
ext a; rw [← h.map_repr a, aequiv_map, AlgEquiv.trans_apply, aequiv_map, ofEquiv_map_apply]
#align is_adjoin_root.aequiv_of_equiv IsAdjoinRoot.aequiv_ofEquiv
@[simp]
-theorem ofEquiv_aequiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
+theorem ofEquiv_aequiv {U : Type*} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot U f) (e : S ≃ₐ[R] T) :
(h.ofEquiv e).aequiv h' = e.symm.trans (h.aequiv h') := by
ext a
@@ -3,16 +3,13 @@
Copyright (c) 2022 Anne Baanen. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen
-
-! This file was ported from Lean 3 source module ring_theory.is_adjoin_root
-! leanprover-community/mathlib commit f7fc89d5d5ff1db2d1242c7bb0e9062ce47ef47c
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathlib.Data.Polynomial.AlgebraMap
import Mathlib.FieldTheory.Minpoly.IsIntegrallyClosed
import Mathlib.RingTheory.PowerBasis
+#align_import ring_theory.is_adjoin_root from "leanprover-community/mathlib"@"f7fc89d5d5ff1db2d1242c7bb0e9062ce47ef47c"
+
/-!
# A predicate on adjoining roots of polynomial
This is the second half of the changes originally in #5699, removing all occurrences of ;
after a space and implementing a linter rule to enforce it.
In most cases this 2-character substring has a space after it, so the following command was run first:
find . -type f -name "*.lean" -exec sed -i -E 's/ ; /; /g' {} \;
The remaining cases were few enough in number that they were done manually.
@@ -715,7 +715,7 @@ theorem ofEquiv_root (h : IsAdjoinRoot S f) (e : S ≃ₐ[R] T) : (h.ofEquiv e).
@[simp]
theorem aequiv_ofEquiv {U : Type _} [CommRing U] [Algebra R U] (h : IsAdjoinRoot S f)
(h' : IsAdjoinRoot T f) (e : T ≃ₐ[R] U) : h.aequiv (h'.ofEquiv e) = (h.aequiv h').trans e := by
- ext a ; rw [← h.map_repr a, aequiv_map, AlgEquiv.trans_apply, aequiv_map, ofEquiv_map_apply]
+ ext a; rw [← h.map_repr a, aequiv_map, AlgEquiv.trans_apply, aequiv_map, ofEquiv_map_apply]
#align is_adjoin_root.aequiv_of_equiv IsAdjoinRoot.aequiv_ofEquiv
@[simp]
@@ -27,7 +27,7 @@ in order to provide an easier way to translate results from one to the other.
## Motivation
`AdjoinRoot` presents one construction of a ring `R[α]`. However, it is possible to obtain
-rings of this form in many ways, such as `NumberField.ring_of_integers ℚ(√-5)`,
+rings of this form in many ways, such as `NumberField.ringOfIntegers ℚ(√-5)`,
or `Algebra.adjoin R {α, α^2}`, or `IntermediateField.adjoin R {α, 2 - α}`,
or even if we want to view `ℂ` as adjoining a root of `X^2 + 1` to `ℝ`.
@@ -298,7 +298,7 @@ theorem liftHom_root (h : IsAdjoinRoot S f) : h.liftHom x hx' h.root = x := by
rw [← lift_algebraMap_apply, lift_root]
#align is_adjoin_root.lift_hom_root IsAdjoinRoot.liftHom_root
-/-- Unicity of `lift_hom`: a map that agrees on `h.root` agrees with `lift_hom` everywhere. -/
+/-- Unicity of `liftHom`: a map that agrees on `h.root` agrees with `liftHom` everywhere. -/
theorem eq_liftHom (h : IsAdjoinRoot S f) (g : S →ₐ[R] T) (hroot : g h.root = x) :
g = h.liftHom x hx' :=
AlgHom.ext (h.apply_eq_lift hx' g g.commutes hroot)
@@ -408,10 +408,6 @@ theorem modByMonicHom_root (h : IsAdjoinRootMonic S f) (hdeg : 1 < natDegree f)
h.modByMonicHom h.root = X := by simpa using modByMonicHom_root_pow h hdeg
#align is_adjoin_root_monic.mod_by_monic_hom_root IsAdjoinRootMonic.modByMonicHom_root
--- example (a b n : ℕ) (ha : a < n) (hb : b < n) (h : (a : Fin n) = (b : Fin n)) : a = b := by
-
-
-
/-- The basis on `S` generated by powers of `h.root`.
Auxiliary definition for `IsAdjoinRootMonic.powerBasis`. -/
@@ -643,8 +639,7 @@ This is the converse of `IsAdjoinRoot.ofEquiv`: this turns an `IsAdjoinRoot` int
`AlgEquiv`, and `IsAdjoinRoot.ofEquiv` turns an `AlgEquiv` into an `IsAdjoinRoot`.
-/
def aequiv (h : IsAdjoinRoot S f) (h' : IsAdjoinRoot T f) : S ≃ₐ[R] T :=
- { h.liftHom h'.root
- h'.aeval_root with
+ { h.liftHom h'.root h'.aeval_root with
toFun := h.liftHom h'.root h'.aeval_root
invFun := h'.liftHom h.root h.aeval_root
left_inv := fun x => by rw [← h.map_repr x, liftHom_map, aeval_eq, liftHom_map, aeval_eq]
@@ -763,8 +763,8 @@ theorem Algebra.adjoin.powerBasis'_minpoly_gen [IsDomain R] [IsDomain S] [NoZero
haveI :=
noZeroSMulDivisors_of_prime_of_degree_ne_zero (prime_of_isIntegrallyClosed hx')
(ne_of_lt (degree_pos hx')).symm
- rw [← minpolyGen_eq, adjoin.powerBasis', minpolyGen_map, minpolyGen_eq, powerBasis'_gen,
- ← isAdjoinRootMonic_root_eq_root _ (monic hx'), minpoly_eq]
+ rw [← minpolyGen_eq, adjoin.powerBasis', minpolyGen_map, minpolyGen_eq,
+ AdjoinRoot.powerBasis'_gen, ← isAdjoinRootMonic_root_eq_root _ (monic hx'), minpoly_eq]
exact irreducible hx'
#align algebra.adjoin.power_basis'_minpoly_gen Algebra.adjoin.powerBasis'_minpoly_gen
The unported dependencies are