@@ -5,33 +5,100 @@ Authors: Edward Watine
5
5
-/
6
6
import Mathlib.Analysis.Analytic.Basic
7
7
8
-
9
8
/-!
10
9
# Scalar series
11
10
12
11
This file contains API for analytic functions `∑ cᵢ • xⁱ` defined in terms of scalars
13
12
`c₀, c₁, c₂, …`.
14
13
## Main definitions / results:
15
14
* `FormalMultilinearSeries.ofScalars`: the formal power series `∑ cᵢ • xⁱ`.
16
- * `FormalMultilinearSeries.ofScalars_radius_eq_of_tendsto`: the ratio test for an analytic function
17
- defined in terms of a formal power series `∑ cᵢ • xⁱ`.
15
+ * `FormalMultilinearSeries.ofScalarsSum`: the sum of such a power series, if it exists, and zero
16
+ otherwise.
17
+ * `FormalMultilinearSeries.ofScalars_radius_eq_(zero/inv/top)_of_tendsto`:
18
+ the ratio test for an analytic function defined in terms of a formal power series `∑ cᵢ • xⁱ`.
19
+ * `FormalMultilinearSeries.ofScalars_radius_eq_inv_of_tendsto_ENNReal`:
20
+ the ratio test for an analytic function using `ENNReal` division for all values `ℝ≥0∞`.
18
21
-/
19
22
20
23
namespace FormalMultilinearSeries
21
24
22
25
section Field
23
26
27
+ open ContinuousMultilinearMap
28
+
24
29
variable {𝕜 : Type *} (E : Type *) [Field 𝕜] [Ring E] [Algebra 𝕜 E] [TopologicalSpace E]
25
- [TopologicalRing E] ( c : ℕ → 𝕜)
30
+ [TopologicalRing E] { c : ℕ → 𝕜}
26
31
27
32
/-- Formal power series of `∑ cᵢ • xⁱ` for some scalar field `𝕜` and ring algebra `E`-/
28
- def ofScalars : FormalMultilinearSeries 𝕜 E E :=
33
+ def ofScalars (c : ℕ → 𝕜) : FormalMultilinearSeries 𝕜 E E :=
29
34
fun n ↦ c n • ContinuousMultilinearMap.mkPiAlgebraFin 𝕜 n E
30
35
31
- variable {E}
36
+ @[simp]
37
+ theorem ofScalars_eq_zero [Nontrivial E] (n : ℕ) : ofScalars E c n = 0 ↔ c n = 0 := by
38
+ rw [ofScalars, smul_eq_zero (c := c n) (x := ContinuousMultilinearMap.mkPiAlgebraFin 𝕜 n E)]
39
+ refine or_iff_left (ContinuousMultilinearMap.ext_iff.1 .mt <| not_forall_of_exists_not ?_)
40
+ use fun _ ↦ 1
41
+ simp
32
42
33
- /-- The sum of the formal power series. Takes the value `0` outside the radius of convergence. -/
34
- noncomputable def ofScalarsSum (x : E) := (ofScalars E c).sum x
43
+ @[simp]
44
+ theorem ofScalars_eq_zero_of_scalar_zero {n : ℕ} (hc : c n = 0 ) : ofScalars E c n = 0 := by
45
+ rw [ofScalars, hc, zero_smul 𝕜 (ContinuousMultilinearMap.mkPiAlgebraFin 𝕜 n E)]
46
+
47
+ @[simp]
48
+ theorem ofScalars_series_eq_zero [Nontrivial E] : ofScalars E c = 0 ↔ c = 0 := by
49
+ simp [FormalMultilinearSeries.ext_iff, funext_iff]
50
+
51
+ variable (𝕜) in
52
+ @[simp]
53
+ theorem ofScalars_series_eq_zero_of_scalar_zero : ofScalars E (0 : ℕ → 𝕜) = 0 := by
54
+ simp [FormalMultilinearSeries.ext_iff]
55
+
56
+ @[simp]
57
+ theorem ofScalars_series_of_subsingleton [Subsingleton E] : ofScalars E c = 0 := by
58
+ simp_rw [FormalMultilinearSeries.ext_iff, ofScalars, ContinuousMultilinearMap.ext_iff]
59
+ exact fun _ _ ↦ Subsingleton.allEq _ _
60
+
61
+ variable (𝕜) in
62
+ theorem ofScalars_series_injective [Nontrivial E] : Function.Injective (ofScalars E (𝕜 := 𝕜)) := by
63
+ intro _ _
64
+ refine Function.mtr fun h ↦ ?_
65
+ simp_rw [FormalMultilinearSeries.ext_iff, ofScalars, ContinuousMultilinearMap.ext_iff, smul_apply]
66
+ push_neg
67
+ obtain ⟨n, hn⟩ := Function.ne_iff.1 h
68
+ refine ⟨n, fun _ ↦ 1 , ?_⟩
69
+ simp only [mkPiAlgebraFin_apply, List.ofFn_const, List.prod_replicate, one_pow, ne_eq]
70
+ exact (smul_left_injective 𝕜 one_ne_zero).ne hn
71
+
72
+ variable (c)
73
+
74
+ @[simp]
75
+ theorem ofScalars_series_eq_iff [Nontrivial E] (c' : ℕ → 𝕜) :
76
+ ofScalars E c = ofScalars E c' ↔ c = c' :=
77
+ ⟨fun e => ofScalars_series_injective 𝕜 E e, _root_.congrArg _⟩
78
+
79
+ theorem ofScalars_apply_zero (n : ℕ) :
80
+ (ofScalars E c n fun _ => 0 ) = Pi.single (f := fun _ => E) 0 (c 0 • 1 ) n := by
81
+ rw [ofScalars]
82
+ cases n <;> simp
83
+
84
+ theorem ofScalars_add (c' : ℕ → 𝕜) : ofScalars E (c + c') = ofScalars E c + ofScalars E c' := by
85
+ unfold ofScalars
86
+ simp_rw [Pi.add_apply, Pi.add_def _ _]
87
+ exact funext fun n ↦ Module.add_smul (c n) (c' n) (ContinuousMultilinearMap.mkPiAlgebraFin 𝕜 n E)
88
+
89
+ theorem ofScalars_smul (x : 𝕜) : ofScalars E (x • c) = x • ofScalars E c := by
90
+ unfold ofScalars
91
+ simp [Pi.smul_def x _, smul_smul]
92
+
93
+ variable (𝕜) in
94
+ /-- The submodule generated by scalar series on `FormalMultilinearSeries 𝕜 E E`. -/
95
+ def ofScalarsSubmodule : Submodule 𝕜 (FormalMultilinearSeries 𝕜 E E) where
96
+ carrier := {ofScalars E f | f}
97
+ add_mem' := fun ⟨c, hc⟩ ⟨c', hc'⟩ ↦ ⟨c + c', hc' ▸ hc ▸ ofScalars_add E c c'⟩
98
+ zero_mem' := ⟨0 , ofScalars_series_eq_zero_of_scalar_zero 𝕜 E⟩
99
+ smul_mem' := fun x _ ⟨c, hc⟩ ↦ ⟨x • c, hc ▸ ofScalars_smul E c x⟩
100
+
101
+ variable {E}
35
102
36
103
theorem ofScalars_apply_eq (x : E) (n : ℕ) :
37
104
ofScalars E c n (fun _ ↦ x) = c n • x ^ n := by
@@ -42,35 +109,39 @@ theorem ofScalars_apply_eq' (x : E) :
42
109
(fun n ↦ ofScalars E c n (fun _ ↦ x)) = fun n ↦ c n • x ^ n := by
43
110
simp [ofScalars]
44
111
112
+ /-- The sum of the formal power series. Takes the value `0` outside the radius of convergence. -/
113
+ noncomputable def ofScalarsSum := (ofScalars E c).sum
114
+
45
115
theorem ofScalars_sum_eq (x : E) : ofScalarsSum c x =
46
116
∑' n, c n • x ^ n := tsum_congr fun n => ofScalars_apply_eq c x n
47
117
48
118
theorem ofScalarsSum_eq_tsum : ofScalarsSum c =
49
119
fun (x : E) => ∑' n : ℕ, c n • x ^ n := funext (ofScalars_sum_eq c)
50
120
51
121
@[simp]
52
- theorem ofScalars_op [T2Space E] (x : E) :
122
+ theorem ofScalarsSum_zero : ofScalarsSum c (0 : E) = c 0 • 1 := by
123
+ simp [ofScalarsSum_eq_tsum, ← ofScalars_apply_eq, ofScalars_apply_zero]
124
+
125
+ @[simp]
126
+ theorem ofScalarsSum_of_subsingleton [Subsingleton E] {x : E} : ofScalarsSum c x = 0 := by
127
+ simp [Subsingleton.eq_zero x, Subsingleton.eq_zero (1 : E)]
128
+
129
+ @[simp]
130
+ theorem ofScalarsSum_op [T2Space E] (x : E) :
53
131
ofScalarsSum c (MulOpposite.op x) = MulOpposite.op (ofScalarsSum c x) := by
54
132
simp [ofScalars, ofScalars_sum_eq, ← MulOpposite.op_pow, ← MulOpposite.op_smul, tsum_op]
55
133
56
134
@[simp]
57
- theorem ofScalars_unop [T2Space E] (x : Eᵐᵒᵖ) :
135
+ theorem ofScalarsSum_unop [T2Space E] (x : Eᵐᵒᵖ) :
58
136
ofScalarsSum c (MulOpposite.unop x) = MulOpposite.unop (ofScalarsSum c x) := by
59
137
simp [ofScalars, ofScalars_sum_eq, ← MulOpposite.unop_pow, ← MulOpposite.unop_smul, tsum_unop]
60
138
61
- @[simp]
62
- theorem ofScalars_eq_zero [Nontrivial E] (n : ℕ) : ofScalars E c n = 0 ↔ c n = 0 := by
63
- rw [ofScalars, smul_eq_zero (c := c n) (x := ContinuousMultilinearMap.mkPiAlgebraFin 𝕜 n E)]
64
- refine or_iff_left (ContinuousMultilinearMap.ext_iff.1 .mt <| not_forall_of_exists_not ?_)
65
- use fun _ ↦ 1
66
- simp
67
-
68
139
end Field
69
140
70
141
section Normed
71
142
72
- open Filter
73
- open scoped Topology
143
+ open Filter ENNReal
144
+ open scoped Topology NNReal
74
145
75
146
variable {𝕜 : Type *} (E : Type *) [NontriviallyNormedField 𝕜] [NormedRing E]
76
147
[NormedAlgebra 𝕜 E] (c : ℕ → 𝕜) (n : ℕ)
@@ -88,44 +159,142 @@ theorem ofScalars_norm_le (hn : n > 0) : ‖ofScalars E c n‖ ≤ ‖c n‖ :=
88
159
theorem ofScalars_norm [NormOneClass E] : ‖ofScalars E c n‖ = ‖c n‖ := by
89
160
simp [ofScalars_norm_eq_mul]
90
161
91
- /-- The radius of convergence of a scalar series is the inverse of the ratio of the norms of the
92
- coefficients. -/
93
- theorem ofScalars_radius_eq_inv_of_tendsto [NormOneClass E] {r : NNReal} (hr : r ≠ 0 )
162
+ private theorem tendsto_succ_norm_div_norm {r r' : ℝ≥0 } (hr' : r' ≠ 0 )
163
+ (hc : Tendsto (fun n ↦ ‖c n.succ‖ / ‖c n‖) atTop (𝓝 r)) :
164
+ Tendsto (fun n ↦ ‖‖c (n + 1 )‖ * r' ^ (n + 1 )‖ /
165
+ ‖‖c n‖ * r' ^ n‖) atTop (𝓝 ↑(r' * r)) := by
166
+ simp_rw [norm_mul, norm_norm, mul_div_mul_comm, ← norm_div, pow_succ,
167
+ mul_div_right_comm, div_self (pow_ne_zero _ (NNReal.coe_ne_zero.mpr hr')
168
+ ), one_mul, norm_div, NNReal.norm_eq]
169
+ exact mul_comm r' r ▸ hc.mul tendsto_const_nhds
170
+
171
+ theorem ofScalars_radius_ge_inv_of_tendsto {r : ℝ≥0 } (hr : r ≠ 0 )
94
172
(hc : Tendsto (fun n ↦ ‖c n.succ‖ / ‖c n‖) atTop (𝓝 r)) :
95
- (ofScalars E c).radius = ENNReal.ofNNReal r⁻¹ := by
96
- have hc' {r' : NNReal} (hr' : (r' : ℝ) ≠ 0 ) :
97
- Tendsto (fun n ↦ ‖‖ofScalars E c (n + 1 )‖ * r' ^ (n + 1 )‖ /
98
- ‖‖ofScalars E c n‖ * r' ^ n‖) atTop (𝓝 ↑(r' * r)) := by
99
- simp_rw [norm_mul, norm_norm, ofScalars_norm, mul_div_mul_comm, ← norm_div, pow_succ,
100
- mul_div_right_comm, div_self (pow_ne_zero _ hr'), one_mul, norm_div, NNReal.norm_eq]
101
- exact mul_comm r' r ▸ Filter.Tendsto.mul hc tendsto_const_nhds
102
- apply le_antisymm <;> refine ENNReal.le_of_forall_nnreal_lt (fun r' hr' ↦ ?_)
103
- · rw [ENNReal.coe_le_coe, NNReal.le_inv_iff_mul_le hr]
104
- have := FormalMultilinearSeries.summable_norm_mul_pow _ hr'
105
- contrapose! this
106
- have hrz : (r' : ℝ) ≠ 0 := by aesop
107
- apply not_summable_of_ratio_test_tendsto_gt_one this
108
- exact hc' (by aesop)
109
- · rw [ENNReal.coe_lt_coe, NNReal.lt_inv_iff_mul_lt hr] at hr'
110
- by_cases hrz : r' = 0
111
- · simp [hrz]
112
- · apply FormalMultilinearSeries.le_radius_of_summable_norm
113
- refine summable_of_ratio_test_tendsto_lt_one hr' ?_ <| hc' (NNReal.coe_ne_zero.2 hrz)
114
- refine (Tendsto.eventually_ne hc (NNReal.coe_ne_zero.2 hr)).mp (Eventually.of_forall ?_)
115
- simp_rw [div_ne_zero_iff, ofScalars_norm, mul_ne_zero_iff]
173
+ (ofScalars E c).radius ≥ ofNNReal r⁻¹ := by
174
+ refine le_of_forall_nnreal_lt (fun r' hr' ↦ ?_)
175
+ rw [coe_lt_coe, NNReal.lt_inv_iff_mul_lt hr] at hr'
176
+ by_cases hrz : r' = 0
177
+ · simp [hrz]
178
+ apply FormalMultilinearSeries.le_radius_of_summable_norm
179
+ refine Summable.of_norm_bounded_eventually (fun n ↦ ‖‖c n‖ * r' ^ n‖) ?_ ?_
180
+ · refine summable_of_ratio_test_tendsto_lt_one hr' ?_ ?_
181
+ · refine (hc.eventually_ne (NNReal.coe_ne_zero.mpr hr)).mp (Eventually.of_forall ?_)
116
182
aesop
183
+ · simp_rw [norm_norm]
184
+ exact tendsto_succ_norm_div_norm c hrz hc
185
+ · filter_upwards [eventually_cofinite_ne 0 ] with n hn
186
+ simp only [norm_mul, norm_norm, norm_pow, NNReal.norm_eq]
187
+ gcongr
188
+ exact ofScalars_norm_le E c n (Nat.pos_iff_ne_zero.mpr hn)
189
+
190
+ /-- The radius of convergence of a scalar series is the inverse of the non-zero limit
191
+ `fun n ↦ ‖c n.succ‖ / ‖c n‖`. -/
192
+ theorem ofScalars_radius_eq_inv_of_tendsto [NormOneClass E] {r : ℝ≥0 } (hr : r ≠ 0 )
193
+ (hc : Tendsto (fun n ↦ ‖c n.succ‖ / ‖c n‖) atTop (𝓝 r)) :
194
+ (ofScalars E c).radius = ofNNReal r⁻¹ := by
195
+ refine le_antisymm ?_ (ofScalars_radius_ge_inv_of_tendsto E c hr hc)
196
+ refine le_of_forall_nnreal_lt (fun r' hr' ↦ ?_)
197
+ rw [coe_le_coe, NNReal.le_inv_iff_mul_le hr]
198
+ have := FormalMultilinearSeries.summable_norm_mul_pow _ hr'
199
+ contrapose! this
200
+ apply not_summable_of_ratio_test_tendsto_gt_one this
201
+ simp_rw [ofScalars_norm]
202
+ exact tendsto_succ_norm_div_norm c (by aesop) hc
117
203
118
204
/-- A convenience lemma restating the result of `ofScalars_radius_eq_inv_of_tendsto` under
119
205
the inverse ratio. -/
120
206
theorem ofScalars_radius_eq_of_tendsto [NormOneClass E] {r : NNReal} (hr : r ≠ 0 )
121
207
(hc : Tendsto (fun n ↦ ‖c n‖ / ‖c n.succ‖) atTop (𝓝 r)) :
122
- (ofScalars E c).radius = ENNReal. ofNNReal r := by
208
+ (ofScalars E c).radius = ofNNReal r := by
123
209
suffices Tendsto (fun n ↦ ‖c n.succ‖ / ‖c n‖) atTop (𝓝 r⁻¹) by
124
210
convert ofScalars_radius_eq_inv_of_tendsto E c (inv_ne_zero hr) this
125
211
simp
126
- convert (continuousAt_inv₀ <| NNReal.coe_ne_zero.mpr hr).tendsto.comp hc
212
+ convert hc.inv₀ ( NNReal.coe_ne_zero.mpr hr) using 1
127
213
simp
128
214
215
+ /-- The ratio test stating that if `‖c n.succ‖ / ‖c n‖` tends to zero, the radius is unbounded.
216
+ This requires that the coefficients are eventually non-zero as
217
+ `‖c n.succ‖ / 0 = 0` by convention. -/
218
+ theorem ofScalars_radius_eq_top_of_tendsto (hc : ∀ᶠ n in atTop, c n ≠ 0 )
219
+ (hc' : Tendsto (fun n ↦ ‖c n.succ‖ / ‖c n‖) atTop (𝓝 0 )) : (ofScalars E c).radius = ⊤ := by
220
+ refine radius_eq_top_of_summable_norm _ fun r' ↦ ?_
221
+ by_cases hrz : r' = 0
222
+ · apply Summable.comp_nat_add (k := 1 )
223
+ simp [hrz]
224
+ exact (summable_const_iff 0 ).mpr rfl
225
+ · refine Summable.of_norm_bounded_eventually (fun n ↦ ‖‖c n‖ * r' ^ n‖) ?_ ?_
226
+ · apply summable_of_ratio_test_tendsto_lt_one zero_lt_one (hc.mp (Eventually.of_forall ?_))
227
+ · simp only [norm_norm]
228
+ exact mul_zero (_ : ℝ) ▸ tendsto_succ_norm_div_norm _ hrz (NNReal.coe_zero ▸ hc')
229
+ · aesop
230
+ · filter_upwards [eventually_cofinite_ne 0 ] with n hn
231
+ simp only [norm_mul, norm_norm, norm_pow, NNReal.norm_eq]
232
+ gcongr
233
+ exact ofScalars_norm_le E c n (Nat.pos_iff_ne_zero.mpr hn)
234
+
235
+ /-- If `‖c n.succ‖ / ‖c n‖` is unbounded, then the radius of convergence is zero. -/
236
+ theorem ofScalars_radius_eq_zero_of_tendsto [NormOneClass E]
237
+ (hc : Tendsto (fun n ↦ ‖c n.succ‖ / ‖c n‖) atTop atTop) : (ofScalars E c).radius = 0 := by
238
+ suffices (ofScalars E c).radius ≤ 0 by aesop
239
+ refine le_of_forall_nnreal_lt (fun r hr ↦ ?_)
240
+ rw [← coe_zero, coe_le_coe]
241
+ have := FormalMultilinearSeries.summable_norm_mul_pow _ hr
242
+ contrapose! this
243
+ apply not_summable_of_ratio_norm_eventually_ge one_lt_two
244
+ · contrapose! hc
245
+ apply not_tendsto_atTop_of_tendsto_nhds (a:=0 )
246
+ rw [not_frequently] at hc
247
+ apply Tendsto.congr' ?_ tendsto_const_nhds
248
+ filter_upwards [hc] with n hc'
249
+ rw [ofScalars_norm, norm_mul, norm_norm, not_ne_iff, mul_eq_zero] at hc'
250
+ cases hc' <;> aesop
251
+ · filter_upwards [hc.eventually_ge_atTop (2 *r⁻¹), eventually_ne_atTop 0 ] with n hc hn
252
+ simp only [ofScalars_norm, norm_mul, norm_norm, norm_pow, NNReal.norm_eq]
253
+ rw [mul_comm ‖c n‖, ← mul_assoc, ← div_le_div_iff, mul_div_assoc]
254
+ · convert hc
255
+ rw [pow_succ, div_mul_cancel_left₀, NNReal.coe_inv]
256
+ aesop
257
+ · aesop
258
+ · refine Ne.lt_of_le (fun hr' ↦ Not.elim ?_ hc) (norm_nonneg _)
259
+ rw [← hr']
260
+ simp [this]
261
+
262
+ /-- This theorem combines the results of the special cases above, using `ENNReal` division to remove
263
+ the requirement that the ratio is eventually non-zero. -/
264
+ theorem ofScalars_radius_eq_inv_of_tendsto_ENNReal [NormOneClass E] {r : ℝ≥0 ∞}
265
+ (hc' : Tendsto (fun n ↦ ENNReal.ofReal ‖c n.succ‖ / ENNReal.ofReal ‖c n‖) atTop (𝓝 r)) :
266
+ (ofScalars E c).radius = r⁻¹ := by
267
+ rcases ENNReal.trichotomy r with (hr | hr | hr)
268
+ · simp_rw [hr, inv_zero] at hc' ⊢
269
+ by_cases h : (∀ᶠ (n : ℕ) in atTop, c n ≠ 0 )
270
+ · apply ofScalars_radius_eq_top_of_tendsto E c h ?_
271
+ refine Tendsto.congr' ?_ <| (tendsto_toReal zero_ne_top).comp hc'
272
+ filter_upwards [h]
273
+ simp
274
+ · apply (ofScalars E c).radius_eq_top_of_eventually_eq_zero
275
+ simp only [eventually_atTop, not_exists, not_forall, Classical.not_imp, not_not] at h ⊢
276
+ obtain ⟨ti, hti⟩ := eventually_atTop.mp (hc'.eventually_ne zero_ne_top)
277
+ obtain ⟨zi, hzi, z⟩ := h ti
278
+ refine ⟨zi, Nat.le_induction (ofScalars_eq_zero_of_scalar_zero E z) fun n hmn a ↦ ?_⟩
279
+ nontriviality E
280
+ simp only [ofScalars_eq_zero] at a ⊢
281
+ contrapose! hti
282
+ exact ⟨n, hzi.trans hmn, ENNReal.div_eq_top.mpr (by simp [a, hti])⟩
283
+ · simp_rw [hr, inv_top] at hc' ⊢
284
+ apply ofScalars_radius_eq_zero_of_tendsto E c ((tendsto_add_atTop_iff_nat 1 ).mp ?_)
285
+ refine tendsto_ofReal_nhds_top.mp (Tendsto.congr' ?_ ((tendsto_add_atTop_iff_nat 1 ).mpr hc'))
286
+ filter_upwards [hc'.eventually_ne top_ne_zero] with n hn
287
+ apply (ofReal_div_of_pos (Ne.lt_of_le (Ne.symm ?_) (norm_nonneg _))).symm
288
+ aesop
289
+ · have hr' := toReal_ne_zero.mp hr.ne.symm
290
+ have hr'' := toNNReal_ne_zero.mpr hr' -- this result could go in ENNReal
291
+ convert ofScalars_radius_eq_inv_of_tendsto E c hr'' ?_
292
+ · simp [ENNReal.coe_inv hr'', ENNReal.coe_toNNReal (toReal_ne_zero.mp hr.ne.symm).2 ]
293
+ · simp_rw [ENNReal.coe_toNNReal_eq_toReal]
294
+ refine Tendsto.congr' ?_ <| (tendsto_toReal hr'.2 ).comp hc'
295
+ filter_upwards [hc'.eventually_ne hr'.1 , hc'.eventually_ne hr'.2 ]
296
+ simp
297
+
129
298
end Normed
130
299
131
300
end FormalMultilinearSeries
0 commit comments