Skip to content

Commit c88ae7e

Browse files
committed
feat: port Analysis.Normed.Field.InfiniteSum (#2860)
1 parent c1fa0cc commit c88ae7e

File tree

3 files changed

+126
-0
lines changed

3 files changed

+126
-0
lines changed

Mathlib.lean

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,7 @@ import Mathlib.Algebra.Tropical.Basic
245245
import Mathlib.Algebra.Tropical.BigOperators
246246
import Mathlib.Algebra.Tropical.Lattice
247247
import Mathlib.Analysis.Normed.Field.Basic
248+
import Mathlib.Analysis.Normed.Field.InfiniteSum
248249
import Mathlib.Analysis.Normed.Field.UnitBall
249250
import Mathlib.Analysis.Normed.Group.BallSphere
250251
import Mathlib.Analysis.Normed.Group.Basic
Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
/-
2+
Copyright (c) 2021 Anatole Dedecker. All rights reserved.
3+
Released under Apache 2.0 license as described in the file LICENSE.
4+
Authors: Anatole Dedecker
5+
6+
! This file was ported from Lean 3 source module analysis.normed.field.infinite_sum
7+
! leanprover-community/mathlib commit 008205aa645b3f194c1da47025c5f110c8406eab
8+
! Please do not edit these lines, except to modify the commit id
9+
! if you have ported upstream changes.
10+
-/
11+
import Mathlib.Analysis.Normed.Field.Basic
12+
import Mathlib.Analysis.Normed.Group.InfiniteSum
13+
14+
/-! # Multiplying two infinite sums in a normed ring
15+
16+
In this file, we prove various results about `(∑' x : ι, f x) * (∑' y : ι', g y)` in a normed
17+
ring. There are similar results proven in `Mathlib.Topology.Algebra.InfiniteSum` (e.g
18+
`tsum_mul_tsum`), but in a normed ring we get summability results which aren't true in general.
19+
20+
We first establish results about arbitrary index types, `ι` and `ι'`, and then we specialize to
21+
`ι = ι' = ℕ` to prove the Cauchy product formula
22+
(see `tsum_mul_tsum_eq_tsum_sum_antidiagonal_of_summable_norm`).
23+
-/
24+
25+
26+
variable {R : Type _} {ι : Type _} {ι' : Type _} [NormedRing R]
27+
28+
open BigOperators Classical
29+
30+
open Finset
31+
32+
/-! ### Arbitrary index types -/
33+
34+
theorem Summable.mul_of_nonneg {f : ι → ℝ} {g : ι' → ℝ} (hf : Summable f) (hg : Summable g)
35+
(hf' : 0 ≤ f) (hg' : 0 ≤ g) : Summable fun x : ι × ι' => f x.1 * g x.2 :=
36+
(summable_prod_of_nonneg <| fun _ ↦ mul_nonneg (hf' _) (hg' _)).2fun x ↦ hg.mul_left (f x),
37+
by simpa only [hg.tsum_mul_left _] using hf.mul_right (∑' x, g x)⟩
38+
#align summable.mul_of_nonneg Summable.mul_of_nonneg
39+
40+
theorem Summable.mul_norm {f : ι → R} {g : ι' → R} (hf : Summable fun x => ‖f x‖)
41+
(hg : Summable fun x => ‖g x‖) : Summable fun x : ι × ι' => ‖f x.1 * g x.2‖ :=
42+
summable_of_nonneg_of_le (fun x => norm_nonneg (f x.1 * g x.2))
43+
(fun x => norm_mul_le (f x.1) (g x.2))
44+
(hf.mul_of_nonneg hg (fun x => norm_nonneg <| f x) fun x => norm_nonneg <| g x : _)
45+
#align summable.mul_norm Summable.mul_norm
46+
47+
theorem summable_mul_of_summable_norm [CompleteSpace R] {f : ι → R} {g : ι' → R}
48+
(hf : Summable fun x => ‖f x‖) (hg : Summable fun x => ‖g x‖) :
49+
Summable fun x : ι × ι' => f x.1 * g x.2 :=
50+
summable_of_summable_norm (hf.mul_norm hg)
51+
#align summable_mul_of_summable_norm summable_mul_of_summable_norm
52+
53+
/-- Product of two infinites sums indexed by arbitrary types.
54+
See also `tsum_mul_tsum` if `f` and `g` are *not* absolutely summable. -/
55+
theorem tsum_mul_tsum_of_summable_norm [CompleteSpace R] {f : ι → R} {g : ι' → R}
56+
(hf : Summable fun x => ‖f x‖) (hg : Summable fun x => ‖g x‖) :
57+
((∑' x, f x) * ∑' y, g y) = ∑' z : ι × ι', f z.1 * g z.2 :=
58+
tsum_mul_tsum (summable_of_summable_norm hf) (summable_of_summable_norm hg)
59+
(summable_mul_of_summable_norm hf hg)
60+
#align tsum_mul_tsum_of_summable_norm tsum_mul_tsum_of_summable_norm
61+
62+
/-! ### `ℕ`-indexed families (Cauchy product)
63+
64+
We prove two versions of the Cauchy product formula. The first one is
65+
`tsum_mul_tsum_eq_tsum_sum_range_of_summable_norm`, where the `n`-th term is a sum over
66+
`Finset.range (n+1)` involving `Nat` subtraction.
67+
In order to avoid `Nat` subtraction, we also provide
68+
`tsum_mul_tsum_eq_tsum_sum_antidiagonal_of_summable_norm`,
69+
where the `n`-th term is a sum over all pairs `(k, l)` such that `k+l=n`, which corresponds to the
70+
`Finset` `Finset.Nat.antidiagonal n`. -/
71+
72+
73+
section Nat
74+
75+
open Finset.Nat
76+
77+
theorem summable_norm_sum_mul_antidiagonal_of_summable_norm {f g : ℕ → R}
78+
(hf : Summable fun x => ‖f x‖) (hg : Summable fun x => ‖g x‖) :
79+
Summable fun n => ‖∑ kl in antidiagonal n, f kl.1 * g kl.2‖ := by
80+
have :=
81+
summable_sum_mul_antidiagonal_of_summable_mul
82+
(Summable.mul_of_nonneg hf hg (fun _ => norm_nonneg _) fun _ => norm_nonneg _)
83+
refine' summable_of_nonneg_of_le (fun _ => norm_nonneg _) _ this
84+
intro n
85+
calc
86+
‖∑ kl in antidiagonal n, f kl.1 * g kl.2‖ ≤ ∑ kl in antidiagonal n, ‖f kl.1 * g kl.2‖ :=
87+
norm_sum_le _ _
88+
_ ≤ ∑ kl in antidiagonal n, ‖f kl.1‖ * ‖g kl.2‖ := sum_le_sum fun i _ => norm_mul_le _ _
89+
90+
#align summable_norm_sum_mul_antidiagonal_of_summable_norm summable_norm_sum_mul_antidiagonal_of_summable_norm
91+
92+
/-- The Cauchy product formula for the product of two infinite sums indexed by `ℕ`,
93+
expressed by summing on `Finset.Nat.antidiagonal`.
94+
See also `tsum_mul_tsum_eq_tsum_sum_antidiagonal` if `f` and `g` are
95+
*not* absolutely summable. -/
96+
theorem tsum_mul_tsum_eq_tsum_sum_antidiagonal_of_summable_norm [CompleteSpace R] {f g : ℕ → R}
97+
(hf : Summable fun x => ‖f x‖) (hg : Summable fun x => ‖g x‖) :
98+
((∑' n, f n) * ∑' n, g n) = ∑' n, ∑ kl in antidiagonal n, f kl.1 * g kl.2 :=
99+
tsum_mul_tsum_eq_tsum_sum_antidiagonal (summable_of_summable_norm hf)
100+
(summable_of_summable_norm hg) (summable_mul_of_summable_norm hf hg)
101+
#align tsum_mul_tsum_eq_tsum_sum_antidiagonal_of_summable_norm tsum_mul_tsum_eq_tsum_sum_antidiagonal_of_summable_norm
102+
103+
theorem summable_norm_sum_mul_range_of_summable_norm {f g : ℕ → R} (hf : Summable fun x => ‖f x‖)
104+
(hg : Summable fun x => ‖g x‖) : Summable fun n => ‖∑ k in range (n + 1), f k * g (n - k)‖ := by
105+
simp_rw [← sum_antidiagonal_eq_sum_range_succ fun k l => f k * g l]
106+
exact summable_norm_sum_mul_antidiagonal_of_summable_norm hf hg
107+
#align summable_norm_sum_mul_range_of_summable_norm summable_norm_sum_mul_range_of_summable_norm
108+
109+
/-- The Cauchy product formula for the product of two infinite sums indexed by `ℕ`,
110+
expressed by summing on `Finset.range`.
111+
See also `tsum_mul_tsum_eq_tsum_sum_range` if `f` and `g` are
112+
*not* absolutely summable. -/
113+
theorem tsum_mul_tsum_eq_tsum_sum_range_of_summable_norm [CompleteSpace R] {f g : ℕ → R}
114+
(hf : Summable fun x => ‖f x‖) (hg : Summable fun x => ‖g x‖) :
115+
((∑' n, f n) * ∑' n, g n) = ∑' n, ∑ k in range (n + 1), f k * g (n - k) := by
116+
simp_rw [← sum_antidiagonal_eq_sum_range_succ fun k l => f k * g l]
117+
exact tsum_mul_tsum_eq_tsum_sum_antidiagonal_of_summable_norm hf hg
118+
#align tsum_mul_tsum_eq_tsum_sum_range_of_summable_norm tsum_mul_tsum_eq_tsum_sum_range_of_summable_norm
119+
120+
end Nat
121+

Mathlib/Topology/Instances/ENNReal.lean

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1318,6 +1318,10 @@ theorem summable_sigma_of_nonneg {β : α → Type _} {f : (Σ x, β x) → ℝ}
13181318
exact_mod_cast NNReal.summable_sigma
13191319
#align summable_sigma_of_nonneg summable_sigma_of_nonneg
13201320

1321+
theorem summable_prod_of_nonneg {f : (α × β) → ℝ} (hf : 0 ≤ f) :
1322+
Summable f ↔ (∀ x, Summable fun y ↦ f (x, y)) ∧ Summable fun x ↦ ∑' y, f (x, y) :=
1323+
(Equiv.sigmaEquivProd _ _).summable_iff.symm.trans <| summable_sigma_of_nonneg fun _ ↦ hf _
1324+
13211325
theorem summable_of_sum_le {ι : Type _} {f : ι → ℝ} {c : ℝ} (hf : 0 ≤ f)
13221326
(h : ∀ u : Finset ι, (∑ x in u, f x) ≤ c) : Summable f :=
13231327
⟨⨆ u : Finset ι, ∑ x in u, f x,

0 commit comments

Comments
 (0)