The binomial theorem for the integers

Content created by Egbert Rijke, Fredrik Bakke, Jonathan Prieto-Cubides and Gregor Perčič.

Created on 2023-02-20.
Last modified on 2024-10-29.

module elementary-number-theory.binomial-theorem-integers where
Imports
open import commutative-algebra.binomial-theorem-commutative-rings

open import elementary-number-theory.addition-integers
open import elementary-number-theory.distance-natural-numbers
open import elementary-number-theory.integers
open import elementary-number-theory.multiplication-integers
open import elementary-number-theory.natural-numbers
open import elementary-number-theory.powers-integers
open import elementary-number-theory.ring-of-integers

open import foundation.homotopies
open import foundation.identity-types

open import linear-algebra.vectors

open import univalent-combinatorics.standard-finite-types

Idea

The binomial theorem for the integers asserts that for any two integers x and y and any natural number n, we have

  (x + y)ⁿ = ∑_{0 ≤ i < n+1} (n choose i) xⁱ yⁿ⁻ⁱ.

The binomial theorem is the 44th theorem on Freek Wiedijk’s list of 100 theorems [Wie].

Definitions

Binomial sums

binomial-sum-ℤ : (n : ) (f : functional-vec  (succ-ℕ n))  
binomial-sum-ℤ = binomial-sum-Commutative-Ring ℤ-Commutative-Ring

Properties

Binomial sums of one and two elements

binomial-sum-one-element-ℤ :
  (f : functional-vec  1)  binomial-sum-ℤ 0 f  head-functional-vec 0 f
binomial-sum-one-element-ℤ =
  binomial-sum-one-element-Commutative-Ring ℤ-Commutative-Ring

binomial-sum-two-elements-ℤ :
  (f : functional-vec  2) 
  binomial-sum-ℤ 1 f  (f (zero-Fin 1)) +ℤ (f (one-Fin 1))
binomial-sum-two-elements-ℤ =
  binomial-sum-two-elements-Commutative-Ring ℤ-Commutative-Ring

Binomial sums are homotopy invariant

htpy-binomial-sum-ℤ :
  (n : ) {f g : functional-vec  (succ-ℕ n)} 
  (f ~ g)  binomial-sum-ℤ n f  binomial-sum-ℤ n g
htpy-binomial-sum-ℤ =
  htpy-binomial-sum-Commutative-Ring ℤ-Commutative-Ring

Multiplication distributes over sums

left-distributive-mul-binomial-sum-ℤ :
  (n : ) (x : ) (f : functional-vec  (succ-ℕ n)) 
  x *ℤ (binomial-sum-ℤ n f)  binomial-sum-ℤ n  i  x *ℤ (f i))
left-distributive-mul-binomial-sum-ℤ =
  left-distributive-mul-binomial-sum-Commutative-Ring ℤ-Commutative-Ring

right-distributive-mul-binomial-sum-ℤ :
  (n : ) (f : functional-vec  (succ-ℕ n)) (x : ) 
  (binomial-sum-ℤ n f) *ℤ x  binomial-sum-ℤ n  i  (f i) *ℤ x)
right-distributive-mul-binomial-sum-ℤ =
  right-distributive-mul-binomial-sum-Commutative-Ring
    ℤ-Commutative-Ring

Theorem

Binomial theorem for the integers

binomial-theorem-ℤ :
  (n : ) (x y : ) 
  power-ℤ n (x +ℤ y) 
  binomial-sum-ℤ n
    ( λ i 
        ( power-ℤ (nat-Fin (succ-ℕ n) i) x) *ℤ
        ( power-ℤ (dist-ℕ (nat-Fin (succ-ℕ n) i) n) y))
binomial-theorem-ℤ = binomial-theorem-Commutative-Ring ℤ-Commutative-Ring

References

[Wie]
Freek Wiedijk. Formalizing 100 theorems. URL: https://www.cs.ru.nl/~freek/100/.

Recent changes