The Mathlib Handbook

The volumes of the handbook are not written yet. This site shows the map of Mathlib that they will follow, at Mathlib 4472534b60.

The areas / V09. Commutative algebra I: ideals, polynomials, factorization

Mathlib.Algebra.Polynomial.Laurent

108 declarations and 2 deprecated aliases. Mathlib docs · Source

Laurent polynomials

We introduce Laurent polynomials over a semiring R. Mathematically, they are expressions of the form $$ \sum_{i \in \mathbb{Z}} a_i T ^ i $$ where the sum extends over a finite subset of ℤ. Thus, negative exponents are allowed. The coefficients come from the semiring R and the variable T commutes with everything.

Since we are going to convert back and forth between polynomials and Laurent polynomials, we decided to maintain some distinction by using the symbol T, rather than X, as the variable for Laurent polynomials.

Notation

The symbol R[T;T⁻¹] stands for LaurentPolynomial R. We also define

  • C : R →+* R[T;T⁻¹] the inclusion of constant polynomials, analogous to the one for R[X];
  • T : ℤ → R[T;T⁻¹] the sequence of powers of the variable T.

Implementation notes

We define Laurent polynomials as AddMonoidAlgebra R ℤ. Thus, they are essentially Finsupps ℤ →₀ R. This choice differs from the current irreducible design of Polynomial, that instead shields away the implementation via Finsupps. It is closer to the original definition of polynomials.

As a consequence, LaurentPolynomial plays well with polynomials, but there is a little roughness in establishing the API, since the Finsupp implementation of R[X] is well-shielded.

Unlike the case of polynomials, I felt that the exponent notation was not too easy to use, as only natural exponents would be allowed. Moreover, in the end, it seems likely that we should aim to perform computations on exponents in ℤ anyway and separating this via the symbol T seems convenient.

I made a heavy use of simp lemmas, aiming to bring Laurent polynomials to the form C a * T n. Any comments or suggestions for improvements is greatly appreciated!

TODO

Lots is missing! -- (Riccardo) add inclusion into Laurent series. -- A "better" definition of trunc would be as an R-linear map. This works: -- -- def trunc : R[T;T⁻¹] →[R] R[X] := -- refine (?_ : R[ℕ] →[R] R[X]).comp ?_ -- · exact ⟨(toFinsuppIso R).symm, by simp⟩ -- · refine ⟨fun r ↦ comapDomain _ r -- (Set.injOn_of_injective (fun _ _ ↦ Int.ofNat.inj) _), ?_⟩ -- exact fun r f ↦ comapDomain_smul .. -- -- but it would make sense to bundle the maps better, for a smoother user experience. -- I (DT) did not have the strength to embark on this (possibly short!) journey, after getting to -- this stage of the Laurent process! -- This would likely involve adding a comapDomain analogue of -- AddMonoidAlgebra.mapDomainAlgHom and an R-linear version of -- Polynomial.toFinsuppIso. -- Add degree, intDegree, intTrailingDegree, leadingCoeff, trailingCoeff,....

The functions C and T.

theorem AddMonoidAlgebra.comapDomain.congr_simp E1 #

∀ {R : Type u_3} {M : Type u_6} {N : Type u_7} [inst : Semiring R] (f f_1 : M → N) (e_f : f = f_1)
  (hf : Function.Injective f) (x x_1 : AddMonoidAlgebra R N),
  x = x_1 → AddMonoidAlgebra.comapDomain f hf x = AddMonoidAlgebra.comapDomain f_1 ⋯ x_1

abbrev LaurentPolynomial E1 #

(R : Type u_3) → [Semiring R] → Type (max u_3 0)

The semiring of Laurent polynomials with coefficients in the semiring R. We denote it by R[T;T⁻¹]. The ring homomorphism C : R →+* R[T;T⁻¹] includes R as the constant polynomials.

def LaurentPolynomial.«term_[T;T⁻¹]» E1 #

Lean.TrailingParserDescr

theorem LaurentPolynomial.ext E1 #

∀ {R : Type u_1} [inst : Semiring R] {p q : LaurentPolynomial R}, (∀ (a : ℤ), p.coeff a = q.coeff a) → p = q

theorem LaurentPolynomial.ext_iff E0 #

∀ {R : Type u_1} [inst : Semiring R] {p q : LaurentPolynomial R}, p = q ↔ ∀ (a : ℤ), p.coeff a = q.coeff a

def Polynomial.toLaurent E1 #

{R : Type u_1} → [inst : Semiring R] → Polynomial R →+* LaurentPolynomial R

The ring homomorphism, taking a polynomial with coefficients in R to a Laurent polynomial with coefficients in R.

theorem Polynomial.toLaurent_apply E0 #

∀ {R : Type u_1} [inst : Semiring R] (p : Polynomial R), Polynomial.toLaurent p = AddMonoidAlgebra.mapDomain Nat.cast p

This is not a simp lemma, as it is usually preferable to use the lemmas about C and X instead.

def Polynomial.toLaurentAlg E1 #

{R : Type u_1} → [inst : CommSemiring R] → Polynomial R →ₐ[R] LaurentPolynomial R

The R-algebra map, taking a polynomial with coefficients in R to a Laurent polynomial with coefficients in R.

theorem Polynomial.coe_toLaurentAlg E0 #

∀ {R : Type u_1} [inst : CommSemiring R], ⇑Polynomial.toLaurentAlg = ⇑Polynomial.toLaurent

theorem Polynomial.toLaurentAlg_apply E0 #

∀ {R : Type u_1} [inst : CommSemiring R] (f : Polynomial R), Polynomial.toLaurentAlg f = Polynomial.toLaurent f

theorem LaurentPolynomial.single_zero_one_eq_one E1 #

∀ {R : Type u_1} [inst : Semiring R], AddMonoidAlgebra.single 0 1 = 1

def LaurentPolynomial.C E1 #

{R : Type u_1} → [inst : Semiring R] → R →+* LaurentPolynomial R

The ring homomorphism C, including R into the ring of Laurent polynomials over R as the constant Laurent polynomials.

theorem LaurentPolynomial.algebraMap_apply E0 #

∀ {R : Type u_3} {A : Type u_4} [inst : CommSemiring R] [inst_1 : Semiring A] [inst_2 : Algebra R A] (r : R),
  (algebraMap R (LaurentPolynomial A)) r = LaurentPolynomial.C ((algebraMap R A) r)

theorem LaurentPolynomial.C_eq_algebraMap E1 #

∀ {R : Type u_3} [inst : CommSemiring R] (r : R), LaurentPolynomial.C r = (algebraMap R (LaurentPolynomial R)) r

When we have [CommSemiring R], the function C is the same as algebraMap R R[T;T⁻¹]. (But note that C is defined when R is not necessarily commutative, in which case algebraMap is not available.)

theorem LaurentPolynomial.single_eq_C E1 #

∀ {R : Type u_1} [inst : Semiring R] (r : R), AddMonoidAlgebra.single 0 r = LaurentPolynomial.C r

theorem LaurentPolynomial.C_apply E0 #

∀ {R : Type u_1} [inst : Semiring R] (t : R) (n : ℤ), (LaurentPolynomial.C t).coeff n = if n = 0 then t else 0

def LaurentPolynomial.T E1 #

{R : Type u_1} → [inst : Semiring R] → ℤ → LaurentPolynomial R

The function n ↦ T ^ n, implemented as a sequence ℤ → R[T;T⁻¹].

Using directly T ^ n does not work, since we want the exponents to be of Type ℤ and there is no ℤ-power defined on R[T;T⁻¹]. Using that T is a unit introduces extra coercions. For these reasons, the definition of T is as a sequence.

theorem LaurentPolynomial.T_apply E0 #

∀ {R : Type u_1} [inst : Semiring R] (m n : ℤ), (LaurentPolynomial.T n).coeff m = if n = m then 1 else 0

theorem LaurentPolynomial.T_zero E0 #

∀ {R : Type u_1} [inst : Semiring R], LaurentPolynomial.T 0 = 1

theorem LaurentPolynomial.T_add E1 #

∀ {R : Type u_1} [inst : Semiring R] (m n : ℤ),
  LaurentPolynomial.T (m + n) = LaurentPolynomial.T m * LaurentPolynomial.T n

theorem LaurentPolynomial.T_sub E1 #

∀ {R : Type u_1} [inst : Semiring R] (m n : ℤ),
  LaurentPolynomial.T (m - n) = LaurentPolynomial.T m * LaurentPolynomial.T (-n)

theorem LaurentPolynomial.T_pow E0 #

∀ {R : Type u_1} [inst : Semiring R] (m : ℤ) (n : ℕ), LaurentPolynomial.T m ^ n = LaurentPolynomial.T (↑n * m)

theorem LaurentPolynomial.mul_T_assoc E0 #

∀ {R : Type u_1} [inst : Semiring R] (f : LaurentPolynomial R) (m n : ℤ),
  f * LaurentPolynomial.T m * LaurentPolynomial.T n = f * LaurentPolynomial.T (m + n)

The simp version of mul_assoc, in the presence of T's.

theorem LaurentPolynomial.single_eq_C_mul_T E0 #

∀ {R : Type u_1} [inst : Semiring R] (r : R) (n : ℤ),
  AddMonoidAlgebra.single n r = LaurentPolynomial.C r * LaurentPolynomial.T n

theorem Polynomial.toLaurent_C_mul_T E0 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℕ) (r : R),
  Polynomial.toLaurent ((Polynomial.monomial n) r) = LaurentPolynomial.C r * LaurentPolynomial.T ↑n

theorem Polynomial.toLaurent_C E0 #

∀ {R : Type u_1} [inst : Semiring R] (r : R), Polynomial.toLaurent (Polynomial.C r) = LaurentPolynomial.C r

theorem Polynomial.toLaurent_comp_C E0 #

∀ {R : Type u_1} [inst : Semiring R], ⇑Polynomial.toLaurent ∘ ⇑Polynomial.C = ⇑LaurentPolynomial.C

theorem Polynomial.toLaurent_X E0 #

∀ {R : Type u_1} [inst : Semiring R], Polynomial.toLaurent Polynomial.X = LaurentPolynomial.T 1

theorem Polynomial.toLaurent_one E0 #

∀ {R : Type u_1} [inst : Semiring R], Polynomial.toLaurent 1 = 1

theorem Polynomial.toLaurent_C_mul_eq E0 #

∀ {R : Type u_1} [inst : Semiring R] (r : R) (f : Polynomial R),
  Polynomial.toLaurent (Polynomial.C r * f) = LaurentPolynomial.C r * Polynomial.toLaurent f

theorem Polynomial.toLaurent_X_pow E0 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℕ), Polynomial.toLaurent (Polynomial.X ^ n) = LaurentPolynomial.T ↑n

theorem Polynomial.toLaurent_C_mul_X_pow E1 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℕ) (r : R),
  Polynomial.toLaurent (Polynomial.C r * Polynomial.X ^ n) = LaurentPolynomial.C r * LaurentPolynomial.T ↑n

instance LaurentPolynomial.invertibleT E0 #

{R : Type u_1} → [inst : Semiring R] → (n : ℤ) → Invertible (LaurentPolynomial.T n)

theorem LaurentPolynomial.invOf_T E0 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℤ), ⅟(LaurentPolynomial.T n) = LaurentPolynomial.T (-n)

theorem LaurentPolynomial.isUnit_T E1 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℤ), IsUnit (LaurentPolynomial.T n)

theorem LaurentPolynomial.induction_on E1 #

∀ {R : Type u_1} [inst : Semiring R] {M : LaurentPolynomial R → Prop} (p : LaurentPolynomial R),
  (∀ (a : R), M (LaurentPolynomial.C a)) →
    (∀ {p q : LaurentPolynomial R}, M p → M q → M (p + q)) →
      (∀ (n : ℕ) (a : R),
          M (LaurentPolynomial.C a * LaurentPolynomial.T ↑n) →
            M (LaurentPolynomial.C a * LaurentPolynomial.T (↑n + 1))) →
        (∀ (n : ℕ) (a : R),
            M (LaurentPolynomial.C a * LaurentPolynomial.T (-↑n)) →
              M (LaurentPolynomial.C a * LaurentPolynomial.T (-↑n - 1))) →
          M p

theorem LaurentPolynomial.induction_on' E1 #

∀ {R : Type u_1} [inst : Semiring R] {motive : LaurentPolynomial R → Prop} (p : LaurentPolynomial R),
  (∀ (p q : LaurentPolynomial R), motive p → motive q → motive (p + q)) →
    (∀ (n : ℤ) (a : R), motive (LaurentPolynomial.C a * LaurentPolynomial.T n)) → motive p

To prove something about Laurent polynomials, it suffices to show that

  • the condition is closed under taking sums, and
  • it holds for monomials.

theorem LaurentPolynomial.commute_T E1 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℤ) (f : LaurentPolynomial R), Commute (LaurentPolynomial.T n) f

theorem LaurentPolynomial.T_mul E0 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℤ) (f : LaurentPolynomial R),
  LaurentPolynomial.T n * f = f * LaurentPolynomial.T n

theorem LaurentPolynomial.smul_eq_C_mul E1 #

∀ {R : Type u_1} [inst : Semiring R] (r : R) (f : LaurentPolynomial R), r • f = LaurentPolynomial.C r * f

def LaurentPolynomial.trunc E1 #

{R : Type u_1} → [inst : Semiring R] → LaurentPolynomial R →+ Polynomial R

trunc : R[T;T⁻¹] →+ R[X] maps a Laurent polynomial f to the polynomial whose terms of nonnegative degree coincide with the ones of f. The terms of negative degree of f "vanish". trunc is a left-inverse to Polynomial.toLaurent.

theorem LaurentPolynomial.trunc_C_mul_T E0 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℤ) (r : R),
  LaurentPolynomial.trunc (LaurentPolynomial.C r * LaurentPolynomial.T n) =
    if 0 ≤ n then (Polynomial.monomial n.toNat) r else 0

theorem LaurentPolynomial.leftInverse_trunc_toLaurent E0 #

∀ {R : Type u_1} [inst : Semiring R], Function.LeftInverse ⇑LaurentPolynomial.trunc ⇑Polynomial.toLaurent

theorem Polynomial.trunc_toLaurent E0 #

∀ {R : Type u_1} [inst : Semiring R] (f : Polynomial R), LaurentPolynomial.trunc (Polynomial.toLaurent f) = f

theorem Polynomial.toLaurent_injective E1 #

∀ {R : Type u_1} [inst : Semiring R], Function.Injective ⇑Polynomial.toLaurent

theorem Polynomial.toLaurent_inj E0 #

∀ {R : Type u_1} [inst : Semiring R] (f g : Polynomial R), Polynomial.toLaurent f = Polynomial.toLaurent g ↔ f = g

theorem Polynomial.toLaurent_ne_zero E1 #

∀ {R : Type u_1} [inst : Semiring R] {f : Polynomial R}, Polynomial.toLaurent f ≠ 0 ↔ f ≠ 0

theorem Polynomial.toLaurent_eq_zero E0 #

∀ {R : Type u_1} [inst : Semiring R] {f : Polynomial R}, Polynomial.toLaurent f = 0 ↔ f = 0

theorem LaurentPolynomial.exists_T_pow E1 #

∀ {R : Type u_1} [inst : Semiring R] (f : LaurentPolynomial R),
  ∃ n f', Polynomial.toLaurent f' = f * LaurentPolynomial.T ↑n

theorem LaurentPolynomial.induction_on_mul_T E1 #

∀ {R : Type u_1} [inst : Semiring R] {motive : LaurentPolynomial R → Prop} (f : LaurentPolynomial R),
  (∀ (f : Polynomial R) (n : ℕ), motive (Polynomial.toLaurent f * LaurentPolynomial.T (-↑n))) → motive f

This is a version of exists_T_pow stated as an induction principle.

theorem LaurentPolynomial.reduce_to_polynomial_of_mul_T E1 #

∀ {R : Type u_1} [inst : Semiring R] (f : LaurentPolynomial R) {Q : LaurentPolynomial R → Prop},
  (∀ (f : Polynomial R), Q (Polynomial.toLaurent f)) →
    (∀ (f : LaurentPolynomial R), Q (f * LaurentPolynomial.T 1) → Q f) → Q f

Suppose that Q is a statement about Laurent polynomials such that

  • Q is true on ordinary polynomials;
  • Q (f * T) implies Q f;

it follow that Q is true on all Laurent polynomials.

theorem LaurentPolynomial.support_C_mul_T E1 #

∀ {R : Type u_1} [inst : Semiring R] (a : R) (n : ℤ),
  (LaurentPolynomial.C a * LaurentPolynomial.T n).coeff.support ⊆ {n}

theorem LaurentPolynomial.support_coeff_C_mul_T_of_ne_zero E1 #

∀ {R : Type u_1} [inst : Semiring R] {a : R},
  a ≠ 0 → ∀ (n : ℤ), (LaurentPolynomial.C a * LaurentPolynomial.T n).coeff.support = {n}

theorem LaurentPolynomial.coeff_toLaurent E0 #

∀ {R : Type u_1} [inst : Semiring R] (f : Polynomial R),
  (Polynomial.toLaurent f).coeff = Finsupp.mapDomain (⇑Nat.castEmbedding) f.coeff

theorem LaurentPolynomial.support_coeff_toLaurent E2 #

∀ {R : Type u_1} [inst : Semiring R] (f : Polynomial R),
  (Polynomial.toLaurent f).coeff.support = Finset.map Nat.castEmbedding f.support

The support of a polynomial f is a finset in ℕ. The lemma toLaurent_support f shows that the support of f.toLaurent is the same finset, but viewed in ℤ under the natural inclusion ℕ ↪ ℤ.

def LaurentPolynomial.degree E1 #

{R : Type u_1} → [inst : Semiring R] → LaurentPolynomial R → WithBot ℤ

The degree of a Laurent polynomial takes values in WithBot ℤ. If f : R[T;T⁻¹] is a Laurent polynomial, then f.degree is the maximum of its support of f, or ⊥, if f = 0.

theorem LaurentPolynomial.degree_zero E0 #

∀ {R : Type u_1} [inst : Semiring R], LaurentPolynomial.degree 0 = ⊥

theorem LaurentPolynomial.degree_eq_bot_iff E0 #

∀ {R : Type u_1} [inst : Semiring R] {f : LaurentPolynomial R}, f.degree = ⊥ ↔ f = 0

theorem LaurentPolynomial.degree_C_mul_T E0 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℤ) (a : R),
  a ≠ 0 → (LaurentPolynomial.C a * LaurentPolynomial.T n).degree = ↑n

theorem LaurentPolynomial.degree_C_mul_T_ite E1 #

∀ {R : Type u_1} [inst : Semiring R] [inst_1 : DecidableEq R] (n : ℤ) (a : R),
  (LaurentPolynomial.C a * LaurentPolynomial.T n).degree = if a = 0 then ⊥ else ↑n

theorem LaurentPolynomial.degree_T E0 #

∀ {R : Type u_1} [inst : Semiring R] [Nontrivial R] (n : ℤ), (LaurentPolynomial.T n).degree = ↑n

theorem LaurentPolynomial.degree_C E1 #

∀ {R : Type u_1} [inst : Semiring R] {a : R}, a ≠ 0 → (LaurentPolynomial.C a).degree = 0

theorem LaurentPolynomial.degree_C_ite E1 #

∀ {R : Type u_1} [inst : Semiring R] [inst_1 : DecidableEq R] (a : R),
  (LaurentPolynomial.C a).degree = if a = 0 then ⊥ else 0

theorem LaurentPolynomial.degree_C_mul_T_le E1 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℤ) (a : R), (LaurentPolynomial.C a * LaurentPolynomial.T n).degree ≤ ↑n

theorem LaurentPolynomial.degree_T_le E1 #

∀ {R : Type u_1} [inst : Semiring R] (n : ℤ), (LaurentPolynomial.T n).degree ≤ ↑n

theorem LaurentPolynomial.degree_C_le E1 #

∀ {R : Type u_1} [inst : Semiring R] (a : R), (LaurentPolynomial.C a).degree ≤ 0

instance LaurentPolynomial.instModulePolynomial E0 #

{R : Type u_1} → [inst : Semiring R] → Module (Polynomial R) (LaurentPolynomial R)

instance LaurentPolynomial.instIsScalarTowerPolynomial E0 #

∀ (R : Type u_3) [inst : Semiring R], IsScalarTower (Polynomial R) (Polynomial R) (LaurentPolynomial R)

instance LaurentPolynomial.algebraPolynomial E0 #

(R : Type u_4) → [inst : CommSemiring R] → Algebra (Polynomial R) (LaurentPolynomial R)

theorem LaurentPolynomial.algebraMap_X_pow E1 #

∀ {R : Type u_1} [inst : CommSemiring R] (n : ℕ),
  (algebraMap (Polynomial R) (LaurentPolynomial R)) (Polynomial.X ^ n) = LaurentPolynomial.T ↑n

theorem LaurentPolynomial.algebraMap_eq_toLaurent E0 #

∀ {R : Type u_1} [inst : CommSemiring R] (f : Polynomial R),
  (algebraMap (Polynomial R) (LaurentPolynomial R)) f = Polynomial.toLaurent f

instance LaurentPolynomial.isLocalization E0 #

∀ {R : Type u_1} [inst : CommSemiring R], IsLocalization.Away Polynomial.X (LaurentPolynomial R)

theorem LaurentPolynomial.mk'_mul_T E1 #

∀ {R : Type u_1} [inst : CommSemiring R] (p : Polynomial R) (n : ℕ),
  IsLocalization.mk' (LaurentPolynomial R) p ⟨Polynomial.X ^ n, ⋯⟩ * LaurentPolynomial.T ↑n = Polynomial.toLaurent p

theorem LaurentPolynomial.mk'_eq E0 #

∀ {R : Type u_1} [inst : CommSemiring R] (p : Polynomial R) (n : ℕ),
  IsLocalization.mk' (LaurentPolynomial R) p ⟨Polynomial.X ^ n, ⋯⟩ = Polynomial.toLaurent p * LaurentPolynomial.T (-↑n)

theorem LaurentPolynomial.mk'_one_X_pow E1 #

∀ {R : Type u_1} [inst : CommSemiring R] (n : ℕ),
  IsLocalization.mk' (LaurentPolynomial R) 1 ⟨Polynomial.X ^ n, ⋯⟩ = LaurentPolynomial.T (-↑n)

theorem LaurentPolynomial.mk'_one_X E0 #

∀ {R : Type u_1} [inst : CommSemiring R],
  IsLocalization.mk' (LaurentPolynomial R) 1 ⟨Polynomial.X, ⋯⟩ = LaurentPolynomial.T (-1)

def LaurentPolynomial.eval₂ E1 #

{R : Type u_1} →
  [inst : CommSemiring R] → {S : Type u_3} → [inst_1 : CommSemiring S] → (R →+* S) → Sˣ → LaurentPolynomial R →+* S

Given a ring homomorphism f : R →+* S and a unit x in S, the induced homomorphism R[T;T⁻¹] →+* S sending T to x and T⁻¹ to x⁻¹.

theorem LaurentPolynomial.eval₂_toLaurent E0 #

∀ {R : Type u_1} [inst : CommSemiring R] {S : Type u_3} [inst_1 : CommSemiring S] (f : R →+* S) (x : Sˣ)
  (p : Polynomial R), (LaurentPolynomial.eval₂ f x) (Polynomial.toLaurent p) = Polynomial.eval₂ f (↑x) p

theorem LaurentPolynomial.eval₂_T_n E1 #

∀ {R : Type u_1} [inst : CommSemiring R] {S : Type u_3} [inst_1 : CommSemiring S] (f : R →+* S) (x : Sˣ) (n : ℕ),
  (LaurentPolynomial.eval₂ f x) (LaurentPolynomial.T ↑n) = ↑x ^ n

theorem LaurentPolynomial.eval₂_T_neg_n E1 #

∀ {R : Type u_1} [inst : CommSemiring R] {S : Type u_3} [inst_1 : CommSemiring S] (f : R →+* S) (x : Sˣ) (n : ℕ),
  (LaurentPolynomial.eval₂ f x) (LaurentPolynomial.T (-↑n)) = ↑x⁻¹ ^ n

theorem LaurentPolynomial.eval₂_T E0 #

∀ {R : Type u_1} [inst : CommSemiring R] {S : Type u_3} [inst_1 : CommSemiring S] (f : R →+* S) (x : Sˣ) (n : ℤ),
  (LaurentPolynomial.eval₂ f x) (LaurentPolynomial.T n) = ↑(x ^ n)

theorem LaurentPolynomial.eval₂_C E0 #

∀ {R : Type u_1} [inst : CommSemiring R] {S : Type u_3} [inst_1 : CommSemiring S] (f : R →+* S) (x : Sˣ) (r : R),
  (LaurentPolynomial.eval₂ f x) (LaurentPolynomial.C r) = f r

theorem LaurentPolynomial.eval₂_C_mul_T_n E1 #

∀ {R : Type u_1} [inst : CommSemiring R] {S : Type u_3} [inst_1 : CommSemiring S] (f : R →+* S) (x : Sˣ) (r : R)
  (n : ℕ), (LaurentPolynomial.eval₂ f x) (LaurentPolynomial.C r * LaurentPolynomial.T ↑n) = f r * ↑x ^ n

theorem LaurentPolynomial.eval₂_C_mul_T_neg_n E1 #

∀ {R : Type u_1} [inst : CommSemiring R] {S : Type u_3} [inst_1 : CommSemiring S] (f : R →+* S) (x : Sˣ) (r : R)
  (n : ℕ), (LaurentPolynomial.eval₂ f x) (LaurentPolynomial.C r * LaurentPolynomial.T (-↑n)) = f r * ↑x⁻¹ ^ n

theorem LaurentPolynomial.eval₂_C_mul_T E0 #

∀ {R : Type u_1} [inst : CommSemiring R] {S : Type u_3} [inst_1 : CommSemiring S] (f : R →+* S) (x : Sˣ) (r : R)
  (n : ℤ), (LaurentPolynomial.eval₂ f x) (LaurentPolynomial.C r * LaurentPolynomial.T n) = f r * ↑(x ^ n)

theorem LaurentPolynomial.eval₂_mapRingHom E1 #

∀ {R : Type u_1} [inst : CommSemiring R] {S : Type u_3} [inst_1 : CommSemiring S] (f : R →+* S) (x : Sˣ) {R' : Type u_4}
  [inst_2 : CommSemiring R'] (g : R' →+* R) (p : LaurentPolynomial R'),
  (LaurentPolynomial.eval₂ f x) ((AddMonoidAlgebra.mapRingHom ℤ g) p) = (LaurentPolynomial.eval₂ (f.comp g) x) p

def LaurentPolynomial.invert E1 #

{R : Type u_3} → [inst : CommSemiring R] → LaurentPolynomial R ≃ₐ[R] LaurentPolynomial R

The map which substitutes T ↦ T⁻¹ into a Laurent polynomial.

theorem LaurentPolynomial.invert_T E0 #

∀ {R : Type u_3} [inst : CommSemiring R] (n : ℤ),
  LaurentPolynomial.invert (LaurentPolynomial.T n) = LaurentPolynomial.T (-n)

theorem LaurentPolynomial.invert_apply E0 #

∀ {R : Type u_3} [inst : CommSemiring R] (f : LaurentPolynomial R) (n : ℤ),
  (LaurentPolynomial.invert f).coeff n = f.coeff (-n)

theorem LaurentPolynomial.invert_comp_C E0 #

∀ {R : Type u_3} [inst : CommSemiring R], ⇑LaurentPolynomial.invert ∘ ⇑LaurentPolynomial.C = ⇑LaurentPolynomial.C

theorem LaurentPolynomial.invert_C E0 #

∀ {R : Type u_3} [inst : CommSemiring R] (t : R),
  LaurentPolynomial.invert (LaurentPolynomial.C t) = LaurentPolynomial.C t

theorem LaurentPolynomial.involutive_invert E1 #

∀ {R : Type u_3} [inst : CommSemiring R], Function.Involutive ⇑LaurentPolynomial.invert

theorem LaurentPolynomial.invert_symm E0 #

∀ {R : Type u_3} [inst : CommSemiring R], LaurentPolynomial.invert.symm = LaurentPolynomial.invert

theorem LaurentPolynomial.toLaurent_reverse E1 #

∀ {R : Type u_3} [inst : CommSemiring R] (p : Polynomial R),
  Polynomial.toLaurent p.reverse = LaurentPolynomial.invert (Polynomial.toLaurent p) * LaurentPolynomial.T ↑p.natDegree

def LaurentPolynomial.smeval E1 #

{R : Type u_1} →
  {S : Type u_2} →
    [inst : Semiring R] →
      [inst_1 : AddCommMonoid S] → [SMulWithZero R S] → [inst_3 : Monoid S] → LaurentPolynomial R → Sˣ → S

Evaluate a Laurent polynomial at a unit, using scalar multiplication.

theorem LaurentPolynomial.smeval_eq_sum E1 #

∀ {R : Type u_1} {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : SMulWithZero R S]
  [inst_3 : Monoid S] (f : LaurentPolynomial R) (x : Sˣ), f.smeval x = f.coeff.sum fun n r ↦ r • ↑(x ^ n)

theorem LaurentPolynomial.smeval_congr E1 #

∀ {R : Type u_1} {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : SMulWithZero R S]
  [inst_3 : Monoid S] (f g : LaurentPolynomial R) (x y : Sˣ), f = g → x = y → f.smeval x = g.smeval y

theorem LaurentPolynomial.smeval_zero E0 #

∀ {R : Type u_1} {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : SMulWithZero R S]
  [inst_3 : Monoid S] (x : Sˣ), LaurentPolynomial.smeval 0 x = 0

theorem LaurentPolynomial.smeval_single E1 #

∀ {R : Type u_1} {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : SMulWithZero R S]
  [inst_3 : Monoid S] (x : Sˣ) (n : ℤ) (r : R), LaurentPolynomial.smeval (AddMonoidAlgebra.single n r) x = r • ↑(x ^ n)

theorem LaurentPolynomial.smeval_C_mul_T_n E0 #

∀ {R : Type u_1} {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : SMulWithZero R S]
  [inst_3 : Monoid S] (x : Sˣ) (n : ℤ) (r : R), (LaurentPolynomial.C r * LaurentPolynomial.T n).smeval x = r • ↑(x ^ n)

theorem LaurentPolynomial.smeval_C E0 #

∀ {R : Type u_1} {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : SMulWithZero R S]
  [inst_3 : Monoid S] (x : Sˣ) (r : R), (LaurentPolynomial.C r).smeval x = r • 1

theorem LaurentPolynomial.smeval_T_pow E0 #

∀ {R : Type u_1} {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : MulActionWithZero R S]
  [inst_3 : Monoid S] (n : ℤ) (x : Sˣ), (LaurentPolynomial.T n).smeval x = ↑(x ^ n)

theorem LaurentPolynomial.smeval_one E0 #

∀ {R : Type u_1} {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : MulActionWithZero R S]
  [inst_3 : Monoid S] (x : Sˣ), LaurentPolynomial.smeval 1 x = 1

theorem LaurentPolynomial.smeval_add E0 #

∀ {R : Type u_1} {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : Module R S] [inst_3 : Monoid S]
  (f g : LaurentPolynomial R) (x : Sˣ), (f + g).smeval x = f.smeval x + g.smeval x

theorem LaurentPolynomial.smeval_C_mul E0 #

∀ {R : Type u_1} {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : Module R S] [inst_3 : Monoid S]
  (f : LaurentPolynomial R) (x : Sˣ) (r : R), (LaurentPolynomial.C r * f).smeval x = r • f.smeval x

def LaurentPolynomial.leval E1 #

(R : Type u_1) →
  {S : Type u_2} →
    [inst : Semiring R] →
      [inst_1 : AddCommMonoid S] → [inst_2 : Module R S] → [inst_3 : Monoid S] → Sˣ → LaurentPolynomial R →ₗ[R] S

Evaluation as an R-linear map.

theorem LaurentPolynomial.leval_apply E0 #

∀ (R : Type u_1) {S : Type u_2} [inst : Semiring R] [inst_1 : AddCommMonoid S] [inst_2 : Module R S] [inst_3 : Monoid S]
  (x : Sˣ) (f : LaurentPolynomial R), (LaurentPolynomial.leval R x) f = f.smeval x

theorem LaurentPolynomial.eval₂_eq_smeval E1 #

∀ {R : Type u_1} {S : Type u_2} [inst : CommSemiring R] [inst_1 : CommSemiring S] [inst_2 : Algebra R S]
  (p : LaurentPolynomial R) (x : Sˣ), (LaurentPolynomial.eval₂ (algebraMap R S) x) p = p.smeval x

Deprecated aliases

NameNew nameSince
LaurentPolynomial.support_C_mul_T_of_ne_zeroLaurentPolynomial.support_coeff_C_mul_T_of_ne_zero2026-06-18
LaurentPolynomial.toLaurent_supportLaurentPolynomial.support_coeff_toLaurent2026-06-18