Skip to content

[Merged by Bors] - feat(RingTheory/Polynomial/Eisenstein/Generalized): a generalized version of the Eisenstein criterion - #23710

Closed
AntoineChambert-Loir wants to merge 34 commits into
masterfrom
ACL/Eisenstein
Closed

AntoineChambert-Loir wants to merge 34 commits into
masterfrom
ACL/Eisenstein

Conversation

@AntoineChambert-Loir

@AntoineChambert-Loir AntoineChambert-Loir commented Apr 5, 2025 •

Copy link
Copy Markdown
Collaborator

A generalized form of the Eisenstein criterion

Let R be an integral domain, P a prime ideal of R and
let K be the field of fractions o f R ⧸ P.
Let q : R[X] be a monic polynomial which is irreducible in K[X].
Let f : R[X] be a monic polynomial of strictly positive degree
whose image in K[X] is a power of q.
Assume moreover that f.modByMonic q is not zero in (R ⧸ (P ^ 2))[X].
Then f is irreducible.

The Eisenstein criterion is the particular case where q := X.

The case of a polynomial q := X - a is interesting,
then the mod P ^ 2 hypothesis can rephrased as saying
that f.derivative.eval a ∉ P ^ 2. (TODO)
The case of cyclotomic polynomials of prime index can be proved directly using that, with a = 1.

We give a (possibly non convincing) application to the irreducibility
of the polynomial X ^ 4 - 10 * X + 1 in ℤ[X].
One argues modulo 3, with q := X ^ 2 + 1.

Remark

The result can also be generalized to the case where
the leading coefficients of f and q do not belong to P.
(By localization at P, make these coefficients invertible.)
There are two obstructions, though :

  • Usually, one will only obtain irreducibility in F[X], where F is the field
    of fractions of R. (If R is a UFD, this will be close to what is wanted,
    but not in general.)

  • The mod P ^ 2 hypothesis will have to be rephrased to a condition
    in the second symbolic power of P. When P is a maximal ideal,
    that symbolic power coincides with P ^ 2, but not in general.


Open in Gitpod

@AntoineChambert-Loir AntoineChambert-Loir added the WIP Work in progress label Apr 5, 2025
@AntoineChambert-Loir AntoineChambert-Loir changed the title feat(RingTheory/Eisenstein/Generalized): a generalized version of the Eisenstein criterion feat(RingTheory/Polynomial/Eisenstein/Generalized): a generalized version of the Eisenstein criterion Apr 5, 2025
@github-actions github-actions Bot added the t-algebra Algebra (groups, rings, fields, etc) label Apr 5, 2025
@github-actions

github-actions Bot commented Apr 5, 2025 •

Copy link
Copy Markdown

PR summary bdc67055a9

Import changes exceeding 2%

% File
+6.31% Mathlib.Algebra.Polynomial.SpecificDegree

Import changes for modified files

Dependency changes

File Base Count Head Count Change
Mathlib.Algebra.Polynomial.SpecificDegree 1125 1196 +71 (+6.31%)
Mathlib.Algebra.Polynomial.Coeff 906 910 +4 (+0.44%)
Import changes for all files
Files Import difference
50 files Mathlib.Algebra.Colimit.Ring Mathlib.Algebra.CubicDiscriminant Mathlib.Algebra.FreeAlgebra.Cardinality Mathlib.Algebra.MvPolynomial.SchwartzZippel Mathlib.Algebra.Polynomial.CoeffMem Mathlib.Algebra.Polynomial.Degree.CardPowDegree Mathlib.Algebra.Polynomial.Derivation Mathlib.Algebra.Polynomial.Div Mathlib.Algebra.Polynomial.FieldDivision Mathlib.Algebra.Polynomial.GroupRingAction Mathlib.Algebra.Polynomial.Laurent Mathlib.Algebra.Polynomial.Module.AEval Mathlib.Algebra.Polynomial.Module.Basic Mathlib.Algebra.Polynomial.PartialFractions Mathlib.Algebra.Polynomial.RingDivision Mathlib.Algebra.Polynomial.Roots Mathlib.Algebra.Polynomial.Splits Mathlib.Combinatorics.Nullstellensatz Mathlib.Dynamics.Newton Mathlib.FieldTheory.RatFunc.Basic Mathlib.ModelTheory.Algebra.Ring.FreeCommRing Mathlib.NumberTheory.FLT.MasonStothers Mathlib.RingTheory.Algebraic.Cardinality Mathlib.RingTheory.Artinian.Instances Mathlib.RingTheory.Bialgebra.MonoidAlgebra Mathlib.RingTheory.Coalgebra.MonoidAlgebra Mathlib.RingTheory.Derivation.Lie Mathlib.RingTheory.Derivation.ToSquareZero Mathlib.RingTheory.EisensteinCriterion Mathlib.RingTheory.FreeCommRing Mathlib.RingTheory.HopfAlgebra.MonoidAlgebra Mathlib.RingTheory.Localization.Algebra Mathlib.RingTheory.Localization.Finiteness Mathlib.RingTheory.MvPolynomial.EulerIdentity Mathlib.RingTheory.MvPolynomial.FreeCommRing Mathlib.RingTheory.MvPolynomial.Groebner Mathlib.RingTheory.MvPolynomial.Homogeneous Mathlib.RingTheory.MvPolynomial.Localization Mathlib.RingTheory.MvPolynomial.MonomialOrder.DegLex Mathlib.RingTheory.MvPolynomial.MonomialOrder Mathlib.RingTheory.Polynomial.Content Mathlib.RingTheory.Polynomial.Eisenstein.Basic Mathlib.RingTheory.Polynomial.Ideal Mathlib.RingTheory.Polynomial.IrreducibleRing Mathlib.RingTheory.Polynomial.Nilpotent Mathlib.RingTheory.Polynomial.Radical Mathlib.RingTheory.Polynomial.SmallDegreeVieta Mathlib.RingTheory.Polynomial.Vieta Mathlib.RingTheory.Support Mathlib.SetTheory.Cardinal.Free
2
43 files Mathlib.Algebra.MvPolynomial.Cardinal Mathlib.Algebra.MvPolynomial.Derivation Mathlib.Algebra.MvPolynomial.Equiv Mathlib.Algebra.MvPolynomial.PDeriv Mathlib.Algebra.MvPolynomial.Polynomial Mathlib.Algebra.Polynomial.AlgebraMap Mathlib.Algebra.Polynomial.BigOperators Mathlib.Algebra.Polynomial.CancelLeads Mathlib.Algebra.Polynomial.CoeffList Mathlib.Algebra.Polynomial.Degree.Lemmas Mathlib.Algebra.Polynomial.DenomsClearable Mathlib.Algebra.Polynomial.EraseLead Mathlib.Algebra.Polynomial.Eval.Degree Mathlib.Algebra.Polynomial.Eval.Irreducible Mathlib.Algebra.Polynomial.Inductions Mathlib.Algebra.Polynomial.Lifts Mathlib.Algebra.Polynomial.Mirror Mathlib.Algebra.Polynomial.Monic Mathlib.Algebra.Polynomial.Reverse Mathlib.Algebra.Polynomial.Sequence Mathlib.Algebra.Polynomial.Smeval Mathlib.Algebra.Polynomial.SumIteratedDerivative Mathlib.Algebra.Polynomial.UnitTrinomial Mathlib.Algebra.Polynomial.ofFn Mathlib.Algebra.Ring.Subring.IntPolynomial Mathlib.Analysis.Polynomial.CauchyBound Mathlib.FieldTheory.IntermediateField.Adjoin.Defs Mathlib.FieldTheory.IntermediateField.Basic Mathlib.FieldTheory.RatFunc.Defs Mathlib.RingTheory.Adjoin.Polynomial Mathlib.RingTheory.Algebraic.Defs Mathlib.RingTheory.Algebraic.LinearIndependent Mathlib.RingTheory.Algebraic.Pi Mathlib.RingTheory.Derivation.Basic Mathlib.RingTheory.Derivation.DifferentialRing Mathlib.RingTheory.Polynomial.IntegralNormalization Mathlib.RingTheory.Polynomial.ScaleRoots Mathlib.RingTheory.Polynomial.Tower Mathlib.RingTheory.Polynomial.Wronskian Mathlib.RingTheory.PolynomialAlgebra Mathlib.RingTheory.TensorProduct.MvPolynomial Mathlib.Tactic.ComputeDegree Mathlib.Topology.Algebra.IntermediateField
3
15 files Mathlib.Algebra.Polynomial.Coeff Mathlib.Algebra.Polynomial.Degree.Domain Mathlib.Algebra.Polynomial.Degree.Operations Mathlib.Algebra.Polynomial.Degree.SmallDegree Mathlib.Algebra.Polynomial.Degree.Support Mathlib.Algebra.Polynomial.Degree.TrailingDegree Mathlib.Algebra.Polynomial.Degree.Units Mathlib.Algebra.Polynomial.Derivative Mathlib.Algebra.Polynomial.Eval.Coeff Mathlib.Algebra.Polynomial.Eval.SMul Mathlib.Algebra.Polynomial.Eval.Subring Mathlib.Algebra.Polynomial.Identities Mathlib.Data.Nat.Choose.Vandermonde Mathlib.RingTheory.Polynomial.Hermite.Basic Mathlib.RingTheory.Polynomial.Opposites
4
Mathlib.Algebra.Polynomial.SpecificDegree 71
Mathlib.RingTheory.Polynomial.Eisenstein.Generalized (new file) 1201

Declarations diff

+ IsPrime.mul_not_mem
+ _root_.CharP.ofNat_eq_zero'
+ charP
+ generalizedEisenstein
+ irreducible_of_degree_le_three_of_not_isRoot
+ ker_intAlgebraMap_eq_span

You can run this locally as follows
## summary with just the declaration names:
./scripts/declarations_diff.sh <optional_commit>

## more verbose report:
./scripts/declarations_diff.sh long <optional_commit>

The doc-module for script/declarations_diff.sh contains some details about this script.


No changes to technical debt.

You can run this locally as

./scripts/technical-debt-metrics.sh pr_summary
  • The relative value is the weighted sum of the differences with weight given by the inverse of the current value of the statistic.
  • The absolute value is the relative value divided by the total sum of the inverses of the current values (i.e. the weighted average of the differences).

@AntoineChambert-Loir AntoineChambert-Loir added t-number-theory Number theory (also use t-algebra or t-analysis to specialize) and removed WIP Work in progress labels Apr 6, 2025

@riccardobrasca riccardobrasca left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have a bunch of Polynomial.foo that can be just foo.

@faenuccio faenuccio left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice 😄

@AntoineChambert-Loir

Copy link
Copy Markdown
Collaborator Author

shake is very strange here, it asks me to remove almost all imports, but nothing works anymore if I delete any of them.

@adomani adomani left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems that most of the difficulty in the explicit example is due to having let declarations for the polynomials that compute_degree does not unfold.

Maybe there could be a flag for using unfolds profusely in compute_degree?

@AntoineChambert-Loir

Copy link
Copy Markdown
Collaborator Author

Maybe tactics could be provided some stuff that they are allowed to unfold.
Or, in a different way, compute_degree! [q] would compute the degree of q and rewrite it.

@AntoineChambert-Loir

Copy link
Copy Markdown
Collaborator Author

I will generalize to IsDomain R…

@AntoineChambert-Loir

Copy link
Copy Markdown
Collaborator Author

(I failed to generalizing to IsDomain R)

@jcommelin jcommelin left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

bors d+

@mathlib-bors

mathlib-bors Bot commented Apr 11, 2025

Copy link
Copy Markdown
Contributor

✌️ AntoineChambert-Loir can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.

@ghost ghost added the delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). label Apr 11, 2025

@jcommelin jcommelin left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two more minigolfs

@AntoineChambert-Loir

Copy link
Copy Markdown
Collaborator Author

Before I bors this, I have a question: I had not realized that the classic Eisenstein criterion is in Mathlib.RingTheory.EisensteinCriterion. I would suggest that the content of this PR goes to that file as well and that I use the general criterion to prove the classical one—as is done in Archive.Examples.Eisenstein.

@AntoineChambert-Loir

Copy link
Copy Markdown
Collaborator Author

And in fact, that should probably be Mathlib.RingTheory.Polynomial.Eisenstein.Criterion.

@riccardobrasca

Copy link
Copy Markdown
Member

Does this change the import tree a lot?

@AntoineChambert-Loir

Copy link
Copy Markdown
Collaborator Author

probably not, because the file about the criterion is only imported by Eisenstein.Basic and AbelRuffini.

@AntoineChambert-Loir

Copy link
Copy Markdown
Collaborator Author

Maybe I can try that in a second PR.

@riccardobrasca

Copy link
Copy Markdown
Member

Yes, it's probably a good idea to merge this and move stuff later.

@AntoineChambert-Loir

Copy link
Copy Markdown
Collaborator Author

bors r+

mathlib-bors Bot pushed a commit that referenced this pull request Apr 11, 2025
…sion of the Eisenstein criterion (#23710)

A generalized form of the Eisenstein criterion

  Let `R` be an integral domain, `P` a prime ideal of `R` and
  let `K` be the field of fractions o f `R ⧸ P`.
  Let `q : R[X]` be a monic polynomial which is irreducible in `K[X]`.
  Let `f : R[X]` be a monic polynomial of strictly positive degree
  whose image in `K[X]` is a power of `q`.
  Assume moreover that `f.modByMonic q` is not zero in `(R ⧸ (P ^ 2))[X]`.
  Then `f` is irreducible.

The Eisenstein criterion is the particular case where `q := X`.

The case of a polynomial `q := X - a` is interesting,
then the mod `P ^ 2` hypothesis can rephrased as saying
that `f.derivative.eval a ∉ P ^ 2`. (TODO)
The case of cyclotomic polynomials of prime index can be proved directly using that, with `a = 1`.

We give a (possibly non convincing) application to the irreducibility
of the polynomial `X ^ 4 - 10 * X + 1` in `ℤ[X]`.
One argues modulo 3, with `q := X ^ 2 + 1`.

## Remark

The result can also be generalized to the case where
the leading coefficients of `f` and `q` do not belong to `P`.
(By localization at `P`, make these coefficients invertible.)
There are two obstructions, though :

* Usually, one will only obtain irreducibility in `F[X]`, where `F` is the field
of fractions of `R`. (If `R` is a UFD, this will be close to what is wanted,
but not in general.)

* The mod `P ^ 2` hypothesis will have to be rephrased to a condition
in the second symbolic power of `P`. When `P` is a maximal ideal,
that symbolic power coincides with `P ^ 2`, but not in general.
@mathlib-bors

mathlib-bors Bot commented Apr 11, 2025

Copy link
Copy Markdown
Contributor

Build failed:

@jcommelin

Copy link
Copy Markdown
Member

probably not, because the file about the criterion is only imported by Eisenstein.Basic and AbelRuffini.

But we should also consider how many imports the "simple" criterion needs? Does the general version need more imports? Anyway, we can discuss that on the follow up PR.

@AntoineChambert-Loir

Copy link
Copy Markdown
Collaborator Author

bors r+

mathlib-bors Bot pushed a commit that referenced this pull request Apr 11, 2025
…sion of the Eisenstein criterion (#23710)

A generalized form of the Eisenstein criterion

  Let `R` be an integral domain, `P` a prime ideal of `R` and
  let `K` be the field of fractions o f `R ⧸ P`.
  Let `q : R[X]` be a monic polynomial which is irreducible in `K[X]`.
  Let `f : R[X]` be a monic polynomial of strictly positive degree
  whose image in `K[X]` is a power of `q`.
  Assume moreover that `f.modByMonic q` is not zero in `(R ⧸ (P ^ 2))[X]`.
  Then `f` is irreducible.

The Eisenstein criterion is the particular case where `q := X`.

The case of a polynomial `q := X - a` is interesting,
then the mod `P ^ 2` hypothesis can rephrased as saying
that `f.derivative.eval a ∉ P ^ 2`. (TODO)
The case of cyclotomic polynomials of prime index can be proved directly using that, with `a = 1`.

We give a (possibly non convincing) application to the irreducibility
of the polynomial `X ^ 4 - 10 * X + 1` in `ℤ[X]`.
One argues modulo 3, with `q := X ^ 2 + 1`.

## Remark

The result can also be generalized to the case where
the leading coefficients of `f` and `q` do not belong to `P`.
(By localization at `P`, make these coefficients invertible.)
There are two obstructions, though :

* Usually, one will only obtain irreducibility in `F[X]`, where `F` is the field
of fractions of `R`. (If `R` is a UFD, this will be close to what is wanted,
but not in general.)

* The mod `P ^ 2` hypothesis will have to be rephrased to a condition
in the second symbolic power of `P`. When `P` is a maximal ideal,
that symbolic power coincides with `P ^ 2`, but not in general.
@mathlib-bors

mathlib-bors Bot commented Apr 11, 2025

Copy link
Copy Markdown
Contributor

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors Bot changed the title feat(RingTheory/Polynomial/Eisenstein/Generalized): a generalized version of the Eisenstein criterion [Merged by Bors] - feat(RingTheory/Polynomial/Eisenstein/Generalized): a generalized version of the Eisenstein criterion Apr 11, 2025
@mathlib-bors mathlib-bors Bot closed this Apr 11, 2025
@mathlib-bors
mathlib-bors Bot deleted the ACL/Eisenstein branch April 11, 2025 13:07
tannerduve pushed a commit that referenced this pull request May 13, 2025
…sion of the Eisenstein criterion (#23710)

A generalized form of the Eisenstein criterion

  Let `R` be an integral domain, `P` a prime ideal of `R` and
  let `K` be the field of fractions o f `R ⧸ P`.
  Let `q : R[X]` be a monic polynomial which is irreducible in `K[X]`.
  Let `f : R[X]` be a monic polynomial of strictly positive degree
  whose image in `K[X]` is a power of `q`.
  Assume moreover that `f.modByMonic q` is not zero in `(R ⧸ (P ^ 2))[X]`.
  Then `f` is irreducible.

The Eisenstein criterion is the particular case where `q := X`.

The case of a polynomial `q := X - a` is interesting,
then the mod `P ^ 2` hypothesis can rephrased as saying
that `f.derivative.eval a ∉ P ^ 2`. (TODO)
The case of cyclotomic polynomials of prime index can be proved directly using that, with `a = 1`.

We give a (possibly non convincing) application to the irreducibility
of the polynomial `X ^ 4 - 10 * X + 1` in `ℤ[X]`.
One argues modulo 3, with `q := X ^ 2 + 1`.

## Remark

The result can also be generalized to the case where
the leading coefficients of `f` and `q` do not belong to `P`.
(By localization at `P`, make these coefficients invertible.)
There are two obstructions, though :

* Usually, one will only obtain irreducibility in `F[X]`, where `F` is the field
of fractions of `R`. (If `R` is a UFD, this will be close to what is wanted,
but not in general.)

* The mod `P ^ 2` hypothesis will have to be rephrased to a condition
in the second symbolic power of `P`. When `P` is a maximal ideal,
that symbolic power coincides with `P ^ 2`, but not in general.
grunweg added a commit that referenced this pull request May 14, 2025
grunweg added a commit that referenced this pull request May 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). large-import Automatically added label for PRs with a significant increase in transitive imports t-algebra Algebra (groups, rings, fields, etc) t-number-theory Number theory (also use t-algebra or t-analysis to specialize)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants