# mathlib3documentation

data.polynomial.partial_fractions

# Partial fractions #

THIS FILE IS SYNCHRONIZED WITH MATHLIB4. Any changes to this file require a corresponding PR to mathlib4.

These results were formalised by the Xena Project, at the suggestion of Patrick Massot.

# The main theorem #

• div_eq_quo_add_sum_rem_div: General partial fraction decomposition theorem for polynomials over an integral domain R : If f, g₁, g₂, ..., gₙ ∈ R[X] and the gᵢs are all monic and pairwise coprime, then ∃ q, r₁, ..., rₙ ∈ R[X] such that f / g₁g₂...gₙ = q + r₁/g₁ + ... + rₙ/gₙ and for all i, deg(rᵢ) < deg(gᵢ).

• The result is formalized here in slightly more generality, using finsets. That is, if ι is an arbitrary index type, g denotes a map from ι to R[X], and if s is an arbitrary finite subset of ι, with g i monic for all i ∈ s and for all i,j ∈ s, i ≠ j → g i is coprime to g j, then we have ∃ q ∈ R[X] , r : ι → R[X] such that ∀ i ∈ s, deg(r i) < deg(g i) and f / ∏ g i = q + ∑ (r i) / (g i), where the product and sum are over s.

• The proof is done by proving the two-denominator case and then performing finset induction for an arbitrary (finite) number of denominators.

## Scope for Expansion #

• Proving uniqueness of the decomposition
theorem div_eq_quo_add_rem_div_add_rem_div (R : Type) [comm_ring R] [is_domain R] (K : Type) [field K] [ K] [ K] (f : polynomial R) {g₁ g₂ : polynomial R} (hg₁ : g₁.monic) (hg₂ : g₂.monic) (hcoprime : g₂) :
(q r₁ r₂ : , r₁.degree < g₁.degree r₂.degree < g₂.degree f / (g₁ * g₂) = q + r₁ / g₁ + r₂ / g₂

Let R be an integral domain and f, g₁, g₂ ∈ R[X]. Let g₁ and g₂ be monic and coprime. Then, ∃ q, r₁, r₂ ∈ R[X] such that f / g₁g₂ = q + r₁/g₁ + r₂/g₂ and deg(r₁) < deg(g₁) and deg(r₂) < deg(g₂).

theorem div_eq_quo_add_sum_rem_div (R : Type) [comm_ring R] [is_domain R] (K : Type) [field K] [ K] [ K] (f : polynomial R) {ι : Type u_1} {g : ι } {s : finset ι} (hg : (i : ι), i s (g i).monic) (hcop : s.pairwise (λ (i j : ι), is_coprime (g i) (g j))) :
(q : (r : ι , ( (i : ι), i s (r i).degree < (g i).degree) f / s.prod (λ (i : ι), (g i)) = q + s.sum (λ (i : ι), (r i) / (g i))

Let R be an integral domain and f ∈ R[X]. Let s be a finite index set. Then, a fraction of the form f / ∏ (g i) can be rewritten as q + ∑ (r i) / (g i), where deg(r i) < deg(g i), provided that the g i are monic and pairwise coprime.