Big operators and fin
#
THIS FILE IS SYNCHRONIZED WITH MATHLIB4. Any changes to this file require a corresponding PR to mathlib4.
Some results about products and sums over the type fin
.
The most important results are the induction formulas fin.prod_univ_cast_succ
and fin.prod_univ_succ
, and the formula fin.prod_const
for the product of a
constant function. These results have variants for sums instead of products.
Main declarations #
fin_function_fin_equiv
: An explicit equivalence betweenfin n → fin m
andfin (m ^ n)
.
A sum of a function f : fin 0 → β
is 0
because fin 0
is empty
A product of a function f : fin 0 → β
is 1
because fin 0
is empty
A product of a function f : fin (n + 1) → β
over all fin (n + 1)
is the product of f x
, for some x : fin (n + 1)
times the remaining product
A sum of a function f : fin (n + 1) → β
over all fin (n + 1)
is the sum of f x
,
for some x : fin (n + 1)
plus the remaining product
A product of a function f : fin (n + 1) → β
over all fin (n + 1)
is the product of f 0
plus the remaining product
A sum of a function f : fin (n + 1) → β
over all fin (n + 1)
is the sum of f 0
plus the remaining product
A sum of a function f : fin (n + 1) → β
over all fin (n + 1)
is the sum of
f (fin.last n)
plus the remaining sum
A product of a function f : fin (n + 1) → β
over all fin (n + 1)
is the product of f (fin.last n)
plus the remaining product
For f = (a₁, ..., aₙ)
in αⁿ
, partial_prod f
is (1, a₁, a₁a₂, ..., a₁...aₙ)
in αⁿ⁺¹
.
Equations
- fin.partial_prod f i = (list.take ↑i (list.of_fn f)).prod
For f = (a₁, ..., aₙ)
in αⁿ
, partial_sum f
is
(0, a₁, a₁ + a₂, ..., a₁ + ... + aₙ)
in αⁿ⁺¹
.
Equations
- fin.partial_sum f i = (list.take ↑i (list.of_fn f)).sum
Let (g₀, g₁, ..., gₙ)
be a tuple of elements in Gⁿ⁺¹
.
Then if k < j
, this says -(g₀ + g₁ + ... + gₖ₋₁) + (g₀ + g₁ + ... + gₖ) = gₖ
.
If k = j
, it says -(g₀ + g₁ + ... + gₖ₋₁) + (g₀ + g₁ + ... + gₖ₊₁) = gₖ + gₖ₊₁
.
If k > j
, it says -(g₀ + g₁ + ... + gₖ) + (g₀ + g₁ + ... + gₖ₊₁) = gₖ₊₁.
Useful for defining group cohomology.
Let (g₀, g₁, ..., gₙ)
be a tuple of elements in Gⁿ⁺¹
.
Then if k < j
, this says (g₀g₁...gₖ₋₁)⁻¹ * g₀g₁...gₖ = gₖ
.
If k = j
, it says (g₀g₁...gₖ₋₁)⁻¹ * g₀g₁...gₖ₊₁ = gₖgₖ₊₁
.
If k > j
, it says (g₀g₁...gₖ)⁻¹ * g₀g₁...gₖ₊₁ = gₖ₊₁.
Useful for defining group cohomology.
Equivalence between Π i : fin m, fin (n i)
and fin (∏ i : fin m, n i)
.
Equations
- fin_pi_fin_equiv = equiv.of_right_inverse_of_card_le fin_pi_fin_equiv._proof_1 (λ (f : Π (i : fin m), fin (n i)), ⟨finset.univ.sum (λ (i : fin m), ↑(f i) * finset.univ.prod (λ (j : fin ↑i), n (⇑(fin.cast_le _) j))), _⟩) (λ (a : fin (finset.univ.prod (λ (i : fin m), n i))) (b : fin m), ⟨↑a / finset.univ.prod (λ (j : fin ↑b), n (⇑(fin.cast_le _) j)) % n b, _⟩) fin_pi_fin_equiv._proof_6