Weighted homogeneous polynomials #
THIS FILE IS SYNCHRONIZED WITH MATHLIB4. Any changes to this file require a corresponding PR to mathlib4.
It is possible to assign weights (in a commutative additive monoid M) to the variables of a
multivariate polynomial ring, so that monomials of the ring then have a weighted degree with
respect to the weights of the variables. The weights are represented by a function w : σ → M,
where σ are the indeterminates.
A multivariate polynomial φ is weighted homogeneous of weighted degree m : M if all monomials
occuring in φ have the same weighted degree m.
Main definitions/lemmas #
-
weighted_total_degree' w φ: the weighted total degree of a multivariate polynomial with respect to the weightsw, taking values inwith_bot M. -
weighted_total_degree w φ: WhenMhas a⊥element, we can define the weighted total degree of a multivariate polynomial as a function taking values inM. -
is_weighted_homogeneous w φ m: a predicate that asserts thatφis weighted homogeneous of weighted degreemwith respect to the weightsw. -
weighted_homogeneous_submodule R w m: the submodule of homogeneous polynomials of weighted degreem. -
weighted_homogeneous_component w m: the additive morphism that projects polynomials onto their summand that is weighted homogeneous of degreenwith respect tow. -
sum_weighted_homogeneous_component: every polynomial is the sum of its weighted homogeneous components.
weighted_degree' #
The weighted degree' of the finitely supported function s : σ →₀ ℕ is the sum
∑(s i)•(w i).
Equations
The weighted total degree of a multivariate polynomial, taking values in with_bot M.
Equations
- mv_polynomial.weighted_total_degree' w p = p.support.sup (λ (s : σ →₀ ℕ), ↑(⇑(mv_polynomial.weighted_degree' w) s))
The weighted_total_degree' of a polynomial p is ⊥ if and only if p = 0.
The weighted_total_degree' of the zero polynomial is ⊥.
When M has a ⊥ element, we can define the weighted total degree of a multivariate
polynomial as a function taking values in M.
Equations
- mv_polynomial.weighted_total_degree w p = p.support.sup (λ (s : σ →₀ ℕ), ⇑(mv_polynomial.weighted_degree' w) s)
This lemma relates weighted_total_degree and weighted_total_degree'.
The weighted_total_degree of the zero polynomial is ⊥.
A multivariate polynomial φ is weighted homogeneous of weighted degree m if all monomials
occuring in φ have weighted degree m.
Equations
- mv_polynomial.is_weighted_homogeneous w φ m = ∀ ⦃d : σ →₀ ℕ⦄, mv_polynomial.coeff d φ ≠ 0 → ⇑(mv_polynomial.weighted_degree' w) d = m
The submodule of homogeneous mv_polynomials of degree n.
Equations
- mv_polynomial.weighted_homogeneous_submodule R w m = {carrier := {x : mv_polynomial σ R | mv_polynomial.is_weighted_homogeneous w x m}, add_mem' := _, zero_mem' := _, smul_mem' := _}
Instances for mv_polynomial.weighted_homogeneous_submodule
The submodule weighted_homogeneous_submodule R w m of homogeneous mv_polynomials of
degree n is equal to the R-submodule of all p : (σ →₀ ℕ) →₀ R such that
p.support ⊆ {d | weighted_degree' w d = m}. While equal, the former has a
convenient definitional reduction.
The submodule generated by products Pm *Pn of weighted homogeneous polynomials of degrees m
and n is contained in the submodule of weighted homogeneous polynomials of degree m + n.
Monomials are weighted homogeneous.
A polynomial of weighted_total_degree ⊥ is weighted_homogeneous of degree ⊥.
Constant polynomials are weighted homogeneous of degree 0.
0 is weighted homogeneous of any degree.
1 is weighted homogeneous of degree 0.
An indeterminate i : σ is weighted homogeneous of degree w i.
The weighted degree of a weighted homogeneous polynomial controls its support.
The weighted degree of a nonzero weighted homogeneous polynomial is well-defined.
The sum of two weighted homogeneous polynomials of degree n is weighted homogeneous of
weighted degree n.
The sum of weighted homogeneous polynomials of degree n is weighted homogeneous of
weighted degree n.
The product of weighted homogeneous polynomials of weighted degrees m and n is weighted
homogeneous of weighted degree m + n.
A product of weighted homogeneous polynomials is weighted homogeneous, with weighted degree equal to the sum of the weighted degrees.
A non zero weighted homogeneous polynomial of weighted degree n has weighted total degree
n.
The weighted homogeneous submodules form a graded monoid.
weighted_homogeneous_component w n φ is the part of φ that is weighted homogeneous of
weighted degree n, with respect to the weights w.
See sum_weighted_homogeneous_component for the statement that φ is equal to the sum
of all its weighted homogeneous components.
Equations
- mv_polynomial.weighted_homogeneous_component w n = (finsupp.supported R R {d : σ →₀ ℕ | ⇑(mv_polynomial.weighted_degree' w) d = n}).subtype.comp (finsupp.restrict_dom R R {d : σ →₀ ℕ | ⇑(mv_polynomial.weighted_degree' w) d = n})
The n weighted homogeneous component of a polynomial is weighted homogeneous of
weighted degree n.
Every polynomial is the sum of its weighted homogeneous components.
The weighted homogeneous components of a weighted homogeneous polynomial.
If M is a canonically_ordered_add_monoid, then the weighted_homogeneous_component
of weighted degree 0 of a polynomial is its constant coefficient.