Skip to content

[Merged by Bors] - feat(Polynomial): polynomial sequences are bases for R[X] - #20846

Closed
Julian wants to merge 44 commits into
masterfrom
polynomial-sequences
Closed

[Merged by Bors] - feat(Polynomial): polynomial sequences are bases for R[X]#20846
Julian wants to merge 44 commits into
masterfrom
polynomial-sequences

Conversation

@Julian

@Julian Julian commented Jan 19, 2025

Copy link
Copy Markdown
Collaborator

We define polynomial sequences -- that is, sequences of polynomials where the ith polynomial has degree i.

We do not yet refactor any existing polynomial sequences to go via this proof (e.g. for the usual monomial basis which has its own proof already in Mathlib).

Co-authored-by: Aaron Hill aa1ronham@gmail.com
Co-authored-by: Julian Berman Julian@GrayVines.com
Co-authored-by: Matej Penciak matej.penciak@gmail.com
Co-authored-by: Austin Letson waustinletson@gmail.com


Open in Gitpod

@github-actions

github-actions Bot commented Jan 19, 2025

Copy link
Copy Markdown

PR summary 1f8bcb55bd

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference
Mathlib.Algebra.Polynomial.Sequence (new file) 1022

Declarations diff

+ Sequence
+ basis
+ basis_degree_strictMono
+ basis_eq_self
+ basis_natDegree_strictMono
+ coeFun
+ degree_eq
+ degree_smul_of_isRightRegular_leadingCoeff
+ degree_strictMono
+ linearIndependent
+ natDegree_eq
+ natDegree_strictMono
+ ne_zero
+ 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).

@github-actions github-actions Bot added the t-algebra Algebra (groups, rings, fields, etc) label Jan 19, 2025
Comment thread Mathlib/Algebra/Polynomial/Sequence.lean Outdated

@Ruben-VandeVelde Ruben-VandeVelde 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.

Thanks!

Comment thread Mathlib/Algebra/Polynomial/Degree/Operations.lean Outdated
Comment thread Mathlib/Algebra/Polynomial/Sequence.lean Outdated
Comment thread Mathlib/Algebra/Polynomial/Sequence.lean Outdated

/-- Polynomials in a polynomial sequence are linearly independent. -/
lemma linearIndependent [NoZeroDivisors R] :
LinearIndependent R S := linearIndependent_iff'.mpr <| fun s g eqzero i hi ↦ by

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.

This proof doesn't immediately generalize, but is this true over semirings?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I wasn't sure, and I saw lots of the linear independence API being generalized the last few weeks to Semirings. I'll look again to see if perhaps now I can find something that works.

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.

I discussed the question with a friend today and our conclusion is that this will only be true over semirings which have injective addition, i.e. a + b = a + c -> b = c (this would be AddCancelCommMonoid). Counter-example: if a + c = b + c but a ≠ b, you have a • 1 + c • (1 + X) = b • 1 + c • (1 + X) while a ≠ b. In the case of an AddCancelCommMonoid it will be true since the space of polynomials will also be an AddCancelCommMonoid. This in particular covers the case of . However I did not find a typeclass in Mathlib to talk about such semirings, so I would say that the way to go here is to write a TODO mentioning the missing typeclass (if it is missing, maybe it would be nice to open a Zulip thread to make sure).

Comment thread Mathlib/Algebra/Polynomial/Sequence.lean Outdated
Comment thread Mathlib/Algebra/Polynomial/Sequence.lean Outdated
Comment thread Mathlib/Algebra/Polynomial/Sequence.lean Outdated
@Ruben-VandeVelde Ruben-VandeVelde added the awaiting-author A reviewer has asked the author a question or requested changes. label Jan 20, 2025
Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com>
@Julian
Julian force-pushed the polynomial-sequences branch from 48fce04 to 0fc1a7d Compare January 20, 2025 21:56
* origin/master: (294 commits)
  feat: equalizers and coequalizers in the category of ind-objects (#21139)
  doc: turn more links to Stacks into `@[stacks]` tags (#21135)
  feat(Asymptotics): prove `IsLittleOTVS.add` (#20578)
  feat(Algebra/Polynomial): `Polynomial.aeval` for product algebras (#21062)
  chore: import Std in Mathlib.lean (#21126)
  feat(Data/Matroid/Circuit): fundamental circuits and extensionality  (#21145)
  feat(CategoryTheory/Endofunctor): prove the dual form of Lambek's Lemma on terminal coalgebra (#21140)
  feat(SetTheory/Game/PGame): rewrite left moves of `-x` as right moves of `x` under binders (#21109)
  feat(RingTheory/Localization/Pi): localization of a finite direct product is a product of localizations (#19042)
  doc: fixed notation error in customizing category composition (#21132)
  feat(Matrix): more lemmas for `PEquiv.toMatrix` (#21143)
  chore(SupIndep): speedup the `Decidable` instance (#21114)
  fix(CI): use `Elab.async=false` for late importers workflow (#21147)
  feat(Topology/Algebra/Indicator): indicator of a clopen is continuous (#20687)
  feat(Data/Matroid/Rank/Cardinal): Cardinality-valued rank function (#20921)
  feat(Algebra): `Pi.single_induction` (#21141)
  chore(BigOperators/Fin): golf a proof (#21131)
  feat: generalize tangent cone lemmas to TVS (#20859)
  feat(CategoryTheory): `Comma.snd L R` is final if `R` is final and domains are filtered (#21136)
  refactor: unapply matrix lemmas (#21091)
  chore(Algebra/Category): `erw` -> `rw` (#21130)
  feat(CategoryTheory): filteredness of Comma catgories given finality of one of the functors (#21128)
  feat(Algebra/Category): `ConcreteCategory` instance for `ModuleCat` (#21125)
  feat: PSum of finite sorts is finite (#20285)
  feat: inequality on the integral of a convex function of a RN derivative (#21093)
  feat: `(v +ᵥ s) -ᵥ (v +ᵥ t) = s -ᵥ t` (#21058)
  chore: rename the fact that `(∀ a < a₁, a ≤ a₂) ↔ a₁ ≤ a₂` in a dense order (#20317)
  feat: a `RelHom` preserves directedness (#20080)
  feat(Combinatorics/SimpleGraph): add definitions and theorems about the coloring of sum graphs (#18677)
  chore(Data/Matrix/PEquiv): clean up names (#21108)
  feat(Algebra/Category): `ConcreteCategory` instances for rings (#20815)
  feat: define Descriptive.Tree (#18763)
  chore(Data/Complex/Exponential): split trig functions to new file (#21075)
  feat(Logic/IsEmpty/Relator): empty on sides (#20319)
  feat(Algebra/Category): `ConcreteCategory` instance for `AlgebraCat` (#21121)
  feat(NumberTheory/LSeries): results involving partial sums of coefficients (part 1) (#20661)
  feat(RingTheory/LaurentSeries): add algebraEquiv (#21004)
  chore(SetTheory/Game/Impartial): golf two proofs (#21074)
  feat(CategoryTheory/Subpresheaf): preimage/image/range of subpresheaves (#21047)
  feat(RingTheory/IntegralClosure): `Algebra.IsIntegral` transfers via surjective homomorphisms (#21023)
  feat(`InformationTheory/Hamming`): Add AddGroup instances (#20994)
  feat(RingTheory/IntegralClosure): prove `Module.Finite R (adjoin R S)` for finite set `S` of integral elements (#20970)
  feat(RingTheory/Artinian): `IsUnit a` iff `a ∈ R⁰` for an artinian ring `R` (#21084)
  feat: separating set in the category of ind-objects (#21082)
  feat: derivWithin lemmas (#21092)
  chore(Fintype): golf a proof (#21113)
  chore: golf using `funext₂` (#21106)
  chore(Algebra/Group/Submonoid/Operations): move instances to new file (#21067)
  doc(Algebra/BigOperators/Fin): change 'product' to 'sum' in doc-string of additivised declarations (#21101)
  doc(ComputeDegree): typos (#21095)
  ...
@Julian

Julian commented Feb 21, 2025

Copy link
Copy Markdown
Collaborator Author

I believe I've covered all the suggestions @EtienneC30, thanks for all the tips! And asked on Zulip about the last remaining generalization (which I've added a TODO for).

@Julian Julian removed the awaiting-author A reviewer has asked the author a question or requested changes. label Feb 21, 2025
@pechersky

Copy link
Copy Markdown
Contributor

Results about injectivity and lt on degree and natDegree can likely be stated as StrictMono. There is a StrictMono.injective.

@Julian Julian added the awaiting-author A reviewer has asked the author a question or requested changes. label Feb 21, 2025
@Julian

Julian commented Feb 21, 2025

Copy link
Copy Markdown
Collaborator Author

Ah, nice! Done as well.

@Julian Julian removed the awaiting-author A reviewer has asked the author a question or requested changes. label Feb 21, 2025
@EtienneC30

Copy link
Copy Markdown
Member

Thanks!
maintainer merge

@github-actions

Copy link
Copy Markdown

🚀 Pull request has been placed on the maintainer queue by EtienneC30.

@github-actions github-actions Bot added the maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. label Feb 22, 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.

Thanks!

bors d+

Comment thread Mathlib/Algebra/Polynomial/Sequence.lean
@mathlib-bors

mathlib-bors Bot commented Feb 24, 2025

Copy link
Copy Markdown
Contributor

✌️ Julian 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 delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). and removed maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. labels Feb 24, 2025
@Julian

Julian commented Feb 24, 2025

Copy link
Copy Markdown
Collaborator Author

bors r+

mathlib-bors Bot pushed a commit that referenced this pull request Feb 24, 2025
We define [polynomial sequences](https://en.wikipedia.org/wiki/Polynomial_sequence) -- that is, sequences of polynomials where the `i`th polynomial has degree `i`.

We do not yet refactor any existing polynomial sequences to go via this proof (e.g. for the usual monomial basis which has its own proof already in Mathlib).
    
Co-authored-by: Aaron Hill <aa1ronham@gmail.com>
Co-authored-by: Julian Berman <Julian@GrayVines.com>
Co-authored-by: Matej Penciak <matej.penciak@gmail.com>
Co-authored-by: Austin Letson <waustinletson@gmail.com>



Co-authored-by: Aaron Hill <aa1ronham@gmail.com>
@mathlib-bors

mathlib-bors Bot commented Feb 24, 2025

Copy link
Copy Markdown
Contributor

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors Bot changed the title feat(Polynomial): polynomial sequences are bases for R[X] [Merged by Bors] - feat(Polynomial): polynomial sequences are bases for R[X] Feb 24, 2025
@mathlib-bors mathlib-bors Bot closed this Feb 24, 2025
@mathlib-bors
mathlib-bors Bot deleted the polynomial-sequences branch February 24, 2025 16:42
Julian added a commit that referenced this pull request Feb 24, 2025
* origin/master:
  feat(Polynomial): polynomial sequences are bases for R[X] (#20846)
  feat: monoidal structure on Hopf algebras (#12011)
  feat(DiscreteValuationRing): addVal_eq_zero_iff (#21154)
  refactor(Cache): refactor getPackageDir to not use manually provided package directories (#21817)
  feat(CategoryTheory): categories of homological complexes have a separator (#20229)
  chore(Data/Complex): deprecate `Complex.abs` (#21995)
  feat: uncountable instances for `Ordinal` and isomorphic types (#18547)
  feat(Data/Set/Card): a few missing lemmas (#22186)
  feat: discrete topological spaces are 0-manifolds (#22105)
  feat(Data/Matroid/Loop): matroid loops (#22045)
  feat(SetTheory/Ordinal/Nimber/Field): Nimber division (#19066)
  feat(LinearAlgebra/Pi): add `pi_proj` and `pi_proj_comp` (#22162)
  feat(Data/Matroid/Circuit): matroid cocircuits (#21692)
  feat(Topology/Compactification/OnePoint): generalize instance (#22179)
  feat(Combinatorics/SimpleGraph): takeUntil properties (#21250)
  feat(Tactic): `pnat_to_nat` and `enat_to_nat` tactics (#21602)
  refactor: move `Polynomial.coeffs` and related results (#22225)
  chore: add AlgHom.ker_coe_equiv, resolve porting notes and erws (#22019)
  refactor(Order/Category): `ConcreteCategory` instance for `\omegaCPO` (#21478)
  feat(CategoryTheory): Grothendieck categories have a coseparator (#22224)
  feat: tweak calc widget (#22170)
  feat(CategoryTheory): the Freyd-Mitchell embedding theorem (#22222)
  chore(CategoryTheory): turn more `simp` into `simps!` (#22223)
  feat(CategoryTheory): the category of ind-objects is Grothendieck abelian (#21606)
  feat(AlgebraicTopology/SimplexCategory/GeneratorsRelations/EpiMono): epi-mono factorisation in `SimplexCategoryGenRel` (#21743)
  chore(CategoryTheory/DiscreteCategory): turn `simp` to `simps!` (#22217)
  feat(Analysis/Asymptotics): exponential growth of a sequence (#21178)
  feat(CategoryTheory): sigmaConst preserves monomorphisms (#21599)
  feat(RingTheory/Cotangent): `liftBaseChange` is injective for localizations (#21037)
  chore(CategoryTheory): fix incorrect name (#22210)
  feat(CategoryTheory): `IsPullback` version of 'pullback of iso is iso' (#22211)
  feat(CategoryTheory): pullbacks in functor categories (#22209)
  feat(CategoryTheory): detecting limit cones over connected diagrams (#22192)
  feat(LinearAlgebra): add theorems for injective/surjective/bijective compositions of bilinear maps (#21491)
Champitoad pushed a commit that referenced this pull request Feb 25, 2025
We define [polynomial sequences](https://en.wikipedia.org/wiki/Polynomial_sequence) -- that is, sequences of polynomials where the `i`th polynomial has degree `i`.

We do not yet refactor any existing polynomial sequences to go via this proof (e.g. for the usual monomial basis which has its own proof already in Mathlib).
    
Co-authored-by: Aaron Hill <aa1ronham@gmail.com>
Co-authored-by: Julian Berman <Julian@GrayVines.com>
Co-authored-by: Matej Penciak <matej.penciak@gmail.com>
Co-authored-by: Austin Letson <waustinletson@gmail.com>



Co-authored-by: Aaron Hill <aa1ronham@gmail.com>
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). t-algebra Algebra (groups, rings, fields, etc)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants