Linear Algebra API for Computable Univariate Polynomials #
This file contains linear maps and instance-stable bounded-degree predicates for CPolynomial.
This is an R-linear function that returns the coefficient of X^n.
Equations
- CompPoly.CPolynomial.lcoeff n = { toFun := fun (p : CompPoly.CPolynomial R) => p.coeff n, map_add' := ⋯, map_smul' := ⋯ }
Instances For
The set of CPolynomial R consisting of polynomials of degree ≤ n.
Equations
- CompPoly.CPolynomial.degreeLE n = {p : CompPoly.CPolynomial R | (↑p).degreeBound ≤ n}
Instances For
The set of CPolynomial R consisting of polynomials of degree < n.
Equations
- CompPoly.CPolynomial.degreeLT n = {p : CompPoly.CPolynomial R | (↑p).degreeBound < ↑n}
Instances For
theorem
CompPoly.CPolynomial.mem_degreeLT_iff_size_le
{R : Type u_1}
[Zero R]
{n : ℕ}
{p : CPolynomial R}
:
degreeLT n is exactly the bounded-size carrier storing at most n coefficients.
@[instance_reducible]
instance
CompPoly.CPolynomial.instAddCommMonoidElemDegreeLT
{R : Type u_1}
[Semiring R]
[BEq R]
[LawfulBEq R]
(n : ℕ)
:
AddCommMonoid ↑(degreeLT n)
Equations
- One or more equations did not get rendered due to their size.
The first n coefficients on degreeLT n form a computable linear map to Fin n → R.
Equations
- CompPoly.CPolynomial.degreeLTCoeffs n = { toFun := fun (p : ↑(CompPoly.CPolynomial.degreeLT n)) (i : Fin n) => (↑p).coeff ↑i, map_add' := ⋯, map_smul' := ⋯ }
Instances For
@[simp]
theorem
CompPoly.CPolynomial.degreeLTCoeffs_apply
{R : Type u_1}
[Semiring R]
[BEq R]
[LawfulBEq R]
(n : ℕ)
(p : ↑(degreeLT n))
(i : Fin n)
:
Applying degreeLTCoeffs returns the corresponding bounded coefficient.