Infinite sums over ℕ
and ℤ
#
This file contains lemmas about HasSum
, Summable
, and tsum
applied to the important special
cases where the domain is ℕ
or ℤ
. For instance, we prove the formula
∑ i in range k, f i + ∑' i, f (i + k) = ∑' i, f i
, in sum_add_tsum_nat_add
, as well as several
results relating sums on ℕ
and ℤ
.
Sums over ℕ
#
If f : ℕ → M
has sum m
, then the partial sums ∑ i in range n, f i
converge to m
.
You can compute a sum over an encodable type by summing over the natural numbers and taking a supremum. This is useful for outer measures.
tsum_iSup_decode₂
specialized to the complete lattice of sets.
Some properties about measure-like functions. These could also be functions defined on complete
sublattices of sets, with the property that they are countably sub-additive.
R
will probably be instantiated with (≤)
in all applications.
If a function is countably sub-additive then it is sub-additive on countable types
If a function is countably sub-additive then it is sub-additive on finite sets
If a function is countably sub-additive then it is binary sub-additive
For f : ℕ → G
, then ∑' k, f (k + i)
tends to zero. This does not require a summability
assumption on f
, as otherwise all sums are zero.
Sums over ℤ
#
In this section we prove a variety of lemmas relating sums over ℕ
to sums over ℤ
.
Alias of HasSum.of_nat_of_neg_add_one
.
If f₀, f₁, f₂, ...
and g₀, g₁, g₂, ...
have sums a
, b
respectively, then the ℤ
-indexed
sequence: ..., g₂, g₁, g₀, f₀, f₁, f₂, ...
(with f₀
at the 0
-th position) has sum a + b
.
If f₀, f₁, f₂, ...
and g₀, g₁, g₂, ...
are both summable then so is the ℤ
-indexed
sequence: ..., g₂, g₁, g₀, f₀, f₁, f₂, ...
(with f₀
at the 0
-th position).
If f₀, f₁, f₂, ...
and g₀, g₁, g₂, ...
are both summable, then the sum of the ℤ
-indexed
sequence: ..., g₂, g₁, g₀, f₀, f₁, f₂, ...
(with f₀
at the 0
-th position) is
∑' n, f n + ∑' n, g n
.
Alias of HasSum.nat_add_neg
.
Alias of HasSum.of_add_one_of_neg_add_one
.
Alias of Summable.of_nat_of_neg
.
"iff" version of Summable.of_nat_of_neg_add_one
.
"iff" version of Summable.of_natCast_neg_natCast
.