[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
X Y : J
f : X ⟶ Y
⊢ ((Functor.const J).obj (of ↑{u | ∀ {i j : J} (f : i ⟶ j), ↑(F.map f) (u i) = u j})).map f ≫
      (fun j => ContinuousMap.mk fun u => ↑u j) Y =
    (fun j => ContinuousMap.mk fun u => ↑u j) X ≫ F.map f
[PROOFSTEP]
dsimp
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
X Y : J
f : X ⟶ Y
⊢ (𝟙 (of { x // ∀ {i j : J} (f : i ⟶ j), ↑(F.map f) (x i) = x j }) ≫ ContinuousMap.mk fun u => ↑u Y) =
    (ContinuousMap.mk fun u => ↑u X) ≫ F.map f
[PROOFSTEP]
rw [Category.id_comp]
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
X Y : J
f : X ⟶ Y
⊢ (ContinuousMap.mk fun u => ↑u Y) = (ContinuousMap.mk fun u => ↑u X) ≫ F.map f
[PROOFSTEP]
apply ContinuousMap.ext
[GOAL]
case h
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
X Y : J
f : X ⟶ Y
⊢ ∀ (a : { x // ∀ {i j : J} (f : i ⟶ j), ↑(F.map f) (x i) = x j }),
    ↑(ContinuousMap.mk fun u => ↑u Y) a = ↑((ContinuousMap.mk fun u => ↑u X) ≫ F.map f) a
[PROOFSTEP]
intro a
[GOAL]
case h
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
X Y : J
f : X ⟶ Y
a : { x // ∀ {i j : J} (f : i ⟶ j), ↑(F.map f) (x i) = x j }
⊢ ↑(ContinuousMap.mk fun u => ↑u Y) a = ↑((ContinuousMap.mk fun u => ↑u X) ≫ F.map f) a
[PROOFSTEP]
exact (a.2 f).symm
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
x : ↑S.pt
i✝ j✝ : J
f : i✝ ⟶ j✝
⊢ ↑(F.map f) ((fun j => ↑(NatTrans.app S.π j) x) i✝) = (fun j => ↑(NatTrans.app S.π j) x) j✝
[PROOFSTEP]
dsimp
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
x : ↑S.pt
i✝ j✝ : J
f : i✝ ⟶ j✝
⊢ ↑(F.map f) (↑(NatTrans.app S.π i✝) x) = ↑(NatTrans.app S.π j✝) x
[PROOFSTEP]
erw [← S.w f]
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
x : ↑S.pt
i✝ j✝ : J
f : i✝ ⟶ j✝
⊢ ↑(F.map f) (↑(NatTrans.app S.π i✝) x) = ↑(NatTrans.app S.π i✝ ≫ F.map f) x
[PROOFSTEP]
rfl
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
x : ↑S.pt
i j : J
f : i ⟶ j
⊢ ↑(F.map f) ((fun j => ↑(NatTrans.app S.π j) x) i) = (fun j => ↑(NatTrans.app S.π j) x) j
[PROOFSTEP]
dsimp
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
x : ↑S.pt
i j : J
f : i ⟶ j
⊢ ↑(F.map f) (↑(NatTrans.app S.π i) x) = ↑(NatTrans.app S.π j) x
[PROOFSTEP]
rw [← S.w f]
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
x : ↑S.pt
i j : J
f : i ⟶ j
⊢ ↑(F.map f) (↑(NatTrans.app S.π i) x) = ↑(NatTrans.app S.π i ≫ F.map f) x
[PROOFSTEP]
rfl
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
m : S.pt ⟶ (limitCone F).pt
h : ∀ (j : J), m ≫ NatTrans.app (limitCone F).π j = NatTrans.app S.π j
⊢ m =
    (fun S =>
        ContinuousMap.mk fun x =>
          { val := fun j => ↑(NatTrans.app S.π j) x,
            property :=
              (_ :
                ∀ {i j : J} (f : i ⟶ j),
                  ↑(F.map f) ((fun j => ↑(NatTrans.app S.π j) x) i) = (fun j => ↑(NatTrans.app S.π j) x) j) })
      S
[PROOFSTEP]
apply ContinuousMap.ext
[GOAL]
case h
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
m : S.pt ⟶ (limitCone F).pt
h : ∀ (j : J), m ≫ NatTrans.app (limitCone F).π j = NatTrans.app S.π j
⊢ ∀ (a : ↑S.pt),
    ↑m a =
      ↑((fun S =>
              ContinuousMap.mk fun x =>
                { val := fun j => ↑(NatTrans.app S.π j) x,
                  property :=
                    (_ :
                      ∀ {i j : J} (f : i ⟶ j),
                        ↑(F.map f) ((fun j => ↑(NatTrans.app S.π j) x) i) = (fun j => ↑(NatTrans.app S.π j) x) j) })
            S)
        a
[PROOFSTEP]
intros a
[GOAL]
case h
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
m : S.pt ⟶ (limitCone F).pt
h : ∀ (j : J), m ≫ NatTrans.app (limitCone F).π j = NatTrans.app S.π j
a : ↑S.pt
⊢ ↑m a =
    ↑((fun S =>
            ContinuousMap.mk fun x =>
              { val := fun j => ↑(NatTrans.app S.π j) x,
                property :=
                  (_ :
                    ∀ {i j : J} (f : i ⟶ j),
                      ↑(F.map f) ((fun j => ↑(NatTrans.app S.π j) x) i) = (fun j => ↑(NatTrans.app S.π j) x) j) })
          S)
      a
[PROOFSTEP]
apply Subtype.ext
[GOAL]
case h.a
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
m : S.pt ⟶ (limitCone F).pt
h : ∀ (j : J), m ≫ NatTrans.app (limitCone F).π j = NatTrans.app S.π j
a : ↑S.pt
⊢ ↑(↑m a) =
    ↑(↑((fun S =>
              ContinuousMap.mk fun x =>
                { val := fun j => ↑(NatTrans.app S.π j) x,
                  property :=
                    (_ :
                      ∀ {i j : J} (f : i ⟶ j),
                        ↑(F.map f) ((fun j => ↑(NatTrans.app S.π j) x) i) = (fun j => ↑(NatTrans.app S.π j) x) j) })
            S)
        a)
[PROOFSTEP]
funext j
[GOAL]
case h.a.h
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
m : S.pt ⟶ (limitCone F).pt
h : ∀ (j : J), m ≫ NatTrans.app (limitCone F).π j = NatTrans.app S.π j
a : ↑S.pt
j : J
⊢ ↑(↑m a) j =
    ↑(↑((fun S =>
                ContinuousMap.mk fun x =>
                  { val := fun j => ↑(NatTrans.app S.π j) x,
                    property :=
                      (_ :
                        ∀ {i j : J} (f : i ⟶ j),
                          ↑(F.map f) ((fun j => ↑(NatTrans.app S.π j) x) i) = (fun j => ↑(NatTrans.app S.π j) x) j) })
              S)
          a)
      j
[PROOFSTEP]
dsimp
[GOAL]
case h.a.h
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
m : S.pt ⟶ (limitCone F).pt
h : ∀ (j : J), m ≫ NatTrans.app (limitCone F).π j = NatTrans.app S.π j
a : ↑S.pt
j : J
⊢ ↑(↑m a) j = ↑(NatTrans.app S.π j) a
[PROOFSTEP]
rw [← h]
[GOAL]
case h.a.h
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
S : Cone F
m : S.pt ⟶ (limitCone F).pt
h : ∀ (j : J), m ≫ NatTrans.app (limitCone F).π j = NatTrans.app S.π j
a : ↑S.pt
j : J
⊢ ↑(↑m a) j = ↑(m ≫ NatTrans.app (limitCone F).π j) a
[PROOFSTEP]
rfl
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
⊢ IsLimit (limitConeInfi F)
[PROOFSTEP]
refine
  IsLimit.ofFaithful forget
    (Types.limitConeIsLimit.{v, u} (F ⋙ forget))
      -- Porting note: previously could infer all ?_ except continuity
    (fun s => ⟨fun v => ⟨fun j => (Functor.mapCone forget s).π.app j v, ?_⟩, ?_⟩) fun s => ?_
[GOAL]
case refine_1
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cone F
v : ↑s.pt
⊢ (fun j => NatTrans.app (forget.mapCone s).π j v) ∈ Functor.sections (F ⋙ forget)
[PROOFSTEP]
dsimp [Functor.sections]
[GOAL]
case refine_1
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cone F
v : ↑s.pt
⊢ ∀ {j j' : J} (f : j ⟶ j'),
    forget.map (F.map f) (forget.map (NatTrans.app s.π j) v) = forget.map (NatTrans.app s.π j') v
[PROOFSTEP]
intro _ _ _
[GOAL]
case refine_1
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cone F
v : ↑s.pt
j✝ j'✝ : J
f✝ : j✝ ⟶ j'✝
⊢ forget.map (F.map f✝) (forget.map (NatTrans.app s.π j✝) v) = forget.map (NatTrans.app s.π j'✝) v
[PROOFSTEP]
rw [← comp_apply', forget_map_eq_coe, ← s.π.naturality, forget_map_eq_coe]
[GOAL]
case refine_1
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cone F
v : ↑s.pt
j✝ j'✝ : J
f✝ : j✝ ⟶ j'✝
⊢ ↑(((Functor.const J).obj s.pt).map f✝ ≫ NatTrans.app s.π j'✝) v = ↑(NatTrans.app s.π j'✝) v
[PROOFSTEP]
dsimp
[GOAL]
case refine_1
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cone F
v : ↑s.pt
j✝ j'✝ : J
f✝ : j✝ ⟶ j'✝
⊢ ↑(𝟙 s.pt ≫ NatTrans.app s.π j'✝) v = ↑(NatTrans.app s.π j'✝) v
[PROOFSTEP]
rw [Category.id_comp]
[GOAL]
case refine_2
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cone F
⊢ Continuous fun v =>
    { val := fun j => NatTrans.app (forget.mapCone s).π j v,
      property := (_ : (fun j => NatTrans.app (forget.mapCone s).π j v) ∈ Functor.sections (F ⋙ forget)) }
[PROOFSTEP]
exact
  continuous_iff_coinduced_le.mpr
    (le_iInf fun j => coinduced_le_iff_le_induced.mp <| (continuous_iff_coinduced_le.mp (s.π.app j).continuous : _))
[GOAL]
case refine_3
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cone F
⊢ forget.map
      ((fun s =>
          ContinuousMap.mk fun v =>
            { val := fun j => NatTrans.app (forget.mapCone s).π j v,
              property := (_ : (fun j => NatTrans.app (forget.mapCone s).π j v) ∈ Functor.sections (F ⋙ forget)) })
        s) =
    IsLimit.lift (Types.limitConeIsLimit (F ⋙ forget)) (forget.mapCone s)
[PROOFSTEP]
rfl
[GOAL]
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
⊢ IsColimit (colimitCocone F)
[PROOFSTEP]
refine
  IsColimit.ofFaithful forget (Types.colimitCoconeIsColimit _)
    (fun s =>
        -- Porting note: it appears notation for forget breaks dot notation (also above)
            -- Porting note: previously function was inferred
      ⟨Quot.lift (fun p => (Functor.mapCocone forget s).ι.app p.fst p.snd) ?_, ?_⟩)
    fun s => ?_
[GOAL]
case refine_1
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cocone F
⊢ ∀ (a b : (j : J) × (F ⋙ forget).obj j),
    Types.Quot.Rel (F ⋙ forget) a b →
      (fun p => NatTrans.app (forget.mapCocone s).ι p.fst p.snd) a =
        (fun p => NatTrans.app (forget.mapCocone s).ι p.fst p.snd) b
[PROOFSTEP]
intro _ _ ⟨_, h⟩
[GOAL]
case refine_1
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cocone F
a✝ b✝ : (j : J) × (F ⋙ forget).obj j
w✝ : a✝.fst ⟶ b✝.fst
h : b✝.snd = (F ⋙ forget).map w✝ a✝.snd
⊢ (fun p => NatTrans.app (forget.mapCocone s).ι p.fst p.snd) a✝ =
    (fun p => NatTrans.app (forget.mapCocone s).ι p.fst p.snd) b✝
[PROOFSTEP]
dsimp
[GOAL]
case refine_1
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cocone F
a✝ b✝ : (j : J) × (F ⋙ forget).obj j
w✝ : a✝.fst ⟶ b✝.fst
h : b✝.snd = (F ⋙ forget).map w✝ a✝.snd
⊢ forget.map (NatTrans.app s.ι a✝.fst) a✝.snd = forget.map (NatTrans.app s.ι b✝.fst) b✝.snd
[PROOFSTEP]
rw [h, Functor.comp_map, ← comp_apply', s.ι.naturality]
[GOAL]
case refine_1
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cocone F
a✝ b✝ : (j : J) × (F ⋙ forget).obj j
w✝ : a✝.fst ⟶ b✝.fst
h : b✝.snd = (F ⋙ forget).map w✝ a✝.snd
⊢ forget.map (NatTrans.app s.ι a✝.fst) a✝.snd =
    forget.map (NatTrans.app s.ι a✝.fst ≫ ((Functor.const J).obj s.pt).map w✝) a✝.snd
[PROOFSTEP]
dsimp
[GOAL]
case refine_1
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cocone F
a✝ b✝ : (j : J) × (F ⋙ forget).obj j
w✝ : a✝.fst ⟶ b✝.fst
h : b✝.snd = (F ⋙ forget).map w✝ a✝.snd
⊢ forget.map (NatTrans.app s.ι a✝.fst) a✝.snd = forget.map (NatTrans.app s.ι a✝.fst ≫ 𝟙 s.pt) a✝.snd
[PROOFSTEP]
rw [Category.comp_id]
[GOAL]
case refine_2
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cocone F
⊢ Continuous
    (Quot.lift (fun p => NatTrans.app (forget.mapCocone s).ι p.fst p.snd)
      (_ :
        ∀ (a b : (j : J) × (F ⋙ forget).obj j),
          Types.Quot.Rel (F ⋙ forget) a b →
            (fun p => NatTrans.app (forget.mapCocone s).ι p.fst p.snd) a =
              (fun p => NatTrans.app (forget.mapCocone s).ι p.fst p.snd) b))
[PROOFSTEP]
exact
  continuous_iff_le_induced.mpr
    (iSup_le fun j => coinduced_le_iff_le_induced.mp <| (continuous_iff_coinduced_le.mp (s.ι.app j).continuous : _))
[GOAL]
case refine_3
J : Type v
inst✝ : SmallCategory J
F : J ⥤ TopCatMax
s : Cocone F
⊢ forget.map
      ((fun s =>
          ContinuousMap.mk
            (Quot.lift (fun p => NatTrans.app (forget.mapCocone s).ι p.fst p.snd)
              (_ :
                ∀ (a b : (j : J) × (F ⋙ forget).obj j),
                  Types.Quot.Rel (F ⋙ forget) a b →
                    (fun p => NatTrans.app (forget.mapCocone s).ι p.fst p.snd) a =
                      (fun p => NatTrans.app (forget.mapCocone s).ι p.fst p.snd) b)))
        s) =
    IsColimit.desc (Types.colimitCoconeIsColimit (F ⋙ forget)) (forget.mapCocone s)
[PROOFSTEP]
rfl
[GOAL]
J : Type v
inst✝ : SmallCategory J
X : TopCat
⊢ Continuous fun x => PUnit.unit
[PROOFSTEP]
continuity
[GOAL]
J : Type v
inst✝ : SmallCategory J
X : TopCat
f : X ⟶ of PUnit
⊢ f = default
[PROOFSTEP]
ext
[GOAL]
case w
J : Type v
inst✝ : SmallCategory J
X : TopCat
f : X ⟶ of PUnit
x✝ : forget.obj X
⊢ ↑f x✝ = ↑default x✝
[PROOFSTEP]
aesop
[GOAL]
J : Type v
inst✝ : SmallCategory J
X : TopCat
⊢ Continuous fun x => PEmpty.elim x
[PROOFSTEP]
continuity
[GOAL]
J : Type v
inst✝ : SmallCategory J
X : TopCat
f : of PEmpty ⟶ X
⊢ f = default
[PROOFSTEP]
ext ⟨⟩


[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
⊢ ↑(aeval f) (charpoly f) = 0
[PROOFSTEP]
apply (LinearEquiv.map_eq_zero_iff (algEquivMatrix (chooseBasis R M)).toLinearEquiv).1
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
⊢ ↑(AlgEquiv.toLinearEquiv (algEquivMatrix (chooseBasis R M))) (↑(aeval f) (charpoly f)) = 0
[PROOFSTEP]
rw [AlgEquiv.toLinearEquiv_apply, ← AlgEquiv.coe_algHom, ← Polynomial.aeval_algHom_apply _ _ _, charpoly_def]
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
⊢ ↑(aeval (↑↑(algEquivMatrix (chooseBasis R M)) f))
      (Matrix.charpoly (↑(toMatrix (chooseBasis R M) (chooseBasis R M)) f)) =
    0
[PROOFSTEP]
exact Matrix.aeval_self_charpoly _
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
k : ℕ
⊢ f ^ k = ↑(aeval f) (X ^ k %ₘ charpoly f)
[PROOFSTEP]
rw [← aeval_eq_aeval_mod_charpoly, map_pow, aeval_X]
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
⊢ coeff (minpoly R f) 0 ≠ 0
[PROOFSTEP]
intro h
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
⊢ False
[PROOFSTEP]
obtain ⟨P, hP⟩ := X_dvd_iff.2 h
[GOAL]
case intro
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
⊢ False
[PROOFSTEP]
have hdegP : P.degree < (minpoly R f).degree := by
  rw [hP, mul_comm]
  refine' degree_lt_degree_mul_X fun h => _
  rw [h, mul_zero] at hP
  exact minpoly.ne_zero (isIntegral f) hP
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
⊢ degree P < degree (minpoly R f)
[PROOFSTEP]
rw [hP, mul_comm]
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
⊢ degree P < degree (P * X)
[PROOFSTEP]
refine' degree_lt_degree_mul_X fun h => _
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h✝ : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
h : P = 0
⊢ False
[PROOFSTEP]
rw [h, mul_zero] at hP
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h✝ : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = 0
h : P = 0
⊢ False
[PROOFSTEP]
exact minpoly.ne_zero (isIntegral f) hP
[GOAL]
case intro
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
hdegP : degree P < degree (minpoly R f)
⊢ False
[PROOFSTEP]
have hPmonic : P.Monic :=
  by
  suffices (minpoly R f).Monic by rwa [Monic.def, hP, mul_comm, leadingCoeff_mul_X, ← Monic.def] at this
  exact minpoly.monic (isIntegral f)
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
hdegP : degree P < degree (minpoly R f)
⊢ Monic P
[PROOFSTEP]
suffices (minpoly R f).Monic by rwa [Monic.def, hP, mul_comm, leadingCoeff_mul_X, ← Monic.def] at this
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
hdegP : degree P < degree (minpoly R f)
this : Monic (minpoly R f)
⊢ Monic P
[PROOFSTEP]
rwa [Monic.def, hP, mul_comm, leadingCoeff_mul_X, ← Monic.def] at this
[GOAL]
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
hdegP : degree P < degree (minpoly R f)
⊢ Monic (minpoly R f)
[PROOFSTEP]
exact minpoly.monic (isIntegral f)
[GOAL]
case intro
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
hdegP : degree P < degree (minpoly R f)
hPmonic : Monic P
⊢ False
[PROOFSTEP]
have hzero : aeval f (minpoly R f) = 0 := minpoly.aeval _ _
[GOAL]
case intro
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
hdegP : degree P < degree (minpoly R f)
hPmonic : Monic P
hzero : ↑(aeval f) (minpoly R f) = 0
⊢ False
[PROOFSTEP]
simp only [hP, mul_eq_comp, ext_iff, hf, aeval_X, map_eq_zero_iff, coe_comp, AlgHom.map_mul, zero_apply,
  Function.comp_apply] at hzero
[GOAL]
case intro
R : Type u
M : Type v
inst✝⁵ : CommRing R
inst✝⁴ : Nontrivial R
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : Module.Free R M
inst✝ : Module.Finite R M
f : M →ₗ[R] M
hf : Function.Injective ↑f
h : coeff (minpoly R f) 0 = 0
P : R[X]
hP : minpoly R f = X * P
hdegP : degree P < degree (minpoly R f)
hPmonic : Monic P
hzero : ∀ (x : M), ↑(↑(aeval f) P) x = 0
⊢ False
[PROOFSTEP]
exact not_le.2 hdegP (minpoly.min _ _ hPmonic (ext hzero))