Zulip Chat Archive

Stream: mathlib4

Topic: !4#5424 FieldTheory.AbelRuffini


Jeremy Tan (Jun 24 2023 at 05:58):

!4#5424 There seems to be some sort of diamond issue in a rewrite in induction2:

theorem induction2 {α β γ : solvableByRad F E} ( : γ  Fα, β) ( : P α) ( : P β) : P γ := by
  let p := minpoly F α
  let q := minpoly F β
  have hpq := Polynomial.splits_of_splits_mul _
    (mul_ne_zero (minpoly.ne_zero (isIntegral α)) (minpoly.ne_zero (isIntegral β)))
    (SplittingField.splits (p * q))
  let f : Fα, β →ₐ[F] (p * q).SplittingField := Classical.choice <| algHom_mk_adjoin_splits (by
    intro x hx
    cases' hx with hx hx
    rw [hx]
    exact isIntegral α, hpq.1
    cases hx
    exact isIntegral β, hpq.2⟩)
  have key : minpoly F γ = minpoly F (f γ, ⟩) := by
    refine' minpoly.eq_of_irreducible_of_monic
      (minpoly.irreducible (isIntegral γ)) _ (minpoly.monic (isIntegral γ))
    suffices aeval (⟨γ,  : Fα, β) (minpoly F γ) = 0 by
      rw [aeval_algHom_apply, this, AlgHom.map_zero]
    -- Porting note: this instance is needed for the following `apply`
    haveI := @IntermediateField.toAlgebra F (solvableByRad F E) _ _ _ Fα, β
      (solvableByRad F E) _ (Algebra.id (solvableByRad F E))
    apply (algebraMap (Fα, β) (solvableByRad F E)).injective
    haveI alge := Algebra.id (solvableByRad F E)
    haveI modu := alge.toModule
    haveI ist := Fα, β⟯.isScalarTower_mid'
    rw [RingHom.map_zero]
    rw [ @aeval_algebraMap_apply _ _ _ _ _ _ _ _ _ ist] -- here
    exact minpoly.aeval F γ
  rw [P, key]
  refine' gal_isSolvable_of_splits Normal.splits _ (f γ, ⟩)⟩ (gal_mul_isSolvable  )
  apply SplittingField.instNormal

The error is

application type mismatch
  @aeval_algebraMap_apply F { x // x  Fα, β } { x // x  solvableByRad F E } Semifield.toCommSemiring
    (Subalgebra.toCommSemiring Fα, β⟯.toSubalgebra) (Subalgebra.toSemiring (solvableByRad F E).toSubalgebra)
    (algebra Fα, β) this (algebra (solvableByRad F E)) ist
argument
  ist
has type
  @IsScalarTower F { x // x  Fα, β } { x // x  solvableByRad F E } Algebra.toSMul
    (Subalgebra.instSMulSubtypeMemSubalgebraInstMembershipInstSetLikeSubalgebra Fα, β⟯.toSubalgebra)
    Algebra.toSMul : Prop
but is expected to have type
  @IsScalarTower F { x // x  Fα, β } { x // x  solvableByRad F E } Algebra.toSMul Algebra.toSMul
    Algebra.toSMul : Prop

How can I get the hidden arguments to line up? (note that in mathlib3 ist could be synthed perfectly and it was just rw [← aeval_algebraMap_apply]

Jeremy Tan (Jun 24 2023 at 06:03):

Also the last exact minpoly.aeval F γ can't close the goal

Riccardo Brasca (Jun 24 2023 at 09:18):

Having a look

Riccardo Brasca (Jun 24 2023 at 09:36):

It's fixed.

Riccardo Brasca (Jun 24 2023 at 09:40):

The problem with exact minpoly.aeval F γ is that the goal is

(aeval { val := γ, property :=  }) (minpoly F γ) = 0

so you are evaluating the minimal polynomial of γ not exactly at γ, but at γ as an element of F⟮α, β⟯, that is a subtype of the type of γ. Of course evaluating a polynomial commutes with the coercion to the original type, and this is what docs#Polynomial.aeval_subalgebra_coe says.


Last updated: Dec 20 2023 at 11:08 UTC