Polynomials over finite fields #
THIS FILE IS SYNCHRONIZED WITH MATHLIB4. Any changes to this file require a corresponding PR to mathlib4.
theorem
mv_polynomial.C_dvd_iff_zmod
{σ : Type u_1}
(n : ℕ)
(φ : mv_polynomial σ ℤ) :
⇑mv_polynomial.C ↑n ∣ φ ↔ ⇑(mv_polynomial.map (int.cast_ring_hom (zmod n))) φ = 0
A polynomial over the integers is divisible by n : ℕ
if and only if it is zero over zmod n
.
theorem
mv_polynomial.frobenius_zmod
{σ : Type u_1}
{p : ℕ}
[fact (nat.prime p)]
(f : mv_polynomial σ (zmod p)) :
⇑(frobenius (mv_polynomial σ (zmod p)) p) f = ⇑(mv_polynomial.expand p) f
theorem
mv_polynomial.expand_zmod
{σ : Type u_1}
{p : ℕ}
[fact (nat.prime p)]
(f : mv_polynomial σ (zmod p)) :
⇑(mv_polynomial.expand p) f = f ^ p
noncomputable
def
mv_polynomial.indicator
{K : Type u_1}
{σ : Type u_2}
[fintype K]
[fintype σ]
[comm_ring K]
(a : σ → K) :
mv_polynomial σ K
Over a field, this is the indicator function as an mv_polynomial
.
Equations
- mv_polynomial.indicator a = finset.univ.prod (λ (n : σ), 1 - (mv_polynomial.X n - ⇑mv_polynomial.C (a n)) ^ (fintype.card K - 1))
theorem
mv_polynomial.eval_indicator_apply_eq_one
{K : Type u_1}
{σ : Type u_2}
[fintype K]
[fintype σ]
[comm_ring K]
(a : σ → K) :
⇑(mv_polynomial.eval a) (mv_polynomial.indicator a) = 1
theorem
mv_polynomial.degrees_indicator
{K : Type u_1}
{σ : Type u_2}
[fintype K]
[fintype σ]
[comm_ring K]
(c : σ → K) :
(mv_polynomial.indicator c).degrees ≤ finset.univ.sum (λ (s : σ), (fintype.card K - 1) • {s})
theorem
mv_polynomial.eval_indicator_apply_eq_zero
{K : Type u_1}
{σ : Type u_2}
[fintype K]
[fintype σ]
[field K]
(a b : σ → K)
(h : a ≠ b) :
⇑(mv_polynomial.eval a) (mv_polynomial.indicator b) = 0
@[simp]
theorem
mv_polynomial.evalₗ_apply
(K : Type u_1)
(σ : Type u_2)
[comm_semiring K]
(p : mv_polynomial σ K)
(e : σ → K) :
⇑(mv_polynomial.evalₗ K σ) p e = ⇑(mv_polynomial.eval e) p
noncomputable
def
mv_polynomial.evalₗ
(K : Type u_1)
(σ : Type u_2)
[comm_semiring K] :
mv_polynomial σ K →ₗ[K] (σ → K) → K
mv_polynomial.eval
as a K
-linear map.
Equations
- mv_polynomial.evalₗ K σ = {to_fun := λ (p : mv_polynomial σ K) (e : σ → K), ⇑(mv_polynomial.eval e) p, map_add' := _, map_smul' := _}
theorem
mv_polynomial.map_restrict_dom_evalₗ
{K : Type u_1}
{σ : Type u_2}
[field K]
[fintype K]
[finite σ] :
submodule.map (mv_polynomial.evalₗ K σ) (mv_polynomial.restrict_degree σ K (fintype.card K - 1)) = ⊤
@[protected, instance]
@[protected, instance]
noncomputable
def
mv_polynomial.R.inhabited
(σ K : Type u)
[fintype K]
[comm_ring K] :
inhabited (mv_polynomial.R σ K)
The submodule of multivariate polynomials whose degree of each variable is strictly less than the cardinality of K.
Equations
- mv_polynomial.R σ K = ↥(mv_polynomial.restrict_degree σ K (fintype.card K - 1))
Instances for mv_polynomial.R
@[protected, instance]
noncomputable
def
mv_polynomial.R.module
(σ K : Type u)
[fintype K]
[comm_ring K] :
module K (mv_polynomial.R σ K)
noncomputable
def
mv_polynomial.evalᵢ
(σ K : Type u)
[fintype K]
[comm_ring K] :
mv_polynomial.R σ K →ₗ[K] (σ → K) → K
Evaluation in the mv_polynomial.R
subtype.
Equations
- mv_polynomial.evalᵢ σ K = (mv_polynomial.evalₗ K σ).comp (mv_polynomial.restrict_degree σ K (fintype.card K - 1)).subtype
@[protected, instance]
theorem
mv_polynomial.rank_R
(σ K : Type u)
[fintype K]
[field K]
[fintype σ] :
module.rank K (mv_polynomial.R σ K) = ↑(fintype.card (σ → K))
@[protected, instance]
def
mv_polynomial.R.finite_dimensional
(σ K : Type u)
[fintype K]
[field K]
[finite σ] :
finite_dimensional K (mv_polynomial.R σ K)
theorem
mv_polynomial.finrank_R
(σ K : Type u)
[fintype K]
[field K]
[fintype σ] :
finite_dimensional.finrank K (mv_polynomial.R σ K) = fintype.card (σ → K)
theorem
mv_polynomial.ker_evalₗ
(σ K : Type u)
[fintype K]
[field K]
[finite σ] :
linear_map.ker (mv_polynomial.evalᵢ σ K) = ⊥
theorem
mv_polynomial.eq_zero_of_eval_eq_zero
(σ K : Type u)
[fintype K]
[field K]
[finite σ]
(p : mv_polynomial σ K)
(h : ∀ (v : σ → K), ⇑(mv_polynomial.eval v) p = 0)
(hp : p ∈ mv_polynomial.restrict_degree σ K (fintype.card K - 1)) :
p = 0