analysis.analytic.composition
⟷
Mathlib.Analysis.Analytic.Composition
The following section lists changes to this file in mathlib3 and mathlib4 that occured after the initial port. Most recent changes are shown first. Hovering over a commit will show all commits associated with the same mathlib3 commit.
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(last sync)
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Johan Commelin
-/
import Analysis.Analytic.Basic
-import Combinatorics.Composition
+import Combinatorics.Enumerative.Composition
#align_import analysis.analytic.composition from "leanprover-community/mathlib"@"d07a9c875ed7139abfde6a333b2be205c5bd404e"
@@ -593,7 +593,7 @@ theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
convert (NNReal.summable_geometric (NNReal.div_lt_one_of_lt one_lt_two)).hMul_left (1 / 4)
ext1 n
rw [(this _).tsum_eq, add_tsub_cancel_right]
- field_simp [← mul_assoc, pow_succ', mul_pow, show (4 : ℝ≥0) = 2 * 2 from (two_mul 2).symm,
+ field_simp [← mul_assoc, pow_succ, mul_pow, show (4 : ℝ≥0) = 2 * 2 from (two_mul 2).symm,
mul_right_comm]
#align formal_multilinear_series.comp_summable_nnreal FormalMultilinearSeries.comp_summable_nnreal
-/
@@ -919,13 +919,13 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
have B₁ : ContinuousAt (fun z : F => g (f x + z)) (f (x + y) - f x) :=
by
refine' ContinuousAt.comp _ (continuous_const.add continuous_id).ContinuousAt
- simp only [add_sub_cancel'_right, id.def]
+ simp only [add_sub_cancel, id.def]
exact Hg.continuous_on.continuous_at (IsOpen.mem_nhds EMetric.isOpen_ball fy_mem)
have B₂ : f (x + y) - f x ∈ EMetric.ball (0 : F) rg := by
simpa [edist_eq_coe_nnnorm, edist_eq_coe_nnnorm_sub] using fy_mem
rw [← emetric.is_open_ball.nhds_within_eq B₂] at A
convert Hg.tendsto_locally_uniformly_on.tendsto_comp B₁.continuous_within_at B₂ A
- simp only [add_sub_cancel'_right]
+ simp only [add_sub_cancel]
-- Third step: the sum over all compositions in `comp_partial_sum_target 0 n n` converges to
-- `g (f (x + y))`. As this sum is exactly the composition of the partial sum, this is a direct
-- consequence of the second step
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -543,7 +543,7 @@ theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
fact that there are `2^(n-1)` compositions of `n`, giving at most a geometric loss. -/
rcases ENNReal.lt_iff_exists_nnreal_btwn.1 (lt_min zero_lt_one hq) with ⟨rq, rq_pos, hrq⟩
rcases ENNReal.lt_iff_exists_nnreal_btwn.1 (lt_min zero_lt_one hp) with ⟨rp, rp_pos, hrp⟩
- simp only [lt_min_iff, ENNReal.coe_lt_one_iff, ENNReal.coe_pos] at hrp hrq rp_pos rq_pos
+ simp only [lt_min_iff, ENNReal.coe_lt_one_iff, ENNReal.coe_pos] at hrp hrq rp_pos rq_pos
obtain ⟨Cq, hCq0, hCq⟩ : ∃ Cq > 0, ∀ n, ‖q n‖₊ * rq ^ n ≤ Cq :=
q.nnnorm_mul_pow_le_of_lt_radius hrq.2
obtain ⟨Cp, hCp1, hCp⟩ : ∃ Cp ≥ 1, ∀ n, ‖p n‖₊ * rp ^ n ≤ Cp :=
@@ -661,9 +661,9 @@ power series -/
def compChangeOfVariables (m M N : ℕ) (i : Σ n, Fin n → ℕ) (hi : i ∈ compPartialSumSource m M N) :
Σ n, Composition n := by
rcases i with ⟨n, f⟩
- rw [mem_comp_partial_sum_source_iff] at hi
+ rw [mem_comp_partial_sum_source_iff] at hi
refine' ⟨∑ j, f j, of_fn fun a => f a, fun i hi' => _, by simp [sum_of_fn]⟩
- obtain ⟨j, rfl⟩ : ∃ j : Fin n, f j = i := by rwa [mem_of_fn, Set.mem_range] at hi'
+ obtain ⟨j, rfl⟩ : ∃ j : Fin n, f j = i := by rwa [mem_of_fn, Set.mem_range] at hi'
exact (hi.2 j).1
#align formal_multilinear_series.comp_change_of_variables FormalMultilinearSeries.compChangeOfVariables
-/
@@ -710,7 +710,7 @@ theorem compPartialSumTargetSet_image_compPartialSumSource (m M N : ℕ) (i : Σ
by
rcases i with ⟨n, c⟩
refine' ⟨⟨c.length, c.blocks_fun⟩, _, _⟩
- · simp only [comp_partial_sum_target_set, Set.mem_setOf_eq] at hi
+ · simp only [comp_partial_sum_target_set, Set.mem_setOf_eq] at hi
simp only [mem_comp_partial_sum_source_iff, hi.left, hi.right, true_and_iff, and_true_iff]
exact fun a => c.one_le_blocks' _
· dsimp [comp_change_of_variables]
@@ -756,7 +756,7 @@ theorem compChangeOfVariables_sum {α : Type _} [AddCommMonoid α] (m M N : ℕ)
-- between the index sets of the two sums.
-- 1 - show that the image belongs to `comp_partial_sum_target m N N`
· rintro ⟨k, blocks_fun⟩ H
- rw [mem_comp_partial_sum_source_iff] at H
+ rw [mem_comp_partial_sum_source_iff] at H
simp only [mem_comp_partial_sum_target_iff, Composition.length, Composition.blocks, H.left,
map_of_fn, length_of_fn, true_and_iff, comp_change_of_variables]
intro j
@@ -769,7 +769,7 @@ theorem compChangeOfVariables_sum {α : Type _} [AddCommMonoid α] (m M N : ℕ)
obtain rfl : k = k' :=
by
have := (comp_change_of_variables_length m M N H).symm
- rwa [HEq, comp_change_of_variables_length] at this
+ rwa [HEq, comp_change_of_variables_length] at this
congr
funext i
calc
@@ -923,7 +923,7 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
exact Hg.continuous_on.continuous_at (IsOpen.mem_nhds EMetric.isOpen_ball fy_mem)
have B₂ : f (x + y) - f x ∈ EMetric.ball (0 : F) rg := by
simpa [edist_eq_coe_nnnorm, edist_eq_coe_nnnorm_sub] using fy_mem
- rw [← emetric.is_open_ball.nhds_within_eq B₂] at A
+ rw [← emetric.is_open_ball.nhds_within_eq B₂] at A
convert Hg.tendsto_locally_uniformly_on.tendsto_comp B₁.continuous_within_at B₂ A
simp only [add_sub_cancel'_right]
-- Third step: the sum over all compositions in `comp_partial_sum_target 0 n n` converges to
@@ -956,9 +956,9 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
rw [Finset.prod_const, Finset.card_fin]
apply pow_le_pow_left (norm_nonneg _)
- rw [EMetric.mem_ball, edist_eq_coe_nnnorm] at hy
+ rw [EMetric.mem_ball, edist_eq_coe_nnnorm] at hy
have := le_trans (le_of_lt hy) (min_le_right _ _)
- rwa [ENNReal.coe_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
+ rwa [ENNReal.coe_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
tendsto_nhds_of_cauchySeq_of_subseq cau comp_partial_sum_target_tendsto_at_top C
-- Fifth step: the sum over `n` of `q.comp p n` can be expressed as a particular resummation of
-- the sum over all compositions, by grouping together the compositions of the same
@@ -1073,18 +1073,18 @@ theorem sigma_pi_composition_eq_iff
refine' ⟨fun H => by rw [H], fun H => _⟩
rcases u with ⟨a, b⟩
rcases v with ⟨a', b'⟩
- dsimp at H
+ dsimp at H
have h : a = a' := by
ext1
have :
map List.sum (of_fn fun i : Fin (Composition.length a) => (b i).blocks) =
map List.sum (of_fn fun i : Fin (Composition.length a') => (b' i).blocks) :=
by rw [H]
- simp only [map_of_fn] at this
+ simp only [map_of_fn] at this
change
(of_fn fun i : Fin (Composition.length a) => (b i).blocks.Sum) =
of_fn fun i : Fin (Composition.length a') => (b' i).blocks.Sum at
- this
+ this
simpa [Composition.blocks_sum, Composition.ofFn_blocksFun] using this
induction h
simp only [true_and_iff, eq_self_iff_true, heq_iff_eq]
@@ -1093,7 +1093,7 @@ theorem sigma_pi_composition_eq_iff
nth_le (of_fn fun i : Fin (Composition.length a) => (b i).blocks) i (by simp [i.is_lt]) =
nth_le (of_fn fun i : Fin (Composition.length a) => (b' i).blocks) i (by simp [i.is_lt]) :=
nth_le_of_eq H _
- rwa [nth_le_of_fn, nth_le_of_fn] at this
+ rwa [nth_le_of_fn, nth_le_of_fn] at this
#align composition.sigma_pi_composition_eq_iff Composition.sigma_pi_composition_eq_iff
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -370,12 +370,12 @@ theorem compAlongComposition_bound {n : ℕ} (p : FormalMultilinearSeries 𝕜 E
‖f.compAlongComposition p c v‖ ≤ (‖f‖ * ∏ i, ‖p (c.blocksFun i)‖) * ∏ i : Fin n, ‖v i‖ :=
calc
‖f.compAlongComposition p c v‖ = ‖f (p.applyComposition c v)‖ := rfl
- _ ≤ ‖f‖ * ∏ i, ‖p.applyComposition c v i‖ := (ContinuousMultilinearMap.le_op_norm _ _)
+ _ ≤ ‖f‖ * ∏ i, ‖p.applyComposition c v i‖ := (ContinuousMultilinearMap.le_opNorm _ _)
_ ≤ ‖f‖ * ∏ i, ‖p (c.blocksFun i)‖ * ∏ j : Fin (c.blocksFun i), ‖(v ∘ c.Embedding i) j‖ :=
by
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
refine' Finset.prod_le_prod (fun i hi => norm_nonneg _) fun i hi => _
- apply ContinuousMultilinearMap.le_op_norm
+ apply ContinuousMultilinearMap.le_opNorm
_ =
(‖f‖ * ∏ i, ‖p (c.blocksFun i)‖) *
∏ (i) (j : Fin (c.blocksFun i)), ‖(v ∘ c.Embedding i) j‖ :=
@@ -393,7 +393,7 @@ the norms of the relevant bits of `q` and `p`. -/
theorem compAlongComposition_norm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) (c : Composition n) :
‖q.compAlongComposition p c‖ ≤ ‖q c.length‖ * ∏ i, ‖p (c.blocksFun i)‖ :=
- ContinuousMultilinearMap.op_norm_le_bound _
+ ContinuousMultilinearMap.opNorm_le_bound _
(mul_nonneg (norm_nonneg _) (Finset.prod_nonneg fun i hi => norm_nonneg _))
(compAlongComposition_bound _ _ _)
#align formal_multilinear_series.comp_along_composition_norm FormalMultilinearSeries.compAlongComposition_norm
@@ -950,7 +950,7 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
calc
‖(comp_along_composition q p c) fun j : Fin n => y‖ ≤
‖comp_along_composition q p c‖ * ∏ j : Fin n, ‖y‖ :=
- by apply ContinuousMultilinearMap.le_op_norm
+ by apply ContinuousMultilinearMap.le_opNorm
_ ≤ ‖comp_along_composition q p c‖ * (r : ℝ) ^ n :=
by
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -569,7 +569,7 @@ theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
simp only [Finset.prod_mul_distrib, Finset.prod_pow_eq_pow_sum, c.sum_blocks_fun]
_ ≤ ∏ i : Fin c.length, Cp := (Finset.prod_le_prod' fun i _ => hCp _)
_ = Cp ^ c.length := by simp
- _ ≤ Cp ^ n := pow_le_pow hCp1 c.length_le
+ _ ≤ Cp ^ n := pow_le_pow_right hCp1 c.length_le
calc
‖q.comp_along_composition p c‖₊ * r ^ n ≤
(‖q c.length‖₊ * ∏ i, ‖p (c.blocks_fun i)‖₊) * r ^ n :=
@@ -955,7 +955,7 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
by
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
rw [Finset.prod_const, Finset.card_fin]
- apply pow_le_pow_of_le_left (norm_nonneg _)
+ apply pow_le_pow_left (norm_nonneg _)
rw [EMetric.mem_ball, edist_eq_coe_nnnorm] at hy
have := le_trans (le_of_lt hy) (min_le_right _ _)
rwa [ENNReal.coe_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -403,7 +403,7 @@ theorem compAlongComposition_norm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F
theorem compAlongComposition_nnnorm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) (c : Composition n) :
‖q.compAlongComposition p c‖₊ ≤ ‖q c.length‖₊ * ∏ i, ‖p (c.blocksFun i)‖₊ := by
- rw [← NNReal.coe_le_coe]; push_cast ; exact q.comp_along_composition_norm p c
+ rw [← NNReal.coe_le_coe]; push_cast; exact q.comp_along_composition_norm p c
#align formal_multilinear_series.comp_along_composition_nnnorm FormalMultilinearSeries.compAlongComposition_nnnorm
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/ce64cd319bb6b3e82f31c2d38e79080d377be451
@@ -3,8 +3,8 @@ Copyright (c) 2020 Sébastien Gouëzel. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Johan Commelin
-/
-import Mathbin.Analysis.Analytic.Basic
-import Mathbin.Combinatorics.Composition
+import Analysis.Analytic.Basic
+import Combinatorics.Composition
#align_import analysis.analytic.composition from "leanprover-community/mathlib"@"d07a9c875ed7139abfde6a333b2be205c5bd404e"
mathlib commit https://github.com/leanprover-community/mathlib/commit/32a7e535287f9c73f2e4d2aef306a39190f0b504
@@ -590,7 +590,7 @@ theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
convert hasSum_fintype fun c : Composition n => (4 ^ n : ℝ≥0)⁻¹
simp [Finset.card_univ, composition_card, div_eq_mul_inv]
refine' NNReal.summable_sigma.2 ⟨fun n => (this n).Summable, (NNReal.summable_nat_add_iff 1).1 _⟩
- convert (NNReal.summable_geometric (NNReal.div_lt_one_of_lt one_lt_two)).mul_left (1 / 4)
+ convert (NNReal.summable_geometric (NNReal.div_lt_one_of_lt one_lt_two)).hMul_left (1 / 4)
ext1 n
rw [(this _).tsum_eq, add_tsub_cancel_right]
field_simp [← mul_assoc, pow_succ', mul_pow, show (4 : ℝ≥0) = 2 * 2 from (two_mul 2).symm,
mathlib commit https://github.com/leanprover-community/mathlib/commit/8ea5598db6caeddde6cb734aa179cc2408dbd345
@@ -2,15 +2,12 @@
Copyright (c) 2020 Sébastien Gouëzel. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Johan Commelin
-
-! This file was ported from Lean 3 source module analysis.analytic.composition
-! leanprover-community/mathlib commit d07a9c875ed7139abfde6a333b2be205c5bd404e
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathbin.Analysis.Analytic.Basic
import Mathbin.Combinatorics.Composition
+#align_import analysis.analytic.composition from "leanprover-community/mathlib"@"d07a9c875ed7139abfde6a333b2be205c5bd404e"
+
/-!
# Composition of analytic functions
mathlib commit https://github.com/leanprover-community/mathlib/commit/2fe465deb81bcd7ccafa065bb686888a82f15372
@@ -118,7 +118,7 @@ def applyComposition (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ} (c : Compo
#print FormalMultilinearSeries.applyComposition_ones /-
theorem applyComposition_ones (p : FormalMultilinearSeries 𝕜 E F) (n : ℕ) :
p.applyComposition (Composition.ones n) = fun v i =>
- p 1 fun _ => v (Fin.castLE (Composition.length_le _) i) :=
+ p 1 fun _ => v (Fin.castLEEmb (Composition.length_le _) i) :=
by
funext v i
apply p.congr (Composition.ones_blocksFun _ _)
mathlib commit https://github.com/leanprover-community/mathlib/commit/2a0ce625dbb0ffbc7d1316597de0b25c1ec75303
@@ -154,7 +154,7 @@ theorem applyComposition_single (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
theorem removeZero_applyComposition (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
(c : Composition n) : p.removeZero.applyComposition c = p.applyComposition c :=
by
- ext (v i)
+ ext v i
simp [apply_composition, zero_lt_one.trans_le (c.one_le_blocks_fun i), remove_zero_of_pos]
#align formal_multilinear_series.remove_zero_apply_composition FormalMultilinearSeries.removeZero_applyComposition
-/
@@ -1317,7 +1317,7 @@ open Composition
theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) : (r.comp q).comp p = r.comp (q.comp p) :=
by
- ext (n v)
+ ext n v
/- First, rewrite the two compositions appearing in the theorem as two sums over complicated
sigma types, as in the description of the proof above. -/
let f : (Σ a : Composition n, Composition a.length) → H := fun c =>
mathlib commit https://github.com/leanprover-community/mathlib/commit/9f55d0d4363ae59948c33864cbc52e0b12e0e8ce
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Johan Commelin
! This file was ported from Lean 3 source module analysis.analytic.composition
-! leanprover-community/mathlib commit ce11c3c2a285bbe6937e26d9792fda4e51f3fe1a
+! leanprover-community/mathlib commit d07a9c875ed7139abfde6a333b2be205c5bd404e
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
@@ -14,6 +14,9 @@ import Mathbin.Combinatorics.Composition
/-!
# Composition of analytic functions
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
+
In this file we prove that the composition of analytic functions is analytic.
The argument is the following. Assume `g z = ∑' qₙ (z, ..., z)` and `f y = ∑' pₖ (y, ..., y)`. Then
mathlib commit https://github.com/leanprover-community/mathlib/commit/9fb8964792b4237dac6200193a0d533f1b3f7423
@@ -102,6 +102,7 @@ possible compositions of `n`.
-/
+#print FormalMultilinearSeries.applyComposition /-
/-- Given a formal multilinear series `p`, a composition `c` of `n` and the index `i` of a
block of `c`, we may define a function on `fin n → E` by picking the variables in the `i`-th block
of `n`, and applying the corresponding coefficient of `p` to these variables. This function is
@@ -109,7 +110,9 @@ called `p.apply_composition c v i` for `v : fin n → E` and `i : fin c.length`.
def applyComposition (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ} (c : Composition n) :
(Fin n → E) → Fin c.length → F := fun v i => p (c.blocksFun i) (v ∘ c.Embedding i)
#align formal_multilinear_series.apply_composition FormalMultilinearSeries.applyComposition
+-/
+#print FormalMultilinearSeries.applyComposition_ones /-
theorem applyComposition_ones (p : FormalMultilinearSeries 𝕜 E F) (n : ℕ) :
p.applyComposition (Composition.ones n) = fun v i =>
p 1 fun _ => v (Fin.castLE (Composition.length_le _) i) :=
@@ -121,7 +124,9 @@ theorem applyComposition_ones (p : FormalMultilinearSeries 𝕜 E F) (n : ℕ) :
refine' congr_arg v _
rw [Fin.ext_iff, Fin.coe_castLE, Composition.ones_embedding, Fin.val_mk]
#align formal_multilinear_series.apply_composition_ones FormalMultilinearSeries.applyComposition_ones
+-/
+#print FormalMultilinearSeries.applyComposition_single /-
theorem applyComposition_single (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ} (hn : 0 < n)
(v : Fin n → E) : p.applyComposition (Composition.single n hn) v = fun j => p n v :=
by
@@ -139,7 +144,9 @@ theorem applyComposition_single (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
| assumption
| simp
#align formal_multilinear_series.apply_composition_single FormalMultilinearSeries.applyComposition_single
+-/
+#print FormalMultilinearSeries.removeZero_applyComposition /-
@[simp]
theorem removeZero_applyComposition (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
(c : Composition n) : p.removeZero.applyComposition c = p.applyComposition c :=
@@ -147,7 +154,9 @@ theorem removeZero_applyComposition (p : FormalMultilinearSeries 𝕜 E F) {n :
ext (v i)
simp [apply_composition, zero_lt_one.trans_le (c.one_le_blocks_fun i), remove_zero_of_pos]
#align formal_multilinear_series.remove_zero_apply_composition FormalMultilinearSeries.removeZero_applyComposition
+-/
+#print FormalMultilinearSeries.applyComposition_update /-
/-- Technical lemma stating how `p.apply_composition` commutes with updating variables. This
will be the key point to show that functions constructed from `apply_composition` retain
multilinearity. -/
@@ -177,13 +186,16 @@ theorem applyComposition_update (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
apply Function.update_comp_eq_of_not_mem_range
rwa [c.mem_range_embedding_iff']
#align formal_multilinear_series.apply_composition_update FormalMultilinearSeries.applyComposition_update
+-/
+#print FormalMultilinearSeries.compContinuousLinearMap_applyComposition /-
@[simp]
theorem compContinuousLinearMap_applyComposition {n : ℕ} (p : FormalMultilinearSeries 𝕜 F G)
(f : E →L[𝕜] F) (c : Composition n) (v : Fin n → E) :
(p.compContinuousLinearMap f).applyComposition c v = p.applyComposition c (f ∘ v) := by
simp [apply_composition]
#align formal_multilinear_series.comp_continuous_linear_map_apply_composition FormalMultilinearSeries.compContinuousLinearMap_applyComposition
+-/
end FormalMultilinearSeries
@@ -195,6 +207,7 @@ variable [TopologicalAddGroup E] [ContinuousConstSMul 𝕜 E]
variable [TopologicalAddGroup F] [ContinuousConstSMul 𝕜 F]
+#print ContinuousMultilinearMap.compAlongComposition /-
/-- Given a formal multilinear series `p`, a composition `c` of `n` and a continuous multilinear
map `f` in `c.length` variables, one may form a continuous multilinear map in `n` variables by
applying the right coefficient of `p` to each block of the composition, and then applying `f` to
@@ -214,13 +227,16 @@ def compAlongComposition {n : ℕ} (p : FormalMultilinearSeries 𝕜 E F) (c : C
f.cont.comp <|
continuous_pi fun i => (coe_continuous _).comp <| continuous_pi fun j => continuous_apply _
#align continuous_multilinear_map.comp_along_composition ContinuousMultilinearMap.compAlongComposition
+-/
+#print ContinuousMultilinearMap.compAlongComposition_apply /-
@[simp]
theorem compAlongComposition_apply {n : ℕ} (p : FormalMultilinearSeries 𝕜 E F) (c : Composition n)
(f : ContinuousMultilinearMap 𝕜 (fun i : Fin c.length => F) G) (v : Fin n → E) :
(f.compAlongComposition p c) v = f (p.applyComposition c v) :=
rfl
#align continuous_multilinear_map.comp_along_composition_apply ContinuousMultilinearMap.compAlongComposition_apply
+-/
end ContinuousMultilinearMap
@@ -232,6 +248,7 @@ variable [TopologicalAddGroup F] [ContinuousConstSMul 𝕜 F]
variable [TopologicalAddGroup G] [ContinuousConstSMul 𝕜 G]
+#print FormalMultilinearSeries.compAlongComposition /-
/-- Given two formal multilinear series `q` and `p` and a composition `c` of `n`, one may
form a continuous multilinear map in `n` variables by applying the right coefficient of `p` to each
block of the composition, and then applying `q c.length` to the resulting vector. It is
@@ -241,14 +258,18 @@ def compAlongComposition {n : ℕ} (q : FormalMultilinearSeries 𝕜 F G)
ContinuousMultilinearMap 𝕜 (fun i : Fin n => E) G :=
(q c.length).compAlongComposition p c
#align formal_multilinear_series.comp_along_composition FormalMultilinearSeries.compAlongComposition
+-/
+#print FormalMultilinearSeries.compAlongComposition_apply /-
@[simp]
theorem compAlongComposition_apply {n : ℕ} (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) (c : Composition n) (v : Fin n → E) :
(q.compAlongComposition p c) v = q c.length (p.applyComposition c v) :=
rfl
#align formal_multilinear_series.comp_along_composition_apply FormalMultilinearSeries.compAlongComposition_apply
+-/
+#print FormalMultilinearSeries.comp /-
/-- Formal composition of two formal multilinear series. The `n`-th coefficient in the composition
is defined to be the sum of `q.comp_along_composition p c` over all compositions of
`n`. In other words, this term (as a multilinear function applied to `v_0, ..., v_{n-1}`) is
@@ -261,7 +282,9 @@ We give a general formula but which ignores the value of `p 0` instead.
protected def comp (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultilinearSeries 𝕜 E F) :
FormalMultilinearSeries 𝕜 E G := fun n => ∑ c : Composition n, q.compAlongComposition p c
#align formal_multilinear_series.comp FormalMultilinearSeries.comp
+-/
+#print FormalMultilinearSeries.comp_coeff_zero /-
/-- The `0`-th coefficient of `q.comp p` is `q 0`. Since these maps are multilinear maps in zero
variables, but on different spaces, we can not state this directly, so we state it when applied to
arbitrary vectors (which have to be the zero vector). -/
@@ -275,19 +298,25 @@ theorem comp_coeff_zero (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultil
rw [← this, Finset.sum_singleton, comp_along_composition_apply]
symm; congr
#align formal_multilinear_series.comp_coeff_zero FormalMultilinearSeries.comp_coeff_zero
+-/
+#print FormalMultilinearSeries.comp_coeff_zero' /-
@[simp]
theorem comp_coeff_zero' (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultilinearSeries 𝕜 E F)
(v : Fin 0 → E) : (q.comp p) 0 v = q 0 fun i => 0 :=
q.comp_coeff_zero p v _
#align formal_multilinear_series.comp_coeff_zero' FormalMultilinearSeries.comp_coeff_zero'
+-/
+#print FormalMultilinearSeries.comp_coeff_zero'' /-
/-- The `0`-th coefficient of `q.comp p` is `q 0`. When `p` goes from `E` to `E`, this can be
expressed as a direct equality -/
theorem comp_coeff_zero'' (q : FormalMultilinearSeries 𝕜 E F) (p : FormalMultilinearSeries 𝕜 E E) :
(q.comp p) 0 = q 0 := by ext v; exact q.comp_coeff_zero p _ _
#align formal_multilinear_series.comp_coeff_zero'' FormalMultilinearSeries.comp_coeff_zero''
+-/
+#print FormalMultilinearSeries.comp_coeff_one /-
/-- The first coefficient of a composition of formal multilinear series is the composition of the
first coefficients seen as continuous linear maps. -/
theorem comp_coeff_one (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultilinearSeries 𝕜 E F)
@@ -301,7 +330,9 @@ theorem comp_coeff_one (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultili
simp only [apply_composition_ones]
exact p.congr rfl fun j hj1 hj2 => by congr
#align formal_multilinear_series.comp_coeff_one FormalMultilinearSeries.comp_coeff_one
+-/
+#print FormalMultilinearSeries.removeZero_comp_of_pos /-
/-- Only `0`-th coefficient of `q.comp p` depends on `q 0`. -/
theorem removeZero_comp_of_pos (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) {n : ℕ} (hn : 0 < n) : q.removeZero.comp p n = q.comp p n :=
@@ -312,11 +343,14 @@ theorem removeZero_comp_of_pos (q : FormalMultilinearSeries 𝕜 F G)
apply Finset.sum_congr rfl fun c hc => _
rw [remove_zero_of_pos _ (c.length_pos_of_pos hn)]
#align formal_multilinear_series.remove_zero_comp_of_pos FormalMultilinearSeries.removeZero_comp_of_pos
+-/
+#print FormalMultilinearSeries.comp_removeZero /-
@[simp]
theorem comp_removeZero (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultilinearSeries 𝕜 E F) :
q.comp p.removeZero = q.comp p := by ext n; simp [FormalMultilinearSeries.comp]
#align formal_multilinear_series.comp_remove_zero FormalMultilinearSeries.comp_removeZero
+-/
end FormalMultilinearSeries
@@ -328,6 +362,7 @@ variable [NontriviallyNormedField 𝕜] [NormedAddCommGroup E] [NormedSpace 𝕜
namespace FormalMultilinearSeries
+#print FormalMultilinearSeries.compAlongComposition_bound /-
/-- The norm of `f.comp_along_composition p c` is controlled by the product of
the norms of the relevant bits of `f` and `p`. -/
theorem compAlongComposition_bound {n : ℕ} (p : FormalMultilinearSeries 𝕜 E F) (c : Composition n)
@@ -350,7 +385,9 @@ theorem compAlongComposition_bound {n : ℕ} (p : FormalMultilinearSeries 𝕜 E
rw [← c.blocks_fin_equiv.prod_comp, ← Finset.univ_sigma_univ, Finset.prod_sigma]
congr
#align formal_multilinear_series.comp_along_composition_bound FormalMultilinearSeries.compAlongComposition_bound
+-/
+#print FormalMultilinearSeries.compAlongComposition_norm /-
/-- The norm of `q.comp_along_composition p c` is controlled by the product of
the norms of the relevant bits of `q` and `p`. -/
theorem compAlongComposition_norm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F G)
@@ -360,12 +397,15 @@ theorem compAlongComposition_norm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F
(mul_nonneg (norm_nonneg _) (Finset.prod_nonneg fun i hi => norm_nonneg _))
(compAlongComposition_bound _ _ _)
#align formal_multilinear_series.comp_along_composition_norm FormalMultilinearSeries.compAlongComposition_norm
+-/
+#print FormalMultilinearSeries.compAlongComposition_nnnorm /-
theorem compAlongComposition_nnnorm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) (c : Composition n) :
‖q.compAlongComposition p c‖₊ ≤ ‖q c.length‖₊ * ∏ i, ‖p (c.blocksFun i)‖₊ := by
rw [← NNReal.coe_le_coe]; push_cast ; exact q.comp_along_composition_norm p c
#align formal_multilinear_series.comp_along_composition_nnnorm FormalMultilinearSeries.compAlongComposition_nnnorm
+-/
/-!
### The identity formal power series
@@ -379,6 +419,7 @@ section
variable (𝕜 E)
+#print FormalMultilinearSeries.id /-
/-- The identity formal multilinear series, with all coefficients equal to `0` except for `n = 1`
where it is (the continuous multilinear version of) the identity. -/
def id : FormalMultilinearSeries 𝕜 E E
@@ -386,13 +427,17 @@ def id : FormalMultilinearSeries 𝕜 E E
| 1 => (continuousMultilinearCurryFin1 𝕜 E E).symm (ContinuousLinearMap.id 𝕜 E)
| _ => 0
#align formal_multilinear_series.id FormalMultilinearSeries.id
+-/
+#print FormalMultilinearSeries.id_apply_one /-
/-- The first coefficient of `id 𝕜 E` is the identity. -/
@[simp]
theorem id_apply_one (v : Fin 1 → E) : (FormalMultilinearSeries.id 𝕜 E) 1 v = v 0 :=
rfl
#align formal_multilinear_series.id_apply_one FormalMultilinearSeries.id_apply_one
+-/
+#print FormalMultilinearSeries.id_apply_one' /-
/-- The `n`th coefficient of `id 𝕜 E` is the identity when `n = 1`. We state this in a dependent
way, as it will often appear in this form. -/
theorem id_apply_one' {n : ℕ} (h : n = 1) (v : Fin n → E) :
@@ -401,15 +446,19 @@ theorem id_apply_one' {n : ℕ} (h : n = 1) (v : Fin n → E) :
subst n
apply id_apply_one
#align formal_multilinear_series.id_apply_one' FormalMultilinearSeries.id_apply_one'
+-/
+#print FormalMultilinearSeries.id_apply_ne_one /-
/-- For `n ≠ 1`, the `n`-th coefficient of `id 𝕜 E` is zero, by definition. -/
@[simp]
theorem id_apply_ne_one {n : ℕ} (h : n ≠ 1) : (FormalMultilinearSeries.id 𝕜 E) n = 0 := by cases n;
· rfl; cases n; · contradiction; rfl
#align formal_multilinear_series.id_apply_ne_one FormalMultilinearSeries.id_apply_ne_one
+-/
end
+#print FormalMultilinearSeries.comp_id /-
@[simp]
theorem comp_id (p : FormalMultilinearSeries 𝕜 E F) : p.comp (id 𝕜 E) = p :=
by
@@ -442,7 +491,9 @@ theorem comp_id (p : FormalMultilinearSeries 𝕜 E F) : p.comp (id 𝕜 E) = p
rfl
· simp
#align formal_multilinear_series.comp_id FormalMultilinearSeries.comp_id
+-/
+#print FormalMultilinearSeries.id_comp /-
@[simp]
theorem id_comp (p : FormalMultilinearSeries 𝕜 E F) (h : p 0 = 0) : (id 𝕜 F).comp p = p :=
by
@@ -471,16 +522,18 @@ theorem id_comp (p : FormalMultilinearSeries 𝕜 E F) (h : p 0 = 0) : (id 𝕜
rfl
· simp
#align formal_multilinear_series.id_comp FormalMultilinearSeries.id_comp
+-/
/-! ### Summability properties of the composition of formal power series-/
section
+#print FormalMultilinearSeries.comp_summable_nnreal /-
/-- If two formal multilinear series have positive radius of convergence, then the terms appearing
in the definition of their composition are also summable (when multiplied by a suitable positive
geometric term). -/
-theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultilinearSeries 𝕜 E F)
+theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultilinearSeries 𝕜 E F)
(hq : 0 < q.radius) (hp : 0 < p.radius) :
∃ r > (0 : ℝ≥0),
Summable fun i : Σ n, Composition n => ‖q.compAlongComposition p i.2‖₊ * r ^ i.1 :=
@@ -542,10 +595,12 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
rw [(this _).tsum_eq, add_tsub_cancel_right]
field_simp [← mul_assoc, pow_succ', mul_pow, show (4 : ℝ≥0) = 2 * 2 from (two_mul 2).symm,
mul_right_comm]
-#align formal_multilinear_series.comp_summable_nnreal FormalMultilinearSeries.comp_summable_nNReal
+#align formal_multilinear_series.comp_summable_nnreal FormalMultilinearSeries.comp_summable_nnreal
+-/
end
+#print FormalMultilinearSeries.le_comp_radius_of_summable /-
/-- Bounding below the radius of the composition of two formal multilinear series assuming
summability over all compositions. -/
theorem le_comp_radius_of_summable (q : FormalMultilinearSeries 𝕜 F G)
@@ -565,6 +620,7 @@ theorem le_comp_radius_of_summable (q : FormalMultilinearSeries 𝕜 F G)
_ ≤ ∑' i : Σ n : ℕ, Composition n, ‖comp_along_composition q p i.snd‖₊ * r ^ i.fst :=
NNReal.tsum_comp_le_tsum_of_inj hr sigma_mk_injective
#align formal_multilinear_series.le_comp_radius_of_summable FormalMultilinearSeries.le_comp_radius_of_summable
+-/
/-!
### Composing analytic functions
@@ -580,13 +636,16 @@ the source of the change of variables (`comp_partial_source`), its target
giving the main statement in `comp_partial_sum`. -/
+#print FormalMultilinearSeries.compPartialSumSource /-
/-- Source set in the change of variables to compute the composition of partial sums of formal
power series.
See also `comp_partial_sum`. -/
def compPartialSumSource (m M N : ℕ) : Finset (Σ n, Fin n → ℕ) :=
Finset.sigma (Finset.Ico m M) (fun n : ℕ => Fintype.piFinset fun i : Fin n => Finset.Ico 1 N : _)
#align formal_multilinear_series.comp_partial_sum_source FormalMultilinearSeries.compPartialSumSource
+-/
+#print FormalMultilinearSeries.mem_compPartialSumSource_iff /-
@[simp]
theorem mem_compPartialSumSource_iff (m M N : ℕ) (i : Σ n, Fin n → ℕ) :
i ∈ compPartialSumSource m M N ↔ (m ≤ i.1 ∧ i.1 < M) ∧ ∀ a : Fin i.1, 1 ≤ i.2 a ∧ i.2 a < N :=
@@ -594,7 +653,9 @@ theorem mem_compPartialSumSource_iff (m M N : ℕ) (i : Σ n, Fin n → ℕ) :
simp only [comp_partial_sum_source, Finset.mem_Ico, Fintype.mem_piFinset, Finset.mem_sigma,
iff_self_iff]
#align formal_multilinear_series.mem_comp_partial_sum_source_iff FormalMultilinearSeries.mem_compPartialSumSource_iff
+-/
+#print FormalMultilinearSeries.compChangeOfVariables /-
/-- Change of variables appearing to compute the composition of partial sums of formal
power series -/
def compChangeOfVariables (m M N : ℕ) (i : Σ n, Fin n → ℕ) (hi : i ∈ compPartialSumSource m M N) :
@@ -605,7 +666,9 @@ def compChangeOfVariables (m M N : ℕ) (i : Σ n, Fin n → ℕ) (hi : i ∈ co
obtain ⟨j, rfl⟩ : ∃ j : Fin n, f j = i := by rwa [mem_of_fn, Set.mem_range] at hi'
exact (hi.2 j).1
#align formal_multilinear_series.comp_change_of_variables FormalMultilinearSeries.compChangeOfVariables
+-/
+#print FormalMultilinearSeries.compChangeOfVariables_length /-
@[simp]
theorem compChangeOfVariables_length (m M N : ℕ) {i : Σ n, Fin n → ℕ}
(hi : i ∈ compPartialSumSource m M N) :
@@ -615,7 +678,9 @@ theorem compChangeOfVariables_length (m M N : ℕ) {i : Σ n, Fin n → ℕ}
dsimp [comp_change_of_variables]
simp only [Composition.length, map_of_fn, length_of_fn]
#align formal_multilinear_series.comp_change_of_variables_length FormalMultilinearSeries.compChangeOfVariables_length
+-/
+#print FormalMultilinearSeries.compChangeOfVariables_blocksFun /-
theorem compChangeOfVariables_blocksFun (m M N : ℕ) {i : Σ n, Fin n → ℕ}
(hi : i ∈ compPartialSumSource m M N) (j : Fin i.1) :
(compChangeOfVariables m M N i hi).2.blocksFun
@@ -628,15 +693,19 @@ theorem compChangeOfVariables_blocksFun (m M N : ℕ) {i : Σ n, Fin n → ℕ}
apply congr_arg
exact Fin.eta _ _
#align formal_multilinear_series.comp_change_of_variables_blocks_fun FormalMultilinearSeries.compChangeOfVariables_blocksFun
+-/
+#print FormalMultilinearSeries.compPartialSumTargetSet /-
/-- Target set in the change of variables to compute the composition of partial sums of formal
power series, here given a a set. -/
def compPartialSumTargetSet (m M N : ℕ) : Set (Σ n, Composition n) :=
{i | m ≤ i.2.length ∧ i.2.length < M ∧ ∀ j : Fin i.2.length, i.2.blocksFun j < N}
#align formal_multilinear_series.comp_partial_sum_target_set FormalMultilinearSeries.compPartialSumTargetSet
+-/
-theorem comp_partial_sum_target_subset_image_compPartialSumSource (m M N : ℕ)
- (i : Σ n, Composition n) (hi : i ∈ compPartialSumTargetSet m M N) :
+#print FormalMultilinearSeries.compPartialSumTargetSet_image_compPartialSumSource /-
+theorem compPartialSumTargetSet_image_compPartialSumSource (m M N : ℕ) (i : Σ n, Composition n)
+ (hi : i ∈ compPartialSumTargetSet m M N) :
∃ (j : _) (hj : j ∈ compPartialSumSource m M N), i = compChangeOfVariables m M N j hj :=
by
rcases i with ⟨n, c⟩
@@ -648,24 +717,30 @@ theorem comp_partial_sum_target_subset_image_compPartialSumSource (m M N : ℕ)
rw [Composition.sigma_eq_iff_blocks_eq]
simp only [Composition.blocksFun, Composition.blocks, Subtype.coe_eta, nth_le_map']
conv_lhs => rw [← of_fn_nth_le c.blocks]
-#align formal_multilinear_series.comp_partial_sum_target_subset_image_comp_partial_sum_source FormalMultilinearSeries.comp_partial_sum_target_subset_image_compPartialSumSource
+#align formal_multilinear_series.comp_partial_sum_target_subset_image_comp_partial_sum_source FormalMultilinearSeries.compPartialSumTargetSet_image_compPartialSumSource
+-/
+#print FormalMultilinearSeries.compPartialSumTarget /-
/-- Target set in the change of variables to compute the composition of partial sums of formal
power series, here given a a finset.
See also `comp_partial_sum`. -/
def compPartialSumTarget (m M N : ℕ) : Finset (Σ n, Composition n) :=
Set.Finite.toFinset <|
((Finset.finite_toSet _).dependent_image _).Subset <|
- comp_partial_sum_target_subset_image_compPartialSumSource m M N
+ compPartialSumTargetSet_image_compPartialSumSource m M N
#align formal_multilinear_series.comp_partial_sum_target FormalMultilinearSeries.compPartialSumTarget
+-/
+#print FormalMultilinearSeries.mem_compPartialSumTarget_iff /-
@[simp]
theorem mem_compPartialSumTarget_iff {m M N : ℕ} {a : Σ n, Composition n} :
a ∈ compPartialSumTarget m M N ↔
m ≤ a.2.length ∧ a.2.length < M ∧ ∀ j : Fin a.2.length, a.2.blocksFun j < N :=
by simp [comp_partial_sum_target, comp_partial_sum_target_set]
#align formal_multilinear_series.mem_comp_partial_sum_target_iff FormalMultilinearSeries.mem_compPartialSumTarget_iff
+-/
+#print FormalMultilinearSeries.compChangeOfVariables_sum /-
/-- `comp_change_of_variables m M N` is a bijection between `comp_partial_sum_source m M N`
and `comp_partial_sum_target m M N`, yielding equal sums for functions that correspond to each
other under the bijection. As `comp_change_of_variables m M N` is a dependent function, stating
@@ -710,7 +785,9 @@ theorem compChangeOfVariables_sum {α : Type _} [AddCommMonoid α] (m M N : ℕ)
apply comp_partial_sum_target_subset_image_comp_partial_sum_source m M N i
simpa [comp_partial_sum_target] using hi
#align formal_multilinear_series.comp_change_of_variables_sum FormalMultilinearSeries.compChangeOfVariables_sum
+-/
+#print FormalMultilinearSeries.compPartialSumTarget_tendsto_atTop /-
/-- The auxiliary set corresponding to the composition of partial sums asymptotically contains
all possible compositions. -/
theorem compPartialSumTarget_tendsto_atTop :
@@ -730,7 +807,9 @@ theorem compPartialSumTarget_tendsto_atTop :
apply hn
simp only [Finset.mem_image_of_mem, Finset.mem_coe, Finset.mem_univ]
#align formal_multilinear_series.comp_partial_sum_target_tendsto_at_top FormalMultilinearSeries.compPartialSumTarget_tendsto_atTop
+-/
+#print FormalMultilinearSeries.comp_partialSum /-
/-- Composing the partial sums of two multilinear series coincides with the sum over all
compositions in `comp_partial_sum_target 0 N N`. This is precisely the motivation for the
definition of `comp_partial_sum_target`. -/
@@ -757,11 +836,13 @@ theorem comp_partialSum (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultil
rw [← comp_change_of_variables_blocks_fun 0 N N H]
rfl
#align formal_multilinear_series.comp_partial_sum FormalMultilinearSeries.comp_partialSum
+-/
end FormalMultilinearSeries
open FormalMultilinearSeries
+#print HasFPowerSeriesAt.comp /-
/-- If two functions `g` and `f` have power series `q` and `p` respectively at `f x` and `x`, then
`g ∘ f` admits the power series `q.comp p` at `x`. -/
theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinearSeries 𝕜 F G}
@@ -893,7 +974,9 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
rfl
exact E
#align has_fpower_series_at.comp HasFPowerSeriesAt.comp
+-/
+#print AnalyticAt.comp /-
/-- If two functions `g` and `f` are analytic respectively at `f x` and `x`, then `g ∘ f` is
analytic at `x`. -/
theorem AnalyticAt.comp {g : F → G} {f : E → F} {x : E} (hg : AnalyticAt 𝕜 g (f x))
@@ -902,6 +985,7 @@ theorem AnalyticAt.comp {g : F → G} {f : E → F} {x : E} (hg : AnalyticAt
let ⟨p, hp⟩ := hf
(hq.comp hp).AnalyticAt
#align analytic_at.comp AnalyticAt.comp
+-/
/-!
### Associativity of the composition of formal multilinear series
@@ -963,6 +1047,7 @@ namespace Composition
variable {n : ℕ}
+#print Composition.sigma_composition_eq_iff /-
/-- Rewriting equality in the dependent type `Σ (a : composition n), composition a.length)` in
non-dependent terms with lists, requiring that the blocks coincide. -/
theorem sigma_composition_eq_iff (i j : Σ a : Composition n, Composition a.length) :
@@ -975,7 +1060,9 @@ theorem sigma_composition_eq_iff (i j : Σ a : Composition n, Composition a.leng
have H : a = a' := by ext1; exact h
induction H; congr; ext1; exact h'
#align composition.sigma_composition_eq_iff Composition.sigma_composition_eq_iff
+-/
+#print Composition.sigma_pi_composition_eq_iff /-
/-- Rewriting equality in the dependent type
`Σ (c : composition n), Π (i : fin c.length), composition (c.blocks_fun i)` in
non-dependent terms with lists, requiring that the lists of blocks coincide. -/
@@ -1008,7 +1095,9 @@ theorem sigma_pi_composition_eq_iff
nth_le_of_eq H _
rwa [nth_le_of_fn, nth_le_of_fn] at this
#align composition.sigma_pi_composition_eq_iff Composition.sigma_pi_composition_eq_iff
+-/
+#print Composition.gather /-
/-- When `a` is a composition of `n` and `b` is a composition of `a.length`, `a.gather b` is the
composition of `n` obtained by gathering all the blocks of `a` corresponding to a block of `b`.
For instance, if `a = [6, 5, 3, 5, 2]` and `b = [2, 3]`, one should gather together
@@ -1030,13 +1119,17 @@ def gather (a : Composition n) (b : Composition a.length) : Composition n
exact mem_join_of_mem hj hi
blocks_sum := by rw [← sum_join, join_split_wrt_composition, a.blocks_sum]
#align composition.gather Composition.gather
+-/
+#print Composition.length_gather /-
theorem length_gather (a : Composition n) (b : Composition a.length) :
length (a.gather b) = b.length :=
show (map List.sum (a.blocks.splitWrtComposition b)).length = b.blocks.length by
rw [length_map, length_split_wrt_composition]
#align composition.length_gather Composition.length_gather
+-/
+#print Composition.sigmaCompositionAux /-
/-- An auxiliary function used in the definition of `sigma_equiv_sigma_pi` below, associating to
two compositions `a` of `n` and `b` of `a.length`, and an index `i` bounded by the length of
`a.gather b`, the subcomposition of `a` made of those blocks belonging to the `i`-th block of
@@ -1054,7 +1147,9 @@ def sigmaCompositionAux (a : Composition n) (b : Composition a.length)
exact mem_join_of_mem (nth_le_mem _ _ _) hi)
blocks_sum := by simp only [Composition.blocksFun, nth_le_map', Composition.gather]
#align composition.sigma_composition_aux Composition.sigmaCompositionAux
+-/
+#print Composition.length_sigmaCompositionAux /-
theorem length_sigmaCompositionAux (a : Composition n) (b : Composition a.length)
(i : Fin b.length) :
Composition.length (Composition.sigmaCompositionAux a b ⟨i, (length_gather a b).symm ▸ i.2⟩) =
@@ -1062,7 +1157,9 @@ theorem length_sigmaCompositionAux (a : Composition n) (b : Composition a.length
show List.length (nthLe (splitWrtComposition a.blocks b) i _) = blocksFun b i by
rw [nth_le_map_rev List.length, nth_le_of_eq (map_length_split_wrt_composition _ _)]; rfl
#align composition.length_sigma_composition_aux Composition.length_sigmaCompositionAux
+-/
+#print Composition.blocksFun_sigmaCompositionAux /-
theorem blocksFun_sigmaCompositionAux (a : Composition n) (b : Composition a.length)
(i : Fin b.length) (j : Fin (blocksFun b i)) :
blocksFun (sigmaCompositionAux a b ⟨i, (length_gather a b).symm ▸ i.2⟩)
@@ -1071,7 +1168,9 @@ theorem blocksFun_sigmaCompositionAux (a : Composition n) (b : Composition a.len
show nthLe (nthLe _ _ _) _ _ = nthLe a.blocks _ _ by
rw [nth_le_of_eq (nth_le_split_wrt_composition _ _ _), nth_le_drop', nth_le_take']; rfl
#align composition.blocks_fun_sigma_composition_aux Composition.blocksFun_sigmaCompositionAux
+-/
+#print Composition.sizeUpTo_sizeUpTo_add /-
/-- Auxiliary lemma to prove that the composition of formal multilinear series is associative.
Consider a composition `a` of `n` and a composition `b` of `a.length`. Grouping together some
@@ -1120,7 +1219,9 @@ theorem sizeUpTo_sizeUpTo_add (a : Composition n) (b : Composition a.length) {i
simp only [sigma_composition_aux, add_assoc, add_left_inj, Fin.val_mk]
rw [nth_le_of_eq (nth_le_split_wrt_composition _ _ _), nth_le_drop', nth_le_take _ _ C]
#align composition.size_up_to_size_up_to_add Composition.sizeUpTo_sizeUpTo_add
+-/
+#print Composition.sigmaEquivSigmaPi /-
/-- Natural equivalence between `(Σ (a : composition n), composition a.length)` and
`(Σ (c : composition n), Π (i : fin c.length), composition (c.blocks_fun i))`, that shows up as a
change of variables in the proof that composition of formal multilinear series is associative.
@@ -1201,6 +1302,7 @@ def sigmaEquivSigmaPi (n : ℕ) :
rwa [split_wrt_composition_join]
simp only [map_of_fn]
#align composition.sigma_equiv_sigma_pi Composition.sigmaEquivSigmaPi
+-/
end Composition
@@ -1208,6 +1310,7 @@ namespace FormalMultilinearSeries
open Composition
+#print FormalMultilinearSeries.comp_assoc /-
theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) : (r.comp q).comp p = r.comp (q.comp p) :=
by
@@ -1249,6 +1352,7 @@ theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinear
dsimp [Composition.embedding]
rw [size_up_to_size_up_to_add _ _ hi1 hj1, add_assoc]
#align formal_multilinear_series.comp_assoc FormalMultilinearSeries.comp_assoc
+-/
end FormalMultilinearSeries
mathlib commit https://github.com/leanprover-community/mathlib/commit/a3e83f0fa4391c8740f7d773a7a9b74e311ae2a3
@@ -674,7 +674,7 @@ more easily. -/
theorem compChangeOfVariables_sum {α : Type _} [AddCommMonoid α] (m M N : ℕ)
(f : (Σ n : ℕ, Fin n → ℕ) → α) (g : (Σ n, Composition n) → α)
(h : ∀ (e) (he : e ∈ compPartialSumSource m M N), f e = g (compChangeOfVariables m M N e he)) :
- (∑ e in compPartialSumSource m M N, f e) = ∑ e in compPartialSumTarget m M N, g e :=
+ ∑ e in compPartialSumSource m M N, f e = ∑ e in compPartialSumTarget m M N, g e :=
by
apply Finset.sum_bij (comp_change_of_variables m M N)
-- We should show that the correspondance we have set up is indeed a bijection
@@ -1219,7 +1219,7 @@ theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinear
let g : (Σ c : Composition n, ∀ i : Fin c.length, Composition (c.blocksFun i)) → H := fun c =>
r c.1.length fun i : Fin c.1.length =>
q (c.2 i).length (apply_composition p (c.2 i) (v ∘ c.1.Embedding i))
- suffices (∑ c, f c) = ∑ c, g c by
+ suffices ∑ c, f c = ∑ c, g c by
simpa only [FormalMultilinearSeries.comp, ContinuousMultilinearMap.sum_apply,
comp_along_composition_apply, ContinuousMultilinearMap.map_sum, Finset.sum_sigma',
apply_composition]
mathlib commit https://github.com/leanprover-community/mathlib/commit/7e5137f579de09a059a5ce98f364a04e221aabf0
@@ -349,7 +349,6 @@ theorem compAlongComposition_bound {n : ℕ} (p : FormalMultilinearSeries 𝕜 E
by
rw [← c.blocks_fin_equiv.prod_comp, ← Finset.univ_sigma_univ, Finset.prod_sigma]
congr
-
#align formal_multilinear_series.comp_along_composition_bound FormalMultilinearSeries.compAlongComposition_bound
/-- The norm of `q.comp_along_composition p c` is controlled by the product of
@@ -511,7 +510,6 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
‖q c.length‖₊ * rq ^ n ≤ ‖q c.length‖₊ * rq ^ c.length :=
mul_le_mul' le_rfl (pow_le_pow_of_le_one rq.2 hrq.1.le c.length_le)
_ ≤ Cq := hCq _
-
have B
calc
(∏ i, ‖p (c.blocks_fun i)‖₊) * rp ^ n = ∏ i, ‖p (c.blocks_fun i)‖₊ * rp ^ c.blocks_fun i := by
@@ -519,7 +517,6 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
_ ≤ ∏ i : Fin c.length, Cp := (Finset.prod_le_prod' fun i _ => hCp _)
_ = Cp ^ c.length := by simp
_ ≤ Cp ^ n := pow_le_pow hCp1 c.length_le
-
calc
‖q.comp_along_composition p c‖₊ * r ^ n ≤
(‖q c.length‖₊ * ∏ i, ‖p (c.blocks_fun i)‖₊) * r ^ n :=
@@ -531,7 +528,6 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
simp only [r0]
field_simp [mul_pow, (zero_lt_one.trans_le hCp1).ne']
ring
-
refine' ⟨r, r_pos, NNReal.summable_of_le I _⟩
simp_rw [div_eq_mul_inv]
refine' Summable.mul_left _ _
@@ -568,7 +564,6 @@ theorem le_comp_radius_of_summable (q : FormalMultilinearSeries 𝕜 F G)
exact mul_le_mul' (nnnorm_sum_le _ _) le_rfl
_ ≤ ∑' i : Σ n : ℕ, Composition n, ‖comp_along_composition q p i.snd‖₊ * r ^ i.fst :=
NNReal.tsum_comp_le_tsum_of_inj hr sigma_mk_injective
-
#align formal_multilinear_series.le_comp_radius_of_summable FormalMultilinearSeries.le_comp_radius_of_summable
/-!
@@ -710,7 +705,6 @@ theorem compChangeOfVariables_sum {α : Type _} [AddCommMonoid α] (m M N : ℕ)
apply Composition.blocksFun_congr <;> try rw [HEq]
rfl
_ = blocks_fun' i := comp_change_of_variables_blocks_fun m M N H' i
-
-- 4 - show that the map is surjective
· intro i hi
apply comp_partial_sum_target_subset_image_comp_partial_sum_source m M N i
@@ -884,7 +878,6 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
rw [EMetric.mem_ball, edist_eq_coe_nnnorm] at hy
have := le_trans (le_of_lt hy) (min_le_right _ _)
rwa [ENNReal.coe_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
-
tendsto_nhds_of_cauchySeq_of_subseq cau comp_partial_sum_target_tendsto_at_top C
-- Fifth step: the sum over `n` of `q.comp p n` can be expressed as a particular resummation of
-- the sum over all compositions, by grouping together the compositions of the same
@@ -1031,7 +1024,6 @@ def gather (a : Composition n) (b : Composition a.length) : Composition n
calc
0 < j.length := length_pos_of_mem_split_wrt_composition hj
_ ≤ j.sum := length_le_sum_of_one_le _ H
-
intro i hi
apply a.one_le_blocks
rw [← a.blocks.join_split_wrt_composition b]
mathlib commit https://github.com/leanprover-community/mathlib/commit/5f25c089cb34db4db112556f23c50d12da81b297
@@ -541,7 +541,7 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
convert hasSum_fintype fun c : Composition n => (4 ^ n : ℝ≥0)⁻¹
simp [Finset.card_univ, composition_card, div_eq_mul_inv]
refine' NNReal.summable_sigma.2 ⟨fun n => (this n).Summable, (NNReal.summable_nat_add_iff 1).1 _⟩
- convert(NNReal.summable_geometric (NNReal.div_lt_one_of_lt one_lt_two)).mul_left (1 / 4)
+ convert (NNReal.summable_geometric (NNReal.div_lt_one_of_lt one_lt_two)).mul_left (1 / 4)
ext1 n
rw [(this _).tsum_eq, add_tsub_cancel_right]
field_simp [← mul_assoc, pow_succ', mul_pow, show (4 : ℝ≥0) = 2 * 2 from (two_mul 2).symm,
@@ -637,7 +637,7 @@ theorem compChangeOfVariables_blocksFun (m M N : ℕ) {i : Σ n, Fin n → ℕ}
/-- Target set in the change of variables to compute the composition of partial sums of formal
power series, here given a a set. -/
def compPartialSumTargetSet (m M N : ℕ) : Set (Σ n, Composition n) :=
- { i | m ≤ i.2.length ∧ i.2.length < M ∧ ∀ j : Fin i.2.length, i.2.blocksFun j < N }
+ {i | m ≤ i.2.length ∧ i.2.length < M ∧ ∀ j : Fin i.2.length, i.2.blocksFun j < N}
#align formal_multilinear_series.comp_partial_sum_target_set FormalMultilinearSeries.compPartialSumTargetSet
theorem comp_partial_sum_target_subset_image_compPartialSumSource (m M N : ℕ)
mathlib commit https://github.com/leanprover-community/mathlib/commit/cca40788df1b8755d5baf17ab2f27dacc2e17acb
@@ -770,9 +770,9 @@ open FormalMultilinearSeries
/-- If two functions `g` and `f` have power series `q` and `p` respectively at `f x` and `x`, then
`g ∘ f` admits the power series `q.comp p` at `x`. -/
-theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinearSeries 𝕜 F G}
- {p : FormalMultilinearSeries 𝕜 E F} {x : E} (hg : HasFpowerSeriesAt g q (f x))
- (hf : HasFpowerSeriesAt f p x) : HasFpowerSeriesAt (g ∘ f) (q.comp p) x :=
+theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinearSeries 𝕜 F G}
+ {p : FormalMultilinearSeries 𝕜 E F} {x : E} (hg : HasFPowerSeriesAt g q (f x))
+ (hf : HasFPowerSeriesAt f p x) : HasFPowerSeriesAt (g ∘ f) (q.comp p) x :=
by
/- Consider `rf` and `rg` such that `f` and `g` have power series expansion on the disks
of radius `rf` and `rg`. -/
@@ -899,7 +899,7 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
simp only [ContinuousMultilinearMap.sum_apply]
rfl
exact E
-#align has_fpower_series_at.comp HasFpowerSeriesAt.comp
+#align has_fpower_series_at.comp HasFPowerSeriesAt.comp
/-- If two functions `g` and `f` are analytic respectively at `f x` and `x`, then `g ∘ f` is
analytic at `x`. -/
mathlib commit https://github.com/leanprover-community/mathlib/commit/cca40788df1b8755d5baf17ab2f27dacc2e17acb
@@ -133,7 +133,11 @@ theorem applyComposition_single (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
cases j
have : j_val = 0 := le_bot_iff.1 (Nat.lt_succ_iff.1 j_property)
unfold_coes
- congr <;> try first |assumption|simp
+ congr <;>
+ try
+ first
+ | assumption
+ | simp
#align formal_multilinear_series.apply_composition_single FormalMultilinearSeries.applyComposition_single
@[simp]
@@ -425,9 +429,9 @@ theorem comp_id (p : FormalMultilinearSeries 𝕜 E F) : p.comp (id 𝕜 E) = p
∀ b : Composition n,
b ∈ Finset.univ → b ≠ Composition.ones n → comp_along_composition p (id 𝕜 E) b = 0
· intro b _ hb
- obtain ⟨k, hk, lt_k⟩ : ∃ (k : ℕ)(H : k ∈ Composition.blocks b), 1 < k :=
+ obtain ⟨k, hk, lt_k⟩ : ∃ (k : ℕ) (H : k ∈ Composition.blocks b), 1 < k :=
Composition.ne_ones_iff.1 hb
- obtain ⟨i, i_lt, hi⟩ : ∃ (i : ℕ)(h : i < b.blocks.length), b.blocks.nth_le i h = k :=
+ obtain ⟨i, i_lt, hi⟩ : ∃ (i : ℕ) (h : i < b.blocks.length), b.blocks.nth_le i h = k :=
nth_le_of_mem hk
let j : Fin b.length := ⟨i, b.blocks_length ▸ i_lt⟩
have A : 1 < b.blocks_fun j := by convert lt_k
@@ -480,14 +484,14 @@ geometric term). -/
theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultilinearSeries 𝕜 E F)
(hq : 0 < q.radius) (hp : 0 < p.radius) :
∃ r > (0 : ℝ≥0),
- Summable fun i : Σn, Composition n => ‖q.compAlongComposition p i.2‖₊ * r ^ i.1 :=
+ Summable fun i : Σ n, Composition n => ‖q.compAlongComposition p i.2‖₊ * r ^ i.1 :=
by
/- This follows from the fact that the growth rate of `‖qₙ‖` and `‖pₙ‖` is at most geometric,
giving a geometric bound on each `‖q.comp_along_composition p op‖`, together with the
fact that there are `2^(n-1)` compositions of `n`, giving at most a geometric loss. -/
rcases ENNReal.lt_iff_exists_nnreal_btwn.1 (lt_min zero_lt_one hq) with ⟨rq, rq_pos, hrq⟩
rcases ENNReal.lt_iff_exists_nnreal_btwn.1 (lt_min zero_lt_one hp) with ⟨rp, rp_pos, hrp⟩
- simp only [lt_min_iff, ENNReal.coe_lt_one_iff, ENNReal.coe_pos] at hrp hrq rp_pos rq_pos
+ simp only [lt_min_iff, ENNReal.coe_lt_one_iff, ENNReal.coe_pos] at hrp hrq rp_pos rq_pos
obtain ⟨Cq, hCq0, hCq⟩ : ∃ Cq > 0, ∀ n, ‖q n‖₊ * rq ^ n ≤ Cq :=
q.nnnorm_mul_pow_le_of_lt_radius hrq.2
obtain ⟨Cp, hCp1, hCp⟩ : ∃ Cp ≥ 1, ∀ n, ‖p n‖₊ * rp ^ n ≤ Cp :=
@@ -499,7 +503,7 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
set r : ℝ≥0 := rp * rq * r0
have r_pos : 0 < r := mul_pos (mul_pos rp_pos rq_pos) r0_pos
have I :
- ∀ i : Σn : ℕ, Composition n, ‖q.comp_along_composition p i.2‖₊ * r ^ i.1 ≤ Cq / 4 ^ i.1 :=
+ ∀ i : Σ n : ℕ, Composition n, ‖q.comp_along_composition p i.2‖₊ * r ^ i.1 ≤ Cq / 4 ^ i.1 :=
by
rintro ⟨n, c⟩
have A
@@ -550,19 +554,19 @@ end
summability over all compositions. -/
theorem le_comp_radius_of_summable (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) (r : ℝ≥0)
- (hr : Summable fun i : Σn, Composition n => ‖q.compAlongComposition p i.2‖₊ * r ^ i.1) :
+ (hr : Summable fun i : Σ n, Composition n => ‖q.compAlongComposition p i.2‖₊ * r ^ i.1) :
(r : ℝ≥0∞) ≤ (q.comp p).radius :=
by
refine'
le_radius_of_bound_nnreal _
- (∑' i : Σn, Composition n, ‖comp_along_composition q p i.snd‖₊ * r ^ i.fst) fun n => _
+ (∑' i : Σ n, Composition n, ‖comp_along_composition q p i.snd‖₊ * r ^ i.fst) fun n => _
calc
‖FormalMultilinearSeries.comp q p n‖₊ * r ^ n ≤
∑' c : Composition n, ‖comp_along_composition q p c‖₊ * r ^ n :=
by
rw [tsum_fintype, ← Finset.sum_mul]
exact mul_le_mul' (nnnorm_sum_le _ _) le_rfl
- _ ≤ ∑' i : Σn : ℕ, Composition n, ‖comp_along_composition q p i.snd‖₊ * r ^ i.fst :=
+ _ ≤ ∑' i : Σ n : ℕ, Composition n, ‖comp_along_composition q p i.snd‖₊ * r ^ i.fst :=
NNReal.tsum_comp_le_tsum_of_inj hr sigma_mk_injective
#align formal_multilinear_series.le_comp_radius_of_summable FormalMultilinearSeries.le_comp_radius_of_summable
@@ -584,12 +588,12 @@ giving the main statement in `comp_partial_sum`. -/
/-- Source set in the change of variables to compute the composition of partial sums of formal
power series.
See also `comp_partial_sum`. -/
-def compPartialSumSource (m M N : ℕ) : Finset (Σn, Fin n → ℕ) :=
+def compPartialSumSource (m M N : ℕ) : Finset (Σ n, Fin n → ℕ) :=
Finset.sigma (Finset.Ico m M) (fun n : ℕ => Fintype.piFinset fun i : Fin n => Finset.Ico 1 N : _)
#align formal_multilinear_series.comp_partial_sum_source FormalMultilinearSeries.compPartialSumSource
@[simp]
-theorem mem_compPartialSumSource_iff (m M N : ℕ) (i : Σn, Fin n → ℕ) :
+theorem mem_compPartialSumSource_iff (m M N : ℕ) (i : Σ n, Fin n → ℕ) :
i ∈ compPartialSumSource m M N ↔ (m ≤ i.1 ∧ i.1 < M) ∧ ∀ a : Fin i.1, 1 ≤ i.2 a ∧ i.2 a < N :=
by
simp only [comp_partial_sum_source, Finset.mem_Ico, Fintype.mem_piFinset, Finset.mem_sigma,
@@ -598,17 +602,17 @@ theorem mem_compPartialSumSource_iff (m M N : ℕ) (i : Σn, Fin n → ℕ) :
/-- Change of variables appearing to compute the composition of partial sums of formal
power series -/
-def compChangeOfVariables (m M N : ℕ) (i : Σn, Fin n → ℕ) (hi : i ∈ compPartialSumSource m M N) :
- Σn, Composition n := by
+def compChangeOfVariables (m M N : ℕ) (i : Σ n, Fin n → ℕ) (hi : i ∈ compPartialSumSource m M N) :
+ Σ n, Composition n := by
rcases i with ⟨n, f⟩
- rw [mem_comp_partial_sum_source_iff] at hi
+ rw [mem_comp_partial_sum_source_iff] at hi
refine' ⟨∑ j, f j, of_fn fun a => f a, fun i hi' => _, by simp [sum_of_fn]⟩
- obtain ⟨j, rfl⟩ : ∃ j : Fin n, f j = i := by rwa [mem_of_fn, Set.mem_range] at hi'
+ obtain ⟨j, rfl⟩ : ∃ j : Fin n, f j = i := by rwa [mem_of_fn, Set.mem_range] at hi'
exact (hi.2 j).1
#align formal_multilinear_series.comp_change_of_variables FormalMultilinearSeries.compChangeOfVariables
@[simp]
-theorem compChangeOfVariables_length (m M N : ℕ) {i : Σn, Fin n → ℕ}
+theorem compChangeOfVariables_length (m M N : ℕ) {i : Σ n, Fin n → ℕ}
(hi : i ∈ compPartialSumSource m M N) :
Composition.length (compChangeOfVariables m M N i hi).2 = i.1 :=
by
@@ -617,7 +621,7 @@ theorem compChangeOfVariables_length (m M N : ℕ) {i : Σn, Fin n → ℕ}
simp only [Composition.length, map_of_fn, length_of_fn]
#align formal_multilinear_series.comp_change_of_variables_length FormalMultilinearSeries.compChangeOfVariables_length
-theorem compChangeOfVariables_blocksFun (m M N : ℕ) {i : Σn, Fin n → ℕ}
+theorem compChangeOfVariables_blocksFun (m M N : ℕ) {i : Σ n, Fin n → ℕ}
(hi : i ∈ compPartialSumSource m M N) (j : Fin i.1) :
(compChangeOfVariables m M N i hi).2.blocksFun
⟨j, (compChangeOfVariables_length m M N hi).symm ▸ j.2⟩ =
@@ -632,17 +636,17 @@ theorem compChangeOfVariables_blocksFun (m M N : ℕ) {i : Σn, Fin n → ℕ}
/-- Target set in the change of variables to compute the composition of partial sums of formal
power series, here given a a set. -/
-def compPartialSumTargetSet (m M N : ℕ) : Set (Σn, Composition n) :=
+def compPartialSumTargetSet (m M N : ℕ) : Set (Σ n, Composition n) :=
{ i | m ≤ i.2.length ∧ i.2.length < M ∧ ∀ j : Fin i.2.length, i.2.blocksFun j < N }
#align formal_multilinear_series.comp_partial_sum_target_set FormalMultilinearSeries.compPartialSumTargetSet
theorem comp_partial_sum_target_subset_image_compPartialSumSource (m M N : ℕ)
- (i : Σn, Composition n) (hi : i ∈ compPartialSumTargetSet m M N) :
- ∃ (j : _)(hj : j ∈ compPartialSumSource m M N), i = compChangeOfVariables m M N j hj :=
+ (i : Σ n, Composition n) (hi : i ∈ compPartialSumTargetSet m M N) :
+ ∃ (j : _) (hj : j ∈ compPartialSumSource m M N), i = compChangeOfVariables m M N j hj :=
by
rcases i with ⟨n, c⟩
refine' ⟨⟨c.length, c.blocks_fun⟩, _, _⟩
- · simp only [comp_partial_sum_target_set, Set.mem_setOf_eq] at hi
+ · simp only [comp_partial_sum_target_set, Set.mem_setOf_eq] at hi
simp only [mem_comp_partial_sum_source_iff, hi.left, hi.right, true_and_iff, and_true_iff]
exact fun a => c.one_le_blocks' _
· dsimp [comp_change_of_variables]
@@ -654,14 +658,14 @@ theorem comp_partial_sum_target_subset_image_compPartialSumSource (m M N : ℕ)
/-- Target set in the change of variables to compute the composition of partial sums of formal
power series, here given a a finset.
See also `comp_partial_sum`. -/
-def compPartialSumTarget (m M N : ℕ) : Finset (Σn, Composition n) :=
+def compPartialSumTarget (m M N : ℕ) : Finset (Σ n, Composition n) :=
Set.Finite.toFinset <|
((Finset.finite_toSet _).dependent_image _).Subset <|
comp_partial_sum_target_subset_image_compPartialSumSource m M N
#align formal_multilinear_series.comp_partial_sum_target FormalMultilinearSeries.compPartialSumTarget
@[simp]
-theorem mem_compPartialSumTarget_iff {m M N : ℕ} {a : Σn, Composition n} :
+theorem mem_compPartialSumTarget_iff {m M N : ℕ} {a : Σ n, Composition n} :
a ∈ compPartialSumTarget m M N ↔
m ≤ a.2.length ∧ a.2.length < M ∧ ∀ j : Fin a.2.length, a.2.blocksFun j < N :=
by simp [comp_partial_sum_target, comp_partial_sum_target_set]
@@ -673,7 +677,7 @@ other under the bijection. As `comp_change_of_variables m M N` is a dependent fu
that it is a bijection is not directly possible, but the consequence on sums can be stated
more easily. -/
theorem compChangeOfVariables_sum {α : Type _} [AddCommMonoid α] (m M N : ℕ)
- (f : (Σn : ℕ, Fin n → ℕ) → α) (g : (Σn, Composition n) → α)
+ (f : (Σ n : ℕ, Fin n → ℕ) → α) (g : (Σ n, Composition n) → α)
(h : ∀ (e) (he : e ∈ compPartialSumSource m M N), f e = g (compChangeOfVariables m M N e he)) :
(∑ e in compPartialSumSource m M N, f e) = ∑ e in compPartialSumTarget m M N, g e :=
by
@@ -682,7 +686,7 @@ theorem compChangeOfVariables_sum {α : Type _} [AddCommMonoid α] (m M N : ℕ)
-- between the index sets of the two sums.
-- 1 - show that the image belongs to `comp_partial_sum_target m N N`
· rintro ⟨k, blocks_fun⟩ H
- rw [mem_comp_partial_sum_source_iff] at H
+ rw [mem_comp_partial_sum_source_iff] at H
simp only [mem_comp_partial_sum_target_iff, Composition.length, Composition.blocks, H.left,
map_of_fn, length_of_fn, true_and_iff, comp_change_of_variables]
intro j
@@ -695,7 +699,7 @@ theorem compChangeOfVariables_sum {α : Type _} [AddCommMonoid α] (m M N : ℕ)
obtain rfl : k = k' :=
by
have := (comp_change_of_variables_length m M N H).symm
- rwa [HEq, comp_change_of_variables_length] at this
+ rwa [HEq, comp_change_of_variables_length] at this
congr
funext i
calc
@@ -781,7 +785,7 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
`min (r, rf, δ)` be this new radius.-/
have : ContinuousAt f x := Hf.analytic_at.continuous_at
obtain ⟨δ, δpos, hδ⟩ :
- ∃ (δ : ℝ≥0∞)(H : 0 < δ), ∀ {z : E}, z ∈ EMetric.ball x δ → f z ∈ EMetric.ball (f x) rg :=
+ ∃ (δ : ℝ≥0∞) (H : 0 < δ), ∀ {z : E}, z ∈ EMetric.ball x δ → f z ∈ EMetric.ball (f x) rg :=
by
have : EMetric.ball (f x) rg ∈ 𝓝 (f x) := EMetric.ball_mem_nhds _ Hg.r_pos
rcases EMetric.mem_nhds_iff.1 (Hf.analytic_at.continuous_at this) with ⟨δ, δpos, Hδ⟩
@@ -844,7 +848,7 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
exact Hg.continuous_on.continuous_at (IsOpen.mem_nhds EMetric.isOpen_ball fy_mem)
have B₂ : f (x + y) - f x ∈ EMetric.ball (0 : F) rg := by
simpa [edist_eq_coe_nnnorm, edist_eq_coe_nnnorm_sub] using fy_mem
- rw [← emetric.is_open_ball.nhds_within_eq B₂] at A
+ rw [← emetric.is_open_ball.nhds_within_eq B₂] at A
convert Hg.tendsto_locally_uniformly_on.tendsto_comp B₁.continuous_within_at B₂ A
simp only [add_sub_cancel'_right]
-- Third step: the sum over all compositions in `comp_partial_sum_target 0 n n` converges to
@@ -859,10 +863,10 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
-- convergence along a subsequence proved in the third step, and the fact that the sum is Cauchy
-- thanks to the summability properties.
have D :
- HasSum (fun i : Σn, Composition n => q.comp_along_composition p i.2 fun j => y)
+ HasSum (fun i : Σ n, Composition n => q.comp_along_composition p i.2 fun j => y)
(g (f (x + y))) :=
haveI cau :
- CauchySeq fun s : Finset (Σn, Composition n) =>
+ CauchySeq fun s : Finset (Σ n, Composition n) =>
∑ i in s, q.comp_along_composition p i.2 fun j => y :=
by
apply cauchySeq_finset_of_norm_bounded _ (NNReal.summable_coe.2 hr) _
@@ -877,9 +881,9 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
rw [Finset.prod_const, Finset.card_fin]
apply pow_le_pow_of_le_left (norm_nonneg _)
- rw [EMetric.mem_ball, edist_eq_coe_nnnorm] at hy
+ rw [EMetric.mem_ball, edist_eq_coe_nnnorm] at hy
have := le_trans (le_of_lt hy) (min_le_right _ _)
- rwa [ENNReal.coe_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
+ rwa [ENNReal.coe_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
tendsto_nhds_of_cauchySeq_of_subseq cau comp_partial_sum_target_tendsto_at_top C
-- Fifth step: the sum over `n` of `q.comp p n` can be expressed as a particular resummation of
@@ -968,7 +972,7 @@ variable {n : ℕ}
/-- Rewriting equality in the dependent type `Σ (a : composition n), composition a.length)` in
non-dependent terms with lists, requiring that the blocks coincide. -/
-theorem sigma_composition_eq_iff (i j : Σa : Composition n, Composition a.length) :
+theorem sigma_composition_eq_iff (i j : Σ a : Composition n, Composition a.length) :
i = j ↔ i.1.blocks = j.1.blocks ∧ i.2.blocks = j.2.blocks :=
by
refine' ⟨by rintro rfl <;> exact ⟨rfl, rfl⟩, _⟩
@@ -976,31 +980,31 @@ theorem sigma_composition_eq_iff (i j : Σa : Composition n, Composition a.lengt
rcases j with ⟨a', b'⟩
rintro ⟨h, h'⟩
have H : a = a' := by ext1; exact h
- induction H; congr ; ext1; exact h'
+ induction H; congr; ext1; exact h'
#align composition.sigma_composition_eq_iff Composition.sigma_composition_eq_iff
/-- Rewriting equality in the dependent type
`Σ (c : composition n), Π (i : fin c.length), composition (c.blocks_fun i)` in
non-dependent terms with lists, requiring that the lists of blocks coincide. -/
theorem sigma_pi_composition_eq_iff
- (u v : Σc : Composition n, ∀ i : Fin c.length, Composition (c.blocksFun i)) :
+ (u v : Σ c : Composition n, ∀ i : Fin c.length, Composition (c.blocksFun i)) :
u = v ↔ (ofFn fun i => (u.2 i).blocks) = ofFn fun i => (v.2 i).blocks :=
by
refine' ⟨fun H => by rw [H], fun H => _⟩
rcases u with ⟨a, b⟩
rcases v with ⟨a', b'⟩
- dsimp at H
+ dsimp at H
have h : a = a' := by
ext1
have :
map List.sum (of_fn fun i : Fin (Composition.length a) => (b i).blocks) =
map List.sum (of_fn fun i : Fin (Composition.length a') => (b' i).blocks) :=
by rw [H]
- simp only [map_of_fn] at this
+ simp only [map_of_fn] at this
change
(of_fn fun i : Fin (Composition.length a) => (b i).blocks.Sum) =
of_fn fun i : Fin (Composition.length a') => (b' i).blocks.Sum at
- this
+ this
simpa [Composition.blocks_sum, Composition.ofFn_blocksFun] using this
induction h
simp only [true_and_iff, eq_self_iff_true, heq_iff_eq]
@@ -1009,7 +1013,7 @@ theorem sigma_pi_composition_eq_iff
nth_le (of_fn fun i : Fin (Composition.length a) => (b i).blocks) i (by simp [i.is_lt]) =
nth_le (of_fn fun i : Fin (Composition.length a) => (b' i).blocks) i (by simp [i.is_lt]) :=
nth_le_of_eq H _
- rwa [nth_le_of_fn, nth_le_of_fn] at this
+ rwa [nth_le_of_fn, nth_le_of_fn] at this
#align composition.sigma_pi_composition_eq_iff Composition.sigma_pi_composition_eq_iff
/-- When `a` is a composition of `n` and `b` is a composition of `a.length`, `a.gather b` is the
@@ -1140,8 +1144,8 @@ Conversely, if one starts from `c` and the `dᵢ`s, one can join the `dᵢ`s to
inverse map of the equiv.
-/
def sigmaEquivSigmaPi (n : ℕ) :
- (Σa : Composition n, Composition a.length) ≃
- Σc : Composition n, ∀ i : Fin c.length, Composition (c.blocksFun i)
+ (Σ a : Composition n, Composition a.length) ≃
+ Σ c : Composition n, ∀ i : Fin c.length, Composition (c.blocksFun i)
where
toFun i := ⟨i.1.gather i.2, i.1.sigmaCompositionAux i.2⟩
invFun i :=
@@ -1218,9 +1222,9 @@ theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinear
ext (n v)
/- First, rewrite the two compositions appearing in the theorem as two sums over complicated
sigma types, as in the description of the proof above. -/
- let f : (Σa : Composition n, Composition a.length) → H := fun c =>
+ let f : (Σ a : Composition n, Composition a.length) → H := fun c =>
r c.2.length (apply_composition q c.2 (apply_composition p c.1 v))
- let g : (Σc : Composition n, ∀ i : Fin c.length, Composition (c.blocksFun i)) → H := fun c =>
+ let g : (Σ c : Composition n, ∀ i : Fin c.length, Composition (c.blocksFun i)) → H := fun c =>
r c.1.length fun i : Fin c.1.length =>
q (c.2 i).length (apply_composition p (c.2 i) (v ∘ c.1.Embedding i))
suffices (∑ c, f c) = ∑ c, g c by
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -75,7 +75,7 @@ variable {𝕜 : Type _} {E F G H : Type _}
open Filter List
-open Topology BigOperators Classical NNReal ENNReal
+open scoped Topology BigOperators Classical NNReal ENNReal
section Topological
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -376,12 +376,6 @@ section
variable (𝕜 E)
-/- warning: formal_multilinear_series.id -> FormalMultilinearSeries.id is a dubious translation:
-lean 3 declaration is
- forall (𝕜 : Type.{u1}) (E : Type.{u2}) [_inst_1 : NontriviallyNormedField.{u1} 𝕜] [_inst_2 : NormedAddCommGroup.{u2} E] [_inst_3 : NormedSpace.{u1, u2} 𝕜 E (NontriviallyNormedField.toNormedField.{u1} 𝕜 _inst_1) (NormedAddCommGroup.toSeminormedAddCommGroup.{u2} E _inst_2)], FormalMultilinearSeries.{u1, u2, u2} 𝕜 E E (NormedRing.toRing.{u1} 𝕜 (NormedCommRing.toNormedRing.{u1} 𝕜 (NormedField.toNormedCommRing.{u1} 𝕜 (NontriviallyNormedField.toNormedField.{u1} 𝕜 _inst_1)))) (NormedAddCommGroup.toAddCommGroup.{u2} E _inst_2) (NormedSpace.toModule.{u1, u2} 𝕜 E (NontriviallyNormedField.toNormedField.{u1} 𝕜 _inst_1) (NormedAddCommGroup.toSeminormedAddCommGroup.{u2} E _inst_2) _inst_3) (UniformSpace.toTopologicalSpace.{u2} E (PseudoMetricSpace.toUniformSpace.{u2} E (SeminormedAddCommGroup.toPseudoMetricSpace.{u2} E (NormedAddCommGroup.toSeminormedAddCommGroup.{u2} E _inst_2)))) (FormalMultilinearSeries.Id._proof_1.{u2} E _inst_2) (FormalMultilinearSeries.Id._proof_2.{u1, u2} 𝕜 E _inst_1 _inst_2 _inst_3) (NormedAddCommGroup.toAddCommGroup.{u2} E _inst_2) (NormedSpace.toModule.{u1, u2} 𝕜 E (NontriviallyNormedField.toNormedField.{u1} 𝕜 _inst_1) (NormedAddCommGroup.toSeminormedAddCommGroup.{u2} E _inst_2) _inst_3) (UniformSpace.toTopologicalSpace.{u2} E (PseudoMetricSpace.toUniformSpace.{u2} E (SeminormedAddCommGroup.toPseudoMetricSpace.{u2} E (NormedAddCommGroup.toSeminormedAddCommGroup.{u2} E _inst_2)))) (FormalMultilinearSeries.Id._proof_3.{u2} E _inst_2) (FormalMultilinearSeries.Id._proof_4.{u1, u2} 𝕜 E _inst_1 _inst_2 _inst_3)
-but is expected to have type
- PUnit.{max (succ (succ u1)) (succ (succ u2))}
-Case conversion may be inaccurate. Consider using '#align formal_multilinear_series.id FormalMultilinearSeries.idₓ'. -/
/-- The identity formal multilinear series, with all coefficients equal to `0` except for `n = 1`
where it is (the continuous multilinear version of) the identity. -/
def id : FormalMultilinearSeries 𝕜 E E
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -164,14 +164,12 @@ theorem applyComposition_update (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
suffices B : Function.update v j z ∘ r = Function.update (v ∘ r) j' z
· rw [B]
suffices C : Function.update v (r j') z ∘ r = Function.update (v ∘ r) j' z
- · convert C
- exact (c.embedding_comp_inv j).symm
+ · convert C; exact (c.embedding_comp_inv j).symm
exact Function.update_comp_eq_of_injective _ (c.embedding _).Injective _ _
· simp only [h, Function.update_eq_self, Function.update_noteq, Ne.def, not_false_iff]
let r : Fin (c.blocks_fun k) → Fin n := c.embedding k
change p (c.blocks_fun k) (Function.update v j z ∘ r) = p (c.blocks_fun k) (v ∘ r)
- suffices B : Function.update v j z ∘ r = v ∘ r
- · rw [B]
+ suffices B : Function.update v j z ∘ r = v ∘ r; · rw [B]
apply Function.update_comp_eq_of_not_mem_range
rwa [c.mem_range_embedding_iff']
#align formal_multilinear_series.apply_composition_update FormalMultilinearSeries.applyComposition_update
@@ -271,8 +269,7 @@ theorem comp_coeff_zero (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultil
have : {c} = (Finset.univ : Finset (Composition 0)) := by
apply Finset.eq_of_subset_of_card_le <;> simp [Finset.card_univ, composition_card 0]
rw [← this, Finset.sum_singleton, comp_along_composition_apply]
- symm
- congr
+ symm; congr
#align formal_multilinear_series.comp_coeff_zero FormalMultilinearSeries.comp_coeff_zero
@[simp]
@@ -284,9 +281,7 @@ theorem comp_coeff_zero' (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMulti
/-- The `0`-th coefficient of `q.comp p` is `q 0`. When `p` goes from `E` to `E`, this can be
expressed as a direct equality -/
theorem comp_coeff_zero'' (q : FormalMultilinearSeries 𝕜 E F) (p : FormalMultilinearSeries 𝕜 E E) :
- (q.comp p) 0 = q 0 := by
- ext v
- exact q.comp_coeff_zero p _ _
+ (q.comp p) 0 = q 0 := by ext v; exact q.comp_coeff_zero p _ _
#align formal_multilinear_series.comp_coeff_zero'' FormalMultilinearSeries.comp_coeff_zero''
/-- The first coefficient of a composition of formal multilinear series is the composition of the
@@ -316,9 +311,7 @@ theorem removeZero_comp_of_pos (q : FormalMultilinearSeries 𝕜 F G)
@[simp]
theorem comp_removeZero (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultilinearSeries 𝕜 E F) :
- q.comp p.removeZero = q.comp p := by
- ext n
- simp [FormalMultilinearSeries.comp]
+ q.comp p.removeZero = q.comp p := by ext n; simp [FormalMultilinearSeries.comp]
#align formal_multilinear_series.comp_remove_zero FormalMultilinearSeries.comp_removeZero
end FormalMultilinearSeries
@@ -367,11 +360,8 @@ theorem compAlongComposition_norm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F
theorem compAlongComposition_nnnorm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) (c : Composition n) :
- ‖q.compAlongComposition p c‖₊ ≤ ‖q c.length‖₊ * ∏ i, ‖p (c.blocksFun i)‖₊ :=
- by
- rw [← NNReal.coe_le_coe]
- push_cast
- exact q.comp_along_composition_norm p c
+ ‖q.compAlongComposition p c‖₊ ≤ ‖q c.length‖₊ * ∏ i, ‖p (c.blocksFun i)‖₊ := by
+ rw [← NNReal.coe_le_coe]; push_cast ; exact q.comp_along_composition_norm p c
#align formal_multilinear_series.comp_along_composition_nnnorm FormalMultilinearSeries.compAlongComposition_nnnorm
/-!
@@ -417,13 +407,8 @@ theorem id_apply_one' {n : ℕ} (h : n = 1) (v : Fin n → E) :
/-- For `n ≠ 1`, the `n`-th coefficient of `id 𝕜 E` is zero, by definition. -/
@[simp]
-theorem id_apply_ne_one {n : ℕ} (h : n ≠ 1) : (FormalMultilinearSeries.id 𝕜 E) n = 0 :=
- by
- cases n
- · rfl
- cases n
- · contradiction
- rfl
+theorem id_apply_ne_one {n : ℕ} (h : n ≠ 1) : (FormalMultilinearSeries.id 𝕜 E) n = 0 := by cases n;
+ · rfl; cases n; · contradiction; rfl
#align formal_multilinear_series.id_apply_ne_one FormalMultilinearSeries.id_apply_ne_one
end
@@ -478,8 +463,7 @@ theorem id_comp (p : FormalMultilinearSeries 𝕜 E F) (h : p 0 = 0) : (id 𝕜
rw [comp_along_composition_apply, id_apply_one' _ _ (Composition.single_length n_pos)]
dsimp [apply_composition]
refine' p.congr rfl fun i him hin => congr_arg v <| _
- ext
- simp
+ ext; simp
show
∀ b : Composition n,
b ∈ Finset.univ → b ≠ Composition.single n n_pos → comp_along_composition (id 𝕜 F) p b = 0
@@ -542,10 +526,8 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
‖q.comp_along_composition p c‖₊ * r ^ n ≤
(‖q c.length‖₊ * ∏ i, ‖p (c.blocks_fun i)‖₊) * r ^ n :=
mul_le_mul' (q.comp_along_composition_nnnorm p c) le_rfl
- _ = ‖q c.length‖₊ * rq ^ n * ((∏ i, ‖p (c.blocks_fun i)‖₊) * rp ^ n) * r0 ^ n :=
- by
- simp only [r, mul_pow]
- ring
+ _ = ‖q c.length‖₊ * rq ^ n * ((∏ i, ‖p (c.blocks_fun i)‖₊) * rp ^ n) * r0 ^ n := by
+ simp only [r, mul_pow]; ring
_ ≤ Cq * Cp ^ n * r0 ^ n := (mul_le_mul' (mul_le_mul' A B) le_rfl)
_ = Cq / 4 ^ n := by
simp only [r0]
@@ -999,13 +981,8 @@ theorem sigma_composition_eq_iff (i j : Σa : Composition n, Composition a.lengt
rcases i with ⟨a, b⟩
rcases j with ⟨a', b'⟩
rintro ⟨h, h'⟩
- have H : a = a' := by
- ext1
- exact h
- induction H
- congr
- ext1
- exact h'
+ have H : a = a' := by ext1; exact h
+ induction H; congr ; ext1; exact h'
#align composition.sigma_composition_eq_iff Composition.sigma_composition_eq_iff
/-- Rewriting equality in the dependent type
@@ -1079,9 +1056,7 @@ def sigmaCompositionAux (a : Composition n) (b : Composition a.length)
where
blocks :=
nthLe (a.blocks.splitWrtComposition b) i
- (by
- rw [length_split_wrt_composition, ← length_gather]
- exact i.2)
+ (by rw [length_split_wrt_composition, ← length_gather]; exact i.2)
blocks_pos i hi :=
a.blocks_pos
(by
@@ -1094,10 +1069,8 @@ theorem length_sigmaCompositionAux (a : Composition n) (b : Composition a.length
(i : Fin b.length) :
Composition.length (Composition.sigmaCompositionAux a b ⟨i, (length_gather a b).symm ▸ i.2⟩) =
Composition.blocksFun b i :=
- show List.length (nthLe (splitWrtComposition a.blocks b) i _) = blocksFun b i
- by
- rw [nth_le_map_rev List.length, nth_le_of_eq (map_length_split_wrt_composition _ _)]
- rfl
+ show List.length (nthLe (splitWrtComposition a.blocks b) i _) = blocksFun b i by
+ rw [nth_le_map_rev List.length, nth_le_of_eq (map_length_split_wrt_composition _ _)]; rfl
#align composition.length_sigma_composition_aux Composition.length_sigmaCompositionAux
theorem blocksFun_sigmaCompositionAux (a : Composition n) (b : Composition a.length)
@@ -1105,10 +1078,8 @@ theorem blocksFun_sigmaCompositionAux (a : Composition n) (b : Composition a.len
blocksFun (sigmaCompositionAux a b ⟨i, (length_gather a b).symm ▸ i.2⟩)
⟨j, (length_sigmaCompositionAux a b i).symm ▸ j.2⟩ =
blocksFun a (embedding b i j) :=
- show nthLe (nthLe _ _ _) _ _ = nthLe a.blocks _ _
- by
- rw [nth_le_of_eq (nth_le_split_wrt_composition _ _ _), nth_le_drop', nth_le_take']
- rfl
+ show nthLe (nthLe _ _ _) _ _ = nthLe a.blocks _ _ by
+ rw [nth_le_of_eq (nth_le_split_wrt_composition _ _ _), nth_le_drop', nth_le_take']; rfl
#align composition.blocks_fun_sigma_composition_aux Composition.blocksFun_sigmaCompositionAux
/-- Auxiliary lemma to prove that the composition of formal multilinear series is associative.
@@ -1147,11 +1118,8 @@ theorem sizeUpTo_sizeUpTo_add (a : Composition n) (b : Composition a.length) {i
congr
rw [take_append_drop]
· have A : j < blocks_fun b ⟨i, hi⟩ := lt_trans (lt_add_one j) hj
- have B : j < length (sigma_composition_aux a b ⟨i, (length_gather a b).symm ▸ hi⟩) :=
- by
- convert A
- rw [← length_sigma_composition_aux]
- rfl
+ have B : j < length (sigma_composition_aux a b ⟨i, (length_gather a b).symm ▸ hi⟩) := by
+ convert A; rw [← length_sigma_composition_aux]; rfl
have C : size_up_to b i + j < size_up_to b (i + 1) :=
by
simp only [size_up_to_succ b hi, add_lt_add_iff_left]
@@ -1193,9 +1161,7 @@ def sigmaEquivSigmaPi (n : ℕ) :
blocks_pos :=
forall_mem_ofFn_iff.2 fun j =>
Composition.length_pos_of_pos _ (Composition.blocks_pos' _ _ _)
- blocks_sum := by
- dsimp only [Composition.length]
- simp [sum_of_fn] }⟩
+ blocks_sum := by dsimp only [Composition.length]; simp [sum_of_fn] }⟩
left_inv :=
by
-- the fact that we have a left inverse is essentially `join_split_wrt_composition`,
mathlib commit https://github.com/leanprover-community/mathlib/commit/75e7fca56381d056096ce5d05e938f63a6567828
@@ -386,6 +386,12 @@ section
variable (𝕜 E)
+/- warning: formal_multilinear_series.id -> FormalMultilinearSeries.id is a dubious translation:
+lean 3 declaration is
+ forall (𝕜 : Type.{u1}) (E : Type.{u2}) [_inst_1 : NontriviallyNormedField.{u1} 𝕜] [_inst_2 : NormedAddCommGroup.{u2} E] [_inst_3 : NormedSpace.{u1, u2} 𝕜 E (NontriviallyNormedField.toNormedField.{u1} 𝕜 _inst_1) (NormedAddCommGroup.toSeminormedAddCommGroup.{u2} E _inst_2)], FormalMultilinearSeries.{u1, u2, u2} 𝕜 E E (NormedRing.toRing.{u1} 𝕜 (NormedCommRing.toNormedRing.{u1} 𝕜 (NormedField.toNormedCommRing.{u1} 𝕜 (NontriviallyNormedField.toNormedField.{u1} 𝕜 _inst_1)))) (NormedAddCommGroup.toAddCommGroup.{u2} E _inst_2) (NormedSpace.toModule.{u1, u2} 𝕜 E (NontriviallyNormedField.toNormedField.{u1} 𝕜 _inst_1) (NormedAddCommGroup.toSeminormedAddCommGroup.{u2} E _inst_2) _inst_3) (UniformSpace.toTopologicalSpace.{u2} E (PseudoMetricSpace.toUniformSpace.{u2} E (SeminormedAddCommGroup.toPseudoMetricSpace.{u2} E (NormedAddCommGroup.toSeminormedAddCommGroup.{u2} E _inst_2)))) (FormalMultilinearSeries.Id._proof_1.{u2} E _inst_2) (FormalMultilinearSeries.Id._proof_2.{u1, u2} 𝕜 E _inst_1 _inst_2 _inst_3) (NormedAddCommGroup.toAddCommGroup.{u2} E _inst_2) (NormedSpace.toModule.{u1, u2} 𝕜 E (NontriviallyNormedField.toNormedField.{u1} 𝕜 _inst_1) (NormedAddCommGroup.toSeminormedAddCommGroup.{u2} E _inst_2) _inst_3) (UniformSpace.toTopologicalSpace.{u2} E (PseudoMetricSpace.toUniformSpace.{u2} E (SeminormedAddCommGroup.toPseudoMetricSpace.{u2} E (NormedAddCommGroup.toSeminormedAddCommGroup.{u2} E _inst_2)))) (FormalMultilinearSeries.Id._proof_3.{u2} E _inst_2) (FormalMultilinearSeries.Id._proof_4.{u1, u2} 𝕜 E _inst_1 _inst_2 _inst_3)
+but is expected to have type
+ PUnit.{max (succ (succ u1)) (succ (succ u2))}
+Case conversion may be inaccurate. Consider using '#align formal_multilinear_series.id FormalMultilinearSeries.idₓ'. -/
/-- The identity formal multilinear series, with all coefficients equal to `0` except for `n = 1`
where it is (the continuous multilinear version of) the identity. -/
def id : FormalMultilinearSeries 𝕜 E E
mathlib commit https://github.com/leanprover-community/mathlib/commit/039ef89bef6e58b32b62898dd48e9d1a4312bb65
@@ -112,14 +112,14 @@ def applyComposition (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ} (c : Compo
theorem applyComposition_ones (p : FormalMultilinearSeries 𝕜 E F) (n : ℕ) :
p.applyComposition (Composition.ones n) = fun v i =>
- p 1 fun _ => v (Fin.castLe (Composition.length_le _) i) :=
+ p 1 fun _ => v (Fin.castLE (Composition.length_le _) i) :=
by
funext v i
apply p.congr (Composition.ones_blocksFun _ _)
intro j hjn hj1
obtain rfl : j = 0 := by linarith
refine' congr_arg v _
- rw [Fin.ext_iff, Fin.coe_castLe, Composition.ones_embedding, Fin.val_mk]
+ rw [Fin.ext_iff, Fin.coe_castLE, Composition.ones_embedding, Fin.val_mk]
#align formal_multilinear_series.apply_composition_ones FormalMultilinearSeries.applyComposition_ones
theorem applyComposition_single (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ} (hn : 0 < n)
@@ -435,7 +435,7 @@ theorem comp_id (p : FormalMultilinearSeries 𝕜 E F) : p.comp (id 𝕜 E) = p
intros
rw [apply_composition_ones]
refine' congr_arg v _
- rw [Fin.ext_iff, Fin.coe_castLe, Fin.val_mk, Fin.val_mk]
+ rw [Fin.ext_iff, Fin.coe_castLE, Fin.val_mk, Fin.val_mk]
show
∀ b : Composition n,
b ∈ Finset.univ → b ≠ Composition.ones n → comp_along_composition p (id 𝕜 E) b = 0
mathlib commit https://github.com/leanprover-community/mathlib/commit/ce11c3c2a285bbe6937e26d9792fda4e51f3fe1a
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Johan Commelin
! This file was ported from Lean 3 source module analysis.analytic.composition
-! leanprover-community/mathlib commit 57ac39bd365c2f80589a700f9fbb664d3a1a30c2
+! leanprover-community/mathlib commit ce11c3c2a285bbe6937e26d9792fda4e51f3fe1a
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
@@ -202,8 +202,12 @@ def compAlongComposition {n : ℕ} (p : FormalMultilinearSeries 𝕜 E F) (c : C
ContinuousMultilinearMap 𝕜 (fun i : Fin n => E) G
where
toFun v := f (p.applyComposition c v)
- map_add' v i x y := by simp only [apply_composition_update, ContinuousMultilinearMap.map_add]
- map_smul' v i c x := by simp only [apply_composition_update, ContinuousMultilinearMap.map_smul]
+ map_add' _ v i x y := by
+ cases Subsingleton.elim ‹_› (Fin.decidableEq _)
+ simp only [apply_composition_update, ContinuousMultilinearMap.map_add]
+ map_smul' _ v i c x := by
+ cases Subsingleton.elim ‹_› (Fin.decidableEq _)
+ simp only [apply_composition_update, ContinuousMultilinearMap.map_smul]
cont :=
f.cont.comp <|
continuous_pi fun i => (coe_continuous _).comp <| continuous_pi fun j => continuous_apply _
mathlib commit https://github.com/leanprover-community/mathlib/commit/ce7e9d53d4bbc38065db3b595cd5bd73c323bc1d
@@ -551,7 +551,7 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
convert hasSum_fintype fun c : Composition n => (4 ^ n : ℝ≥0)⁻¹
simp [Finset.card_univ, composition_card, div_eq_mul_inv]
refine' NNReal.summable_sigma.2 ⟨fun n => (this n).Summable, (NNReal.summable_nat_add_iff 1).1 _⟩
- convert (NNReal.summable_geometric (NNReal.div_lt_one_of_lt one_lt_two)).mul_left (1 / 4)
+ convert(NNReal.summable_geometric (NNReal.div_lt_one_of_lt one_lt_two)).mul_left (1 / 4)
ext1 n
rw [(this _).tsum_eq, add_tsub_cancel_right]
field_simp [← mul_assoc, pow_succ', mul_pow, show (4 : ℝ≥0) = 2 * 2 from (two_mul 2).symm,
mathlib commit https://github.com/leanprover-community/mathlib/commit/195fcd60ff2bfe392543bceb0ec2adcdb472db4c
@@ -795,10 +795,10 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
`min (r, rf, δ)` be this new radius.-/
have : ContinuousAt f x := Hf.analytic_at.continuous_at
obtain ⟨δ, δpos, hδ⟩ :
- ∃ (δ : ℝ≥0∞)(H : 0 < δ), ∀ {z : E}, z ∈ Emetric.ball x δ → f z ∈ Emetric.ball (f x) rg :=
+ ∃ (δ : ℝ≥0∞)(H : 0 < δ), ∀ {z : E}, z ∈ EMetric.ball x δ → f z ∈ EMetric.ball (f x) rg :=
by
- have : Emetric.ball (f x) rg ∈ 𝓝 (f x) := Emetric.ball_mem_nhds _ Hg.r_pos
- rcases Emetric.mem_nhds_iff.1 (Hf.analytic_at.continuous_at this) with ⟨δ, δpos, Hδ⟩
+ have : EMetric.ball (f x) rg ∈ 𝓝 (f x) := EMetric.ball_mem_nhds _ Hg.r_pos
+ rcases EMetric.mem_nhds_iff.1 (Hf.analytic_at.continuous_at this) with ⟨δ, δpos, Hδ⟩
exact ⟨δ, δpos, fun z hz => Hδ hz⟩
let rf' := min rf δ
have min_pos : 0 < min rf' r := by
@@ -812,13 +812,13 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
/- Let `y` satisfy `‖y‖ < min (r, rf', δ)`. We want to show that `g (f (x + y))` is the sum of
`q.comp p` applied to `y`. -/
-- First, check that `y` is small enough so that estimates for `f` and `g` apply.
- have y_mem : y ∈ Emetric.ball (0 : E) rf :=
- (Emetric.ball_subset_ball (le_trans (min_le_left _ _) (min_le_left _ _))) hy
- have fy_mem : f (x + y) ∈ Emetric.ball (f x) rg :=
+ have y_mem : y ∈ EMetric.ball (0 : E) rf :=
+ (EMetric.ball_subset_ball (le_trans (min_le_left _ _) (min_le_left _ _))) hy
+ have fy_mem : f (x + y) ∈ EMetric.ball (f x) rg :=
by
apply hδ
- have : y ∈ Emetric.ball (0 : E) δ :=
- (Emetric.ball_subset_ball (le_trans (min_le_left _ _) (min_le_right _ _))) hy
+ have : y ∈ EMetric.ball (0 : E) δ :=
+ (EMetric.ball_subset_ball (le_trans (min_le_left _ _) (min_le_right _ _))) hy
simpa [edist_eq_coe_nnnorm_sub, edist_eq_coe_nnnorm]
/- Now the proof starts. To show that the sum of `q.comp p` at `y` is `g (f (x + y))`, we will
write `q.comp p` applied to `y` as a big sum over all compositions. Since the sum is
@@ -855,8 +855,8 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
by
refine' ContinuousAt.comp _ (continuous_const.add continuous_id).ContinuousAt
simp only [add_sub_cancel'_right, id.def]
- exact Hg.continuous_on.continuous_at (IsOpen.mem_nhds Emetric.isOpen_ball fy_mem)
- have B₂ : f (x + y) - f x ∈ Emetric.ball (0 : F) rg := by
+ exact Hg.continuous_on.continuous_at (IsOpen.mem_nhds EMetric.isOpen_ball fy_mem)
+ have B₂ : f (x + y) - f x ∈ EMetric.ball (0 : F) rg := by
simpa [edist_eq_coe_nnnorm, edist_eq_coe_nnnorm_sub] using fy_mem
rw [← emetric.is_open_ball.nhds_within_eq B₂] at A
convert Hg.tendsto_locally_uniformly_on.tendsto_comp B₁.continuous_within_at B₂ A
@@ -891,7 +891,7 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
rw [Finset.prod_const, Finset.card_fin]
apply pow_le_pow_of_le_left (norm_nonneg _)
- rw [Emetric.mem_ball, edist_eq_coe_nnnorm] at hy
+ rw [EMetric.mem_ball, edist_eq_coe_nnnorm] at hy
have := le_trans (le_of_lt hy) (min_le_right _ _)
rwa [ENNReal.coe_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
mathlib commit https://github.com/leanprover-community/mathlib/commit/4c586d291f189eecb9d00581aeb3dd998ac34442
@@ -334,7 +334,7 @@ theorem compAlongComposition_bound {n : ℕ} (p : FormalMultilinearSeries 𝕜 E
‖f.compAlongComposition p c v‖ ≤ (‖f‖ * ∏ i, ‖p (c.blocksFun i)‖) * ∏ i : Fin n, ‖v i‖ :=
calc
‖f.compAlongComposition p c v‖ = ‖f (p.applyComposition c v)‖ := rfl
- _ ≤ ‖f‖ * ∏ i, ‖p.applyComposition c v i‖ := ContinuousMultilinearMap.le_op_norm _ _
+ _ ≤ ‖f‖ * ∏ i, ‖p.applyComposition c v i‖ := (ContinuousMultilinearMap.le_op_norm _ _)
_ ≤ ‖f‖ * ∏ i, ‖p (c.blocksFun i)‖ * ∏ j : Fin (c.blocksFun i), ‖(v ∘ c.Embedding i) j‖ :=
by
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
@@ -524,7 +524,7 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
calc
(∏ i, ‖p (c.blocks_fun i)‖₊) * rp ^ n = ∏ i, ‖p (c.blocks_fun i)‖₊ * rp ^ c.blocks_fun i := by
simp only [Finset.prod_mul_distrib, Finset.prod_pow_eq_pow_sum, c.sum_blocks_fun]
- _ ≤ ∏ i : Fin c.length, Cp := Finset.prod_le_prod' fun i _ => hCp _
+ _ ≤ ∏ i : Fin c.length, Cp := (Finset.prod_le_prod' fun i _ => hCp _)
_ = Cp ^ c.length := by simp
_ ≤ Cp ^ n := pow_le_pow hCp1 c.length_le
@@ -536,7 +536,7 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
by
simp only [r, mul_pow]
ring
- _ ≤ Cq * Cp ^ n * r0 ^ n := mul_le_mul' (mul_le_mul' A B) le_rfl
+ _ ≤ Cq * Cp ^ n * r0 ^ n := (mul_le_mul' (mul_le_mul' A B) le_rfl)
_ = Cq / 4 ^ n := by
simp only [r0]
field_simp [mul_pow, (zero_lt_one.trans_le hCp1).ne']
mathlib commit https://github.com/leanprover-community/mathlib/commit/9da1b3534b65d9661eb8f42443598a92bbb49211
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Johan Commelin
! This file was ported from Lean 3 source module analysis.analytic.composition
-! leanprover-community/mathlib commit b2ff9a3d7a15fd5b0f060b135421d6a89a999c2f
+! leanprover-community/mathlib commit 57ac39bd365c2f80589a700f9fbb664d3a1a30c2
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
@@ -497,8 +497,8 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
/- This follows from the fact that the growth rate of `‖qₙ‖` and `‖pₙ‖` is at most geometric,
giving a geometric bound on each `‖q.comp_along_composition p op‖`, together with the
fact that there are `2^(n-1)` compositions of `n`, giving at most a geometric loss. -/
- rcases ENNReal.lt_iff_exists_nnreal_btwn.1 (lt_min ENNReal.zero_lt_one hq) with ⟨rq, rq_pos, hrq⟩
- rcases ENNReal.lt_iff_exists_nnreal_btwn.1 (lt_min ENNReal.zero_lt_one hp) with ⟨rp, rp_pos, hrp⟩
+ rcases ENNReal.lt_iff_exists_nnreal_btwn.1 (lt_min zero_lt_one hq) with ⟨rq, rq_pos, hrq⟩
+ rcases ENNReal.lt_iff_exists_nnreal_btwn.1 (lt_min zero_lt_one hp) with ⟨rp, rp_pos, hrp⟩
simp only [lt_min_iff, ENNReal.coe_lt_one_iff, ENNReal.coe_pos] at hrp hrq rp_pos rq_pos
obtain ⟨Cq, hCq0, hCq⟩ : ∃ Cq > 0, ∀ n, ‖q n‖₊ * rq ^ n ≤ Cq :=
q.nnnorm_mul_pow_le_of_lt_radius hrq.2
mathlib commit https://github.com/leanprover-community/mathlib/commit/eb0cb4511aaef0da2462207b67358a0e1fe1e2ee
@@ -75,7 +75,7 @@ variable {𝕜 : Type _} {E F G H : Type _}
open Filter List
-open Topology BigOperators Classical NNReal Ennreal
+open Topology BigOperators Classical NNReal ENNReal
section Topological
@@ -497,9 +497,9 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
/- This follows from the fact that the growth rate of `‖qₙ‖` and `‖pₙ‖` is at most geometric,
giving a geometric bound on each `‖q.comp_along_composition p op‖`, together with the
fact that there are `2^(n-1)` compositions of `n`, giving at most a geometric loss. -/
- rcases Ennreal.lt_iff_exists_nNReal_btwn.1 (lt_min Ennreal.zero_lt_one hq) with ⟨rq, rq_pos, hrq⟩
- rcases Ennreal.lt_iff_exists_nNReal_btwn.1 (lt_min Ennreal.zero_lt_one hp) with ⟨rp, rp_pos, hrp⟩
- simp only [lt_min_iff, Ennreal.coe_lt_one_iff, Ennreal.coe_pos] at hrp hrq rp_pos rq_pos
+ rcases ENNReal.lt_iff_exists_nnreal_btwn.1 (lt_min ENNReal.zero_lt_one hq) with ⟨rq, rq_pos, hrq⟩
+ rcases ENNReal.lt_iff_exists_nnreal_btwn.1 (lt_min ENNReal.zero_lt_one hp) with ⟨rp, rp_pos, hrp⟩
+ simp only [lt_min_iff, ENNReal.coe_lt_one_iff, ENNReal.coe_pos] at hrp hrq rp_pos rq_pos
obtain ⟨Cq, hCq0, hCq⟩ : ∃ Cq > 0, ∀ n, ‖q n‖₊ * rq ^ n ≤ Cq :=
q.nnnorm_mul_pow_le_of_lt_radius hrq.2
obtain ⟨Cp, hCp1, hCp⟩ : ∃ Cp ≥ 1, ∀ n, ‖p n‖₊ * rp ^ n ≤ Cp :=
@@ -802,7 +802,7 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
exact ⟨δ, δpos, fun z hz => Hδ hz⟩
let rf' := min rf δ
have min_pos : 0 < min rf' r := by
- simp only [r_pos, Hf.r_pos, δpos, lt_min_iff, Ennreal.coe_pos, and_self_iff]
+ simp only [r_pos, Hf.r_pos, δpos, lt_min_iff, ENNReal.coe_pos, and_self_iff]
/- We will show that `g ∘ f` admits the power series `q.comp p` in the disk of
radius `min (r, rf', δ)`. -/
refine' ⟨min rf' r, _⟩
@@ -893,7 +893,7 @@ theorem HasFpowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
apply pow_le_pow_of_le_left (norm_nonneg _)
rw [Emetric.mem_ball, edist_eq_coe_nnnorm] at hy
have := le_trans (le_of_lt hy) (min_le_right _ _)
- rwa [Ennreal.coe_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
+ rwa [ENNReal.coe_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
tendsto_nhds_of_cauchySeq_of_subseq cau comp_partial_sum_target_tendsto_at_top C
-- Fifth step: the sum over `n` of `q.comp p n` can be expressed as a particular resummation of
mathlib commit https://github.com/leanprover-community/mathlib/commit/271bf175e6c51b8d31d6c0107b7bb4a967c7277e
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Johan Commelin
! This file was ported from Lean 3 source module analysis.analytic.composition
-! leanprover-community/mathlib commit f2ce6086713c78a7f880485f7917ea547a215982
+! leanprover-community/mathlib commit b2ff9a3d7a15fd5b0f060b135421d6a89a999c2f
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
@@ -507,7 +507,7 @@ theorem comp_summable_nNReal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
rcases p.nnnorm_mul_pow_le_of_lt_radius hrp.2 with ⟨Cp, -, hCp⟩
exact ⟨max Cp 1, le_max_right _ _, fun n => (hCp n).trans (le_max_left _ _)⟩
let r0 : ℝ≥0 := (4 * Cp)⁻¹
- have r0_pos : 0 < r0 := NNReal.inv_pos.2 (mul_pos zero_lt_four (zero_lt_one.trans_le hCp1))
+ have r0_pos : 0 < r0 := inv_pos.2 (mul_pos zero_lt_four (zero_lt_one.trans_le hCp1))
set r : ℝ≥0 := rp * rq * r0
have r_pos : 0 < r := mul_pos (mul_pos rp_pos rq_pos) r0_pos
have I :
mathlib commit https://github.com/leanprover-community/mathlib/commit/bd9851ca476957ea4549eb19b40e7b5ade9428cc
These are changes from #11997, the latest adaptation PR for nightly-2024-04-07, which can be made directly on master.
Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com>
@@ -796,7 +796,7 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
-- composition passes to the limit under locally uniform convergence.
have B₁ : ContinuousAt (fun z : F => g (f x + z)) (f (x + y) - f x) := by
refine' ContinuousAt.comp _ (continuous_const.add continuous_id).continuousAt
- simp only [add_sub_cancel, id.def]
+ simp only [add_sub_cancel, _root_.id]
exact Hg.continuousOn.continuousAt (IsOpen.mem_nhds EMetric.isOpen_ball fy_mem)
have B₂ : f (x + y) - f x ∈ EMetric.ball (0 : F) rg := by
simpa [edist_eq_coe_nnnorm, edist_eq_coe_nnnorm_sub] using fy_mem
@@ -313,7 +313,7 @@ theorem compAlongComposition_bound {n : ℕ} (p : FormalMultilinearSeries 𝕜 E
‖f.compAlongComposition p c v‖ ≤ (‖f‖ * ∏ i, ‖p (c.blocksFun i)‖) * ∏ i : Fin n, ‖v i‖ :=
calc
‖f.compAlongComposition p c v‖ = ‖f (p.applyComposition c v)‖ := rfl
- _ ≤ ‖f‖ * ∏ i, ‖p.applyComposition c v i‖ := (ContinuousMultilinearMap.le_opNorm _ _)
+ _ ≤ ‖f‖ * ∏ i, ‖p.applyComposition c v i‖ := ContinuousMultilinearMap.le_opNorm _ _
_ ≤ ‖f‖ * ∏ i, ‖p (c.blocksFun i)‖ * ∏ j : Fin (c.blocksFun i), ‖(v ∘ c.embedding i) j‖ := by
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
refine' Finset.prod_le_prod (fun i _hi => norm_nonneg _) fun i _hi => _
@@ -486,7 +486,7 @@ theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
have B := calc
(∏ i, ‖p (c.blocksFun i)‖₊) * rp ^ n = ∏ i, ‖p (c.blocksFun i)‖₊ * rp ^ c.blocksFun i := by
simp only [Finset.prod_mul_distrib, Finset.prod_pow_eq_pow_sum, c.sum_blocksFun]
- _ ≤ ∏ _i : Fin c.length, Cp := (Finset.prod_le_prod' fun i _ => hCp _)
+ _ ≤ ∏ _i : Fin c.length, Cp := Finset.prod_le_prod' fun i _ => hCp _
_ = Cp ^ c.length := by simp
_ ≤ Cp ^ n := pow_le_pow_right hCp1 c.length_le
calc
@@ -495,7 +495,7 @@ theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
mul_le_mul' (q.compAlongComposition_nnnorm p c) le_rfl
_ = ‖q c.length‖₊ * rq ^ n * ((∏ i, ‖p (c.blocksFun i)‖₊) * rp ^ n) * r0 ^ n := by
simp only [mul_pow]; ring
- _ ≤ Cq * Cp ^ n * r0 ^ n := (mul_le_mul' (mul_le_mul' A B) le_rfl)
+ _ ≤ Cq * Cp ^ n * r0 ^ n := mul_le_mul' (mul_le_mul' A B) le_rfl
_ = Cq / 4 ^ n := by
simp only [r0]
field_simp [mul_pow, (zero_lt_one.trans_le hCp1).ne']
Purely automatic replacement. If this is in any way controversial; I'm happy to just close this PR.
@@ -739,7 +739,7 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
rcases q.comp_summable_nnreal p Hg.radius_pos Hf.radius_pos with ⟨r, r_pos : 0 < r, hr⟩
/- We will consider `y` which is smaller than `r` and `rf`, and also small enough that
`f (x + y)` is close enough to `f x` to be in the disk where `g` is well behaved. Let
- `min (r, rf, δ)` be this new radius.-/
+ `min (r, rf, δ)` be this new radius. -/
obtain ⟨δ, δpos, hδ⟩ :
∃ δ : ℝ≥0∞, 0 < δ ∧ ∀ {z : E}, z ∈ EMetric.ball x δ → f z ∈ EMetric.ball (f x) rg := by
have : EMetric.ball (f x) rg ∈ 𝓝 (f x) := EMetric.ball_mem_nhds _ Hg.r_pos
@@ -1183,7 +1183,7 @@ theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinear
`r`, and the same component of `q`, and the same component of `p`, to the same coordinate of
`v`. This is true by definition, but at each step one needs to convince Lean that the types
one considers are the same, using a suitable congruence lemma to avoid dependent type issues.
- This dance has to be done three times, one for `r`, one for `q` and one for `p`.-/
+ This dance has to be done three times, one for `r`, one for `q` and one for `p`. -/
apply Finset.sum_congr rfl
rintro ⟨a, b⟩ _
dsimp [sigmaEquivSigmaPi]
@@ -39,9 +39,9 @@ summability of the norms, this implies the overall convergence.
## Main results
* `q.comp p` is the formal composition of the formal multilinear series `q` and `p`.
-* `has_fpower_series_at.comp` states that if two functions `g` and `f` admit power series expansions
+* `HasFPowerSeriesAt.comp` states that if two functions `g` and `f` admit power series expansions
`q` and `p`, then `g ∘ f` admits a power series expansion given by `q.comp p`.
-* `analytic_at.comp` states that the composition of analytic functions is analytic.
+* `AnalyticAt.comp` states that the composition of analytic functions is analytic.
* `FormalMultilinearSeries.comp_assoc` states that composition is associative on formal
multilinear series.
@@ -49,18 +49,18 @@ summability of the norms, this implies the overall convergence.
The main technical difficulty is to write down things. In particular, we need to define precisely
`q.comp_along_composition p c` and to show that it is indeed a continuous multilinear
-function. This requires a whole interface built on the class `composition`. Once this is set,
+function. This requires a whole interface built on the class `Composition`. Once this is set,
the main difficulty is to reorder the sums, writing the composition of the partial sums as a sum
over some subset of `Σ n, composition n`. We need to check that the reordering is a bijection,
running over difficulties due to the dependent nature of the types under consideration, that are
-controlled thanks to the interface for `composition`.
+controlled thanks to the interface for `Composition`.
The associativity of composition on formal multilinear series is a nontrivial result: it does not
follow from the associativity of composition of analytic functions, as there is no uniqueness for
the formal multilinear series representing a function (and also, it holds even when the radius of
convergence of the series is `0`). Instead, we give a direct proof, which amounts to reordering
double sums in a careful way. The change of variables is a canonical (combinatorial) bijection
-`composition.sigma_equiv_sigma_pi` between `(Σ (a : composition n), composition a.length)` and
+`Composition.sigmaEquivSigmaPi` between `(Σ (a : composition n), composition a.length)` and
`(Σ (c : composition n), Π (i : fin c.length), composition (c.blocks_fun i))`, and is described
in more details below in the paragraph on associativity.
-/
@@ -154,7 +154,7 @@ theorem applyComposition_update (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
suffices C : Function.update v (r j') z ∘ r = Function.update (v ∘ r) j' z by
convert C; exact (c.embedding_comp_inv j).symm
exact Function.update_comp_eq_of_injective _ (c.embedding _).injective _ _
- · simp only [h, Function.update_eq_self, Function.update_noteq, Ne.def, not_false_iff]
+ · simp only [h, Function.update_eq_self, Function.update_noteq, Ne, not_false_iff]
let r : Fin (c.blocksFun k) → Fin n := c.embedding k
change p (c.blocksFun k) (Function.update v j z ∘ r) = p (c.blocksFun k) (v ∘ r)
suffices B : Function.update v j z ∘ r = v ∘ r by rw [B]
We change the following field in the definition of an additive commutative monoid:
nsmul_succ : ∀ (n : ℕ) (x : G),
- AddMonoid.nsmul (n + 1) x = x + AddMonoid.nsmul n x
+ AddMonoid.nsmul (n + 1) x = AddMonoid.nsmul n x + x
where the latter is more natural
We adjust the definitions of ^
in monoids, groups, etc.
Originally there was a warning comment about why this natural order was preferred
use
x * npowRec n x
and notnpowRec n x * x
in the definition to make sure that definitional unfolding ofnpowRec
is blocked, to avoid deep recursion issues.
but it seems to no longer apply.
Remarks on the PR :
pow_succ
and pow_succ'
have switched their meanings.Ideal.IsPrime.mul_mem_pow
which is defined in [Mathlib/RingTheory/DedekindDomain/Ideal.lean]. Changing the order of operation forced me to add the symmetric lemma Ideal.IsPrime.mem_pow_mul
.@@ -511,7 +511,7 @@ theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
convert (NNReal.summable_geometric (NNReal.div_lt_one_of_lt one_lt_two)).mul_left (1 / 4) using 1
ext1 n
rw [(this _).tsum_eq, add_tsub_cancel_right]
- field_simp [← mul_assoc, pow_succ', mul_pow, show (4 : ℝ≥0) = 2 * 2 by norm_num,
+ field_simp [← mul_assoc, pow_succ, mul_pow, show (4 : ℝ≥0) = 2 * 2 by norm_num,
mul_right_comm]
#align formal_multilinear_series.comp_summable_nnreal FormalMultilinearSeries.comp_summable_nnreal
Move Catalan
, Composition
, DoubleCounting
, Partition
to a new folder Combinatorics.Enumerative
.
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Johan Commelin
-/
import Mathlib.Analysis.Analytic.Basic
-import Mathlib.Combinatorics.Composition
+import Mathlib.Combinatorics.Enumerative.Composition
#align_import analysis.analytic.composition from "leanprover-community/mathlib"@"ce11c3c2a285bbe6937e26d9792fda4e51f3fe1a"
mul
-div
cancellation lemmas (#11530)
Lemma names around cancellation of multiplication and division are a mess.
This PR renames a handful of them according to the following table (each big row contains the multiplicative statement, then the three rows contain the GroupWithZero
lemma name, the Group
lemma, the AddGroup
lemma name).
| Statement | New name | Old name | |
@@ -796,13 +796,13 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
-- composition passes to the limit under locally uniform convergence.
have B₁ : ContinuousAt (fun z : F => g (f x + z)) (f (x + y) - f x) := by
refine' ContinuousAt.comp _ (continuous_const.add continuous_id).continuousAt
- simp only [add_sub_cancel'_right, id.def]
+ simp only [add_sub_cancel, id.def]
exact Hg.continuousOn.continuousAt (IsOpen.mem_nhds EMetric.isOpen_ball fy_mem)
have B₂ : f (x + y) - f x ∈ EMetric.ball (0 : F) rg := by
simpa [edist_eq_coe_nnnorm, edist_eq_coe_nnnorm_sub] using fy_mem
rw [← EMetric.isOpen_ball.nhdsWithin_eq B₂] at A
convert Hg.tendstoLocallyUniformlyOn.tendsto_comp B₁.continuousWithinAt B₂ A
- simp only [add_sub_cancel'_right]
+ simp only [add_sub_cancel]
-- Third step: the sum over all compositions in `comp_partial_sum_target 0 n n` converges to
-- `g (f (x + y))`. As this sum is exactly the composition of the partial sum, this is a direct
-- consequence of the second step
Empty lines were removed by executing the following Python script twice
import os
import re
# Loop through each file in the repository
for dir_path, dirs, files in os.walk('.'):
for filename in files:
if filename.endswith('.lean'):
file_path = os.path.join(dir_path, filename)
# Open the file and read its contents
with open(file_path, 'r') as file:
content = file.read()
# Use a regular expression to replace sequences of "variable" lines separated by empty lines
# with sequences without empty lines
modified_content = re.sub(r'(variable.*\n)\n(variable(?! .* in))', r'\1\2', content)
# Write the modified content back to the file
with open(file_path, 'w') as file:
file.write(modified_content)
@@ -77,9 +77,7 @@ open scoped Topology BigOperators Classical NNReal ENNReal
section Topological
variable [CommRing 𝕜] [AddCommGroup E] [AddCommGroup F] [AddCommGroup G]
-
variable [Module 𝕜 E] [Module 𝕜 F] [Module 𝕜 G]
-
variable [TopologicalSpace E] [TopologicalSpace F] [TopologicalSpace G]
/-! ### Composing formal multilinear series -/
@@ -88,9 +86,7 @@ variable [TopologicalSpace E] [TopologicalSpace F] [TopologicalSpace G]
namespace FormalMultilinearSeries
variable [TopologicalAddGroup E] [ContinuousConstSMul 𝕜 E]
-
variable [TopologicalAddGroup F] [ContinuousConstSMul 𝕜 F]
-
variable [TopologicalAddGroup G] [ContinuousConstSMul 𝕜 G]
/-!
@@ -180,7 +176,6 @@ namespace ContinuousMultilinearMap
open FormalMultilinearSeries
variable [TopologicalAddGroup E] [ContinuousConstSMul 𝕜 E]
-
variable [TopologicalAddGroup F] [ContinuousConstSMul 𝕜 F]
/-- Given a formal multilinear series `p`, a composition `c` of `n` and a continuous multilinear
@@ -214,9 +209,7 @@ end ContinuousMultilinearMap
namespace FormalMultilinearSeries
variable [TopologicalAddGroup E] [ContinuousConstSMul 𝕜 E]
-
variable [TopologicalAddGroup F] [ContinuousConstSMul 𝕜 F]
-
variable [TopologicalAddGroup G] [ContinuousConstSMul 𝕜 G]
/-- Given two formal multilinear series `q` and `p` and a composition `c` of `n`, one may
Homogenises porting notes via capitalisation and addition of whitespace.
It makes the following changes:
@@ -259,7 +259,7 @@ theorem comp_coeff_zero (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultil
have : {c} = (Finset.univ : Finset (Composition 0)) := by
apply Finset.eq_of_subset_of_card_le <;> simp [Finset.card_univ, composition_card 0]
rw [← this, Finset.sum_singleton, compAlongComposition_apply]
- symm; congr! -- porting note: needed the stronger `congr!`!
+ symm; congr! -- Porting note: needed the stronger `congr!`!
#align formal_multilinear_series.comp_coeff_zero FormalMultilinearSeries.comp_coeff_zero
@[simp]
@@ -284,7 +284,7 @@ theorem comp_coeff_one (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultili
Finset.sum_singleton]
refine' q.congr (by simp) fun i hi1 hi2 => _
simp only [applyComposition_ones]
- exact p.congr rfl fun j _hj1 hj2 => by congr! -- porting note: needed the stronger `congr!`
+ exact p.congr rfl fun j _hj1 hj2 => by congr! -- Porting note: needed the stronger `congr!`
#align formal_multilinear_series.comp_coeff_one FormalMultilinearSeries.comp_coeff_one
/-- Only `0`-th coefficient of `q.comp p` depends on `q 0`. -/
I ran tryAtEachStep on all files under Mathlib
to find all locations where omega
succeeds. For each that was a linarith
without an only
, I tried replacing it with omega
, and I verified that elaboration time got smaller. (In almost all cases, there was a noticeable speedup.) I also replaced some slow aesop
s along the way.
@@ -113,7 +113,7 @@ theorem applyComposition_ones (p : FormalMultilinearSeries 𝕜 E F) (n : ℕ) :
funext v i
apply p.congr (Composition.ones_blocksFun _ _)
intro j hjn hj1
- obtain rfl : j = 0 := by linarith
+ obtain rfl : j = 0 := by omega
refine' congr_arg v _
rw [Fin.ext_iff, Fin.coe_castLE, Composition.ones_embedding, Fin.val_mk]
#align formal_multilinear_series.apply_composition_ones FormalMultilinearSeries.applyComposition_ones
Fin.eq_of_veq
and Fin.veq_of_eq
(#10626)
We have Fin.eq_of_val_eq
and Fin.val_eq_of_eq
in Lean core now.
Also slightly shake the tree.
@@ -1205,7 +1205,7 @@ theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinear
intro k hk1 hk2
-- finally, check that the coordinates of `v` one is using are the same. Based on
-- `size_up_to_size_up_to_add`.
- refine' congr_arg v (Fin.eq_of_veq _)
+ refine' congr_arg v (Fin.ext _)
dsimp [Composition.embedding]
rw [sizeUpTo_sizeUpTo_add _ _ hi1 hj1, add_assoc]
#align formal_multilinear_series.comp_assoc FormalMultilinearSeries.comp_assoc
@@ -504,7 +504,7 @@ theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
simp only [mul_pow]; ring
_ ≤ Cq * Cp ^ n * r0 ^ n := (mul_le_mul' (mul_le_mul' A B) le_rfl)
_ = Cq / 4 ^ n := by
- simp only
+ simp only [r0]
field_simp [mul_pow, (zero_lt_one.trans_le hCp1).ne']
ring
refine' ⟨r, r_pos, NNReal.summable_of_le I _⟩
@@ -754,7 +754,7 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
exact ⟨δ, δpos, fun hz => Hδ hz⟩
let rf' := min rf δ
have min_pos : 0 < min rf' r := by
- simp only [r_pos, Hf.r_pos, δpos, lt_min_iff, ENNReal.coe_pos, and_self_iff]
+ simp only [rf', r_pos, Hf.r_pos, δpos, lt_min_iff, ENNReal.coe_pos, and_self_iff]
/- We will show that `g ∘ f` admits the power series `q.comp p` in the disk of
radius `min (r, rf', δ)`. -/
refine' ⟨min rf' r, _⟩
have
, replace
and suffices
(#10640)
No changes to tactic file, it's just boring fixes throughout the library.
This follows on from #6964.
Co-authored-by: sgouezel <sebastien.gouezel@univ-rennes1.fr> Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
@@ -154,15 +154,14 @@ theorem applyComposition_update (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
simp only [Function.update_same]
change p (c.blocksFun (c.index j)) (Function.update v j z ∘ r) = _
let j' := c.invEmbedding j
- suffices B : Function.update v j z ∘ r = Function.update (v ∘ r) j' z
- · rw [B]
- suffices C : Function.update v (r j') z ∘ r = Function.update (v ∘ r) j' z
- · convert C; exact (c.embedding_comp_inv j).symm
+ suffices B : Function.update v j z ∘ r = Function.update (v ∘ r) j' z by rw [B]
+ suffices C : Function.update v (r j') z ∘ r = Function.update (v ∘ r) j' z by
+ convert C; exact (c.embedding_comp_inv j).symm
exact Function.update_comp_eq_of_injective _ (c.embedding _).injective _ _
· simp only [h, Function.update_eq_self, Function.update_noteq, Ne.def, not_false_iff]
let r : Fin (c.blocksFun k) → Fin n := c.embedding k
change p (c.blocksFun k) (Function.update v j z ∘ r) = p (c.blocksFun k) (v ∘ r)
- suffices B : Function.update v j z ∘ r = v ∘ r; · rw [B]
+ suffices B : Function.update v j z ∘ r = v ∘ r by rw [B]
apply Function.update_comp_eq_of_not_mem_range
rwa [c.mem_range_embedding_iff']
#align formal_multilinear_series.apply_composition_update FormalMultilinearSeries.applyComposition_update
@@ -487,13 +486,11 @@ theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
have I :
∀ i : Σ n : ℕ, Composition n, ‖q.compAlongComposition p i.2‖₊ * r ^ i.1 ≤ Cq / 4 ^ i.1 := by
rintro ⟨n, c⟩
- have A
- calc
+ have A := calc
‖q c.length‖₊ * rq ^ n ≤ ‖q c.length‖₊ * rq ^ c.length :=
mul_le_mul' le_rfl (pow_le_pow_of_le_one rq.2 hrq.1.le c.length_le)
_ ≤ Cq := hCq _
- have B
- calc
+ have B := calc
(∏ i, ‖p (c.blocksFun i)‖₊) * rp ^ n = ∏ i, ‖p (c.blocksFun i)‖₊ * rp ^ c.blocksFun i := by
simp only [Finset.prod_mul_distrib, Finset.prod_pow_eq_pow_sum, c.sum_blocksFun]
_ ≤ ∏ _i : Fin c.length, Cp := (Finset.prod_le_prod' fun i _ => hCp _)
@@ -718,8 +715,8 @@ theorem comp_partialSum (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultil
(∑ n in Finset.range N,
∑ r in Fintype.piFinset fun i : Fin n => Finset.Ico 1 N,
q n fun i : Fin n => p (r i) fun _j => z) =
- ∑ i in compPartialSumTarget 0 N N, q.compAlongComposition p i.2 fun _j => z
- · simpa only [FormalMultilinearSeries.partialSum, ContinuousMultilinearMap.map_sum_finset] using H
+ ∑ i in compPartialSumTarget 0 N N, q.compAlongComposition p i.2 fun _j => z by
+ simpa only [FormalMultilinearSeries.partialSum, ContinuousMultilinearMap.map_sum_finset] using H
-- rewrite the first sum as a big sum over a sigma type, in the finset
-- `comp_partial_sum_target 0 N N`
rw [Finset.range_eq_Ico, Finset.sum_sigma']
@@ -991,11 +988,9 @@ def gather (a : Composition n) (b : Composition a.length) : Composition n where
blocks_pos := by
rw [forall_mem_map_iff]
intro j hj
- suffices H : ∀ i ∈ j, 1 ≤ i;
- exact
- calc
- 0 < j.length := length_pos_of_mem_splitWrtComposition hj
- _ ≤ j.sum := length_le_sum_of_one_le _ H
+ suffices H : ∀ i ∈ j, 1 ≤ i by calc
+ 0 < j.length := length_pos_of_mem_splitWrtComposition hj
+ _ ≤ j.sum := length_le_sum_of_one_le _ H
intro i hi
apply a.one_le_blocks
rw [← a.blocks.join_splitWrtComposition b]
@@ -321,11 +321,11 @@ theorem compAlongComposition_bound {n : ℕ} (p : FormalMultilinearSeries 𝕜 E
‖f.compAlongComposition p c v‖ ≤ (‖f‖ * ∏ i, ‖p (c.blocksFun i)‖) * ∏ i : Fin n, ‖v i‖ :=
calc
‖f.compAlongComposition p c v‖ = ‖f (p.applyComposition c v)‖ := rfl
- _ ≤ ‖f‖ * ∏ i, ‖p.applyComposition c v i‖ := (ContinuousMultilinearMap.le_op_norm _ _)
+ _ ≤ ‖f‖ * ∏ i, ‖p.applyComposition c v i‖ := (ContinuousMultilinearMap.le_opNorm _ _)
_ ≤ ‖f‖ * ∏ i, ‖p (c.blocksFun i)‖ * ∏ j : Fin (c.blocksFun i), ‖(v ∘ c.embedding i) j‖ := by
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
refine' Finset.prod_le_prod (fun i _hi => norm_nonneg _) fun i _hi => _
- apply ContinuousMultilinearMap.le_op_norm
+ apply ContinuousMultilinearMap.le_opNorm
_ = (‖f‖ * ∏ i, ‖p (c.blocksFun i)‖) *
∏ i, ∏ j : Fin (c.blocksFun i), ‖(v ∘ c.embedding i) j‖ := by
rw [Finset.prod_mul_distrib, mul_assoc]
@@ -339,7 +339,7 @@ the norms of the relevant bits of `q` and `p`. -/
theorem compAlongComposition_norm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) (c : Composition n) :
‖q.compAlongComposition p c‖ ≤ ‖q c.length‖ * ∏ i, ‖p (c.blocksFun i)‖ :=
- ContinuousMultilinearMap.op_norm_le_bound _
+ ContinuousMultilinearMap.opNorm_le_bound _
(mul_nonneg (norm_nonneg _) (Finset.prod_nonneg fun _i _hi => norm_nonneg _))
(compAlongComposition_bound _ _ _)
#align formal_multilinear_series.comp_along_composition_norm FormalMultilinearSeries.compAlongComposition_norm
@@ -836,7 +836,7 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
calc
‖(compAlongComposition q p c) fun _j : Fin n => y‖ ≤
‖compAlongComposition q p c‖ * ∏ _j : Fin n, ‖y‖ :=
- by apply ContinuousMultilinearMap.le_op_norm
+ by apply ContinuousMultilinearMap.le_opNorm
_ ≤ ‖compAlongComposition q p c‖ * (r : ℝ) ^ n := by
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
rw [Finset.prod_const, Finset.card_fin]
With multiple changes, it is a good time to check if existing set_option maxHeartbeats
and set_option synthInstance.maxHeartbeats
remain necessary. This brings the number of files with such down from 23 to 9. Most are straight deletions though I did change one proof.
@@ -462,7 +462,6 @@ theorem id_comp (p : FormalMultilinearSeries 𝕜 E F) (h : p 0 = 0) : (id 𝕜
section
-set_option maxHeartbeats 300000 in
/-- If two formal multilinear series have positive radius of convergence, then the terms appearing
in the definition of their composition are also summable (when multiplied by a suitable positive
geometric term). -/
@@ -737,7 +736,6 @@ end FormalMultilinearSeries
open FormalMultilinearSeries
-set_option maxHeartbeats 300000 in
/-- If two functions `g` and `f` have power series `q` and `p` respectively at `f x` and `x`, then
`g ∘ f` admits the power series `q.comp p` at `x`. -/
theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinearSeries 𝕜 F G}
@@ -1176,7 +1174,6 @@ namespace FormalMultilinearSeries
open Composition
-set_option maxHeartbeats 500000 in
theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) : (r.comp q).comp p = r.comp (q.comp p) := by
ext n v
Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Eric Wieser <wieser.eric@gmail.com> Co-authored-by: Joachim Breitner <mail@joachim-breitner.de>
@@ -1165,9 +1165,9 @@ def sigmaEquivSigmaPi (n : ℕ) :
rw [get_of_eq (splitWrtComposition_join _ _ _)]
· simp only [get_ofFn]
rfl
- · congr
· simp only [map_ofFn]
rfl
+ · congr
#align composition.sigma_equiv_sigma_pi Composition.sigmaEquivSigmaPi
end Composition
∃ x ∈ s, p x
instead of ∃ x (_ : x ∈ s), p x
(#9326)
This is a follow-up to #9215. It changes the following theorems and definitions:
IsOpen.exists_subset_affineIndependent_span_eq_top
IsConformalMap
SimpleGraph.induce_connected_of_patches
Submonoid.exists_list_of_mem_closure
AddSubmonoid.exists_list_of_mem_closure
AffineSubspace.mem_affineSpan_insert_iff
AffineBasis.exists_affine_subbasis
exists_affineIndependent
LinearMap.mem_submoduleImage
Basis.basis_singleton_iff
atom_iff_nonzero_span
finrank_eq_one_iff'
Submodule.basis_of_pid_aux
exists_linearIndependent_extension
exists_linearIndependent
countable_cover_nhdsWithin_of_sigma_compact
mem_residual
Also deprecate ENNReal.exists_ne_top'
.
@@ -753,7 +753,7 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
`f (x + y)` is close enough to `f x` to be in the disk where `g` is well behaved. Let
`min (r, rf, δ)` be this new radius.-/
obtain ⟨δ, δpos, hδ⟩ :
- ∃ (δ : ℝ≥0∞) (_H : 0 < δ), ∀ {z : E}, z ∈ EMetric.ball x δ → f z ∈ EMetric.ball (f x) rg := by
+ ∃ δ : ℝ≥0∞, 0 < δ ∧ ∀ {z : E}, z ∈ EMetric.ball x δ → f z ∈ EMetric.ball (f x) rg := by
have : EMetric.ball (f x) rg ∈ 𝓝 (f x) := EMetric.ball_mem_nhds _ Hg.r_pos
rcases EMetric.mem_nhds_iff.1 (Hf.analyticAt.continuousAt this) with ⟨δ, δpos, Hδ⟩
exact ⟨δ, δpos, fun hz => Hδ hz⟩
Lemmas around this were a mess, throth in terms of names, statement and location. This PR standardises everything to be in Algebra.BigOperators.Basic
and changes the lemmas to take in InjOn
and SurjOn
assumptions where possible (and where impossible make sure the hypotheses are taken in the correct order) and moves the equality of functions hypothesis last.
Also add a few lemmas that help fix downstream uses by golfing.
From LeanAPAP and LeanCamCombi
@@ -616,7 +616,7 @@ def compPartialSumTargetSet (m M N : ℕ) : Set (Σ n, Composition n) :=
theorem compPartialSumTargetSet_image_compPartialSumSource (m M N : ℕ)
(i : Σ n, Composition n) (hi : i ∈ compPartialSumTargetSet m M N) :
- ∃ (j : _) (hj : j ∈ compPartialSumSource m M N), i = compChangeOfVariables m M N j hj := by
+ ∃ (j : _) (hj : j ∈ compPartialSumSource m M N), compChangeOfVariables m M N j hj = i := by
rcases i with ⟨n, c⟩
refine' ⟨⟨c.length, c.blocksFun⟩, _, _⟩
· simp only [compPartialSumTargetSet, Set.mem_setOf_eq] at hi
@@ -625,7 +625,7 @@ theorem compPartialSumTargetSet_image_compPartialSumSource (m M N : ℕ)
· dsimp [compChangeOfVariables]
rw [Composition.sigma_eq_iff_blocks_eq]
simp only [Composition.blocksFun, Composition.blocks, Subtype.coe_eta, List.get_map]
- conv_lhs => rw [← List.ofFn_get c.blocks]
+ conv_rhs => rw [← List.ofFn_get c.blocks]
#align formal_multilinear_series.comp_partial_sum_target_subset_image_comp_partial_sum_source FormalMultilinearSeries.compPartialSumTargetSet_image_compPartialSumSource
/-- Target set in the change of variables to compute the composition of partial sums of formal
@@ -665,11 +665,8 @@ theorem compChangeOfVariables_sum {α : Type*} [AddCommMonoid α] (m M N : ℕ)
map_ofFn, length_ofFn, true_and_iff, compChangeOfVariables]
intro j
simp only [Composition.blocksFun, (H.right _).right, List.get_ofFn]
- -- 2 - show that the composition gives the `comp_along_composition` application
- · rintro ⟨k, blocks_fun⟩ H
- rw [h]
- -- 3 - show that the map is injective
- · rintro ⟨k, blocks_fun⟩ ⟨k', blocks_fun'⟩ H H' heq
+ -- 2 - show that the map is injective
+ · rintro ⟨k, blocks_fun⟩ H ⟨k', blocks_fun'⟩ H' heq
obtain rfl : k = k' := by
have := (compChangeOfVariables_length m M N H).symm
rwa [heq, compChangeOfVariables_length] at this
@@ -682,10 +679,13 @@ theorem compChangeOfVariables_sum {α : Type*} [AddCommMonoid α] (m M N : ℕ)
apply Composition.blocksFun_congr <;>
first | rw [heq] | rfl
_ = blocks_fun' i := compChangeOfVariables_blocksFun m M N H' i
- -- 4 - show that the map is surjective
+ -- 3 - show that the map is surjective
· intro i hi
apply compPartialSumTargetSet_image_compPartialSumSource m M N i
simpa [compPartialSumTarget] using hi
+ -- 4 - show that the composition gives the `comp_along_composition` application
+ · rintro ⟨k, blocks_fun⟩ H
+ rw [h]
#align formal_multilinear_series.comp_change_of_variables_sum FormalMultilinearSeries.compChangeOfVariables_sum
/-- The auxiliary set corresponding to the composition of partial sums asymptotically contains
The names for lemmas about monotonicity of (a ^ ·)
and (· ^ n)
were a mess. This PR tidies up everything related by following the naming convention for (a * ·)
and (· * b)
. Namely, (a ^ ·)
is pow_right
and (· ^ n)
is pow_left
in lemma names. All lemma renames follow the corresponding multiplication lemma names closely.
Algebra.GroupPower.Order
pow_mono
→ pow_right_mono
pow_le_pow
→ pow_le_pow_right
pow_le_pow_of_le_left
→ pow_le_pow_left
pow_lt_pow_of_lt_left
→ pow_lt_pow_left
strictMonoOn_pow
→ pow_left_strictMonoOn
pow_strictMono_right
→ pow_right_strictMono
pow_lt_pow
→ pow_lt_pow_right
pow_lt_pow_iff
→ pow_lt_pow_iff_right
pow_le_pow_iff
→ pow_le_pow_iff_right
self_lt_pow
→ lt_self_pow
strictAnti_pow
→ pow_right_strictAnti
pow_lt_pow_iff_of_lt_one
→ pow_lt_pow_iff_right_of_lt_one
pow_lt_pow_of_lt_one
→ pow_lt_pow_right_of_lt_one
lt_of_pow_lt_pow
→ lt_of_pow_lt_pow_left
le_of_pow_le_pow
→ le_of_pow_le_pow_left
pow_lt_pow₀
→ pow_lt_pow_right₀
Algebra.GroupPower.CovariantClass
pow_le_pow_of_le_left'
→ pow_le_pow_left'
nsmul_le_nsmul_of_le_right
→ nsmul_le_nsmul_right
pow_lt_pow'
→ pow_lt_pow_right'
nsmul_lt_nsmul
→ nsmul_lt_nsmul_left
pow_strictMono_left
→ pow_right_strictMono'
nsmul_strictMono_right
→ nsmul_left_strictMono
StrictMono.pow_right'
→ StrictMono.pow_const
StrictMono.nsmul_left
→ StrictMono.const_nsmul
pow_strictMono_right'
→ pow_left_strictMono
nsmul_strictMono_left
→ nsmul_right_strictMono
Monotone.pow_right
→ Monotone.pow_const
Monotone.nsmul_left
→ Monotone.const_nsmul
lt_of_pow_lt_pow'
→ lt_of_pow_lt_pow_left'
lt_of_nsmul_lt_nsmul
→ lt_of_nsmul_lt_nsmul_right
pow_le_pow'
→ pow_le_pow_right'
nsmul_le_nsmul
→ nsmul_le_nsmul_left
pow_le_pow_of_le_one'
→ pow_le_pow_right_of_le_one'
nsmul_le_nsmul_of_nonpos
→ nsmul_le_nsmul_left_of_nonpos
le_of_pow_le_pow'
→ le_of_pow_le_pow_left'
le_of_nsmul_le_nsmul'
→ le_of_nsmul_le_nsmul_right'
pow_le_pow_iff'
→ pow_le_pow_iff_right'
nsmul_le_nsmul_iff
→ nsmul_le_nsmul_iff_left
pow_lt_pow_iff'
→ pow_lt_pow_iff_right'
nsmul_lt_nsmul_iff
→ nsmul_lt_nsmul_iff_left
Data.Nat.Pow
Nat.pow_lt_pow_of_lt_left
→ Nat.pow_lt_pow_left
Nat.pow_le_iff_le_left
→ Nat.pow_le_pow_iff_left
Nat.pow_lt_iff_lt_left
→ Nat.pow_lt_pow_iff_left
pow_le_pow_iff_left
pow_lt_pow_iff_left
pow_right_injective
pow_right_inj
Nat.pow_le_pow_left
to have the correct name since Nat.pow_le_pow_of_le_left
is in Std.Nat.pow_le_pow_right
to have the correct name since Nat.pow_le_pow_of_le_right
is in Std.self_le_pow
was a duplicate of le_self_pow
.Nat.pow_lt_pow_of_lt_right
is defeq to pow_lt_pow_right
.Nat.pow_right_strictMono
is defeq to pow_right_strictMono
.Nat.pow_le_iff_le_right
is defeq to pow_le_pow_iff_right
.Nat.pow_lt_iff_lt_right
is defeq to pow_lt_pow_iff_right
.0 < n
or 1 ≤ n
to n ≠ 0
.Nat
lemmas have been protected
.@@ -499,7 +499,7 @@ theorem comp_summable_nnreal (q : FormalMultilinearSeries 𝕜 F G) (p : FormalM
simp only [Finset.prod_mul_distrib, Finset.prod_pow_eq_pow_sum, c.sum_blocksFun]
_ ≤ ∏ _i : Fin c.length, Cp := (Finset.prod_le_prod' fun i _ => hCp _)
_ = Cp ^ c.length := by simp
- _ ≤ Cp ^ n := pow_le_pow hCp1 c.length_le
+ _ ≤ Cp ^ n := pow_le_pow_right hCp1 c.length_le
calc
‖q.compAlongComposition p c‖₊ * r ^ n ≤
(‖q c.length‖₊ * ∏ i, ‖p (c.blocksFun i)‖₊) * r ^ n :=
@@ -842,7 +842,7 @@ theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinea
_ ≤ ‖compAlongComposition q p c‖ * (r : ℝ) ^ n := by
apply mul_le_mul_of_nonneg_left _ (norm_nonneg _)
rw [Finset.prod_const, Finset.card_fin]
- apply pow_le_pow_of_le_left (norm_nonneg _)
+ apply pow_le_pow_left (norm_nonneg _)
rw [EMetric.mem_ball, edist_eq_coe_nnnorm] at hy
have := le_trans (le_of_lt hy) (min_le_right _ _)
rwa [ENNReal.coe_le_coe, ← NNReal.coe_le_coe, coe_nnnorm] at this
This is the supremum of
along with some minor fixes from failures on nightly-testing as Mathlib master
is merged into it.
Note that some PRs for changes that are already compatible with the current toolchain and will be necessary have already been split out: #8380.
I am hopeful that in future we will be able to progressively merge adaptation PRs into a bump/v4.X.0
branch, so we never end up with a "big merge" like this. However one of these adaptation PRs (#8056) predates my new scheme for combined CI, and it wasn't possible to keep that PR viable in the meantime.
In particular this includes adjustments for the Lean PRs
We can get rid of all the
local macro_rules | `($x ^ $y) => `(HPow.hPow $x $y) -- Porting note: See issue [lean4#2220](https://github.com/leanprover/lean4/pull/2220)
macros across Mathlib (and in any projects that want to write natural number powers of reals).
Changes the default behaviour of simp
to (config := {decide := false})
. This makes simp
(and consequentially norm_num
) less powerful, but also more consistent, and less likely to blow up in long failures. This requires a variety of changes: changing some previously by simp
or norm_num
to decide
or rfl
, or adding (config := {decide := true})
.
This changed the behaviour of simp
so that simp [f]
will only unfold "fully applied" occurrences of f
. The old behaviour can be recovered with simp (config := { unfoldPartialApp := true })
. We may in future add a syntax for this, e.g. simp [!f]
; please provide feedback! In the meantime, we have made the following changes:
(config := { unfoldPartialApp := true })
in some places, to recover the old behaviour@[eqns]
to manually adjust the equation lemmas for a particular definition, recovering the old behaviour just for that definition. See #8371, where we do this for Function.comp
and Function.flip
.This change in Lean may require further changes down the line (e.g. adding the !f
syntax, and/or upstreaming the special treatment for Function.comp
and Function.flip
, and/or removing this special treatment). Please keep an open and skeptical mind about these changes!
Co-authored-by: leanprover-community-mathlib4-bot <leanprover-community-mathlib4-bot@users.noreply.github.com> Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Eric Wieser <wieser.eric@gmail.com> Co-authored-by: Mauricio Collares <mauricio@collares.org>
@@ -171,7 +171,7 @@ theorem applyComposition_update (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
theorem compContinuousLinearMap_applyComposition {n : ℕ} (p : FormalMultilinearSeries 𝕜 F G)
(f : E →L[𝕜] F) (c : Composition n) (v : Fin n → E) :
(p.compContinuousLinearMap f).applyComposition c v = p.applyComposition c (f ∘ v) := by
- simp [applyComposition]; rfl
+ simp (config := {unfoldPartialApp := true}) [applyComposition]; rfl
#align formal_multilinear_series.comp_continuous_linear_map_apply_composition FormalMultilinearSeries.compContinuousLinearMap_applyComposition
end FormalMultilinearSeries
@@ -1188,9 +1188,9 @@ theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinear
r c.1.length fun i : Fin c.1.length =>
q (c.2 i).length (applyComposition p (c.2 i) (v ∘ c.1.embedding i))
suffices ∑ c, f c = ∑ c, g c by
- simpa only [FormalMultilinearSeries.comp, ContinuousMultilinearMap.sum_apply,
- compAlongComposition_apply, Finset.sum_sigma', applyComposition,
- ContinuousMultilinearMap.map_sum]
+ simpa (config := { unfoldPartialApp := true }) only [FormalMultilinearSeries.comp,
+ ContinuousMultilinearMap.sum_apply, compAlongComposition_apply, Finset.sum_sigma',
+ applyComposition, ContinuousMultilinearMap.map_sum]
/- Now, we use `Composition.sigmaEquivSigmaPi n` to change
variables in the second sum, and check that we get exactly the same sums. -/
rw [← (sigmaEquivSigmaPi n).sum_comp]
@@ -1045,7 +1045,6 @@ theorem blocksFun_sigmaCompositionAux (a : Composition n) (b : Composition a.len
rw [get_of_eq (get_splitWrtComposition _ _ _), get_drop', get_take']; rfl
#align composition.blocks_fun_sigma_composition_aux Composition.blocksFun_sigmaCompositionAux
-set_option linter.deprecated false in
/-- Auxiliary lemma to prove that the composition of formal multilinear series is associative.
Consider a composition `a` of `n` and a composition `b` of `a.length`. Grouping together some
@@ -1076,7 +1075,7 @@ theorem sizeUpTo_sizeUpTo_add (a : Composition n) (b : Composition a.length) {i
take (sum (take i b.blocks)) (take (sum (take (i + 1) b.blocks)) a.blocks) := by
rw [take_take, min_eq_left]
apply monotone_sum_take _ (Nat.le_succ _)
- rw [this, nthLe_map', nthLe, get_splitWrtComposition, ←
+ rw [this, get_map, get_splitWrtComposition, ←
take_append_drop (sum (take i b.blocks)) (take (sum (take (Nat.succ i) b.blocks)) a.blocks),
sum_append]
congr
@@ -260,7 +260,7 @@ theorem comp_coeff_zero (q : FormalMultilinearSeries 𝕜 F G) (p : FormalMultil
have : {c} = (Finset.univ : Finset (Composition 0)) := by
apply Finset.eq_of_subset_of_card_le <;> simp [Finset.card_univ, composition_card 0]
rw [← this, Finset.sum_singleton, compAlongComposition_apply]
- symm; congr! -- porting note: needed the stronger version of `congr` here
+ symm; congr! -- porting note: needed the stronger `congr!`!
#align formal_multilinear_series.comp_coeff_zero FormalMultilinearSeries.comp_coeff_zero
@[simp]
@@ -596,7 +596,6 @@ theorem compChangeOfVariables_length (m M N : ℕ) {i : Σ n, Fin n → ℕ}
simp only [Composition.length, map_ofFn, length_ofFn]
#align formal_multilinear_series.comp_change_of_variables_length FormalMultilinearSeries.compChangeOfVariables_length
-set_option linter.deprecated false in
theorem compChangeOfVariables_blocksFun (m M N : ℕ) {i : Σ n, Fin n → ℕ}
(hi : i ∈ compPartialSumSource m M N) (j : Fin i.1) :
(compChangeOfVariables m M N i hi).2.blocksFun
@@ -604,7 +603,9 @@ theorem compChangeOfVariables_blocksFun (m M N : ℕ) {i : Σ n, Fin n → ℕ}
i.2 j := by
rcases i with ⟨n, f⟩
dsimp [Composition.blocksFun, Composition.blocks, compChangeOfVariables]
- simp only [map_ofFn, List.nthLe_ofFn, Function.comp_apply]
+ simp only [map_ofFn, List.get_ofFn, Function.comp_apply]
+ -- Porting note: didn't used to need `rfl`
+ rfl
#align formal_multilinear_series.comp_change_of_variables_blocks_fun FormalMultilinearSeries.compChangeOfVariables_blocksFun
/-- Target set in the change of variables to compute the composition of partial sums of formal
@@ -643,7 +644,6 @@ theorem mem_compPartialSumTarget_iff {m M N : ℕ} {a : Σ n, Composition n} :
by simp [compPartialSumTarget, compPartialSumTargetSet]
#align formal_multilinear_series.mem_comp_partial_sum_target_iff FormalMultilinearSeries.mem_compPartialSumTarget_iff
-set_option linter.deprecated false in
/-- `comp_change_of_variables m M N` is a bijection between `comp_partial_sum_source m M N`
and `comp_partial_sum_target m M N`, yielding equal sums for functions that correspond to each
other under the bijection. As `comp_change_of_variables m M N` is a dependent function, stating
@@ -664,13 +664,7 @@ theorem compChangeOfVariables_sum {α : Type*} [AddCommMonoid α] (m M N : ℕ)
simp only [mem_compPartialSumTarget_iff, Composition.length, Composition.blocks, H.left,
map_ofFn, length_ofFn, true_and_iff, compChangeOfVariables]
intro j
- -- Porting note: the following `simp` was sufficient in lean 3.
- simp only [Composition.blocksFun, (H.right _).right, List.nthLe_ofFn]
- convert (H.right ⟨j, ?_⟩).right
- · convert List.nthLe_ofFn _ _ using 2
- rfl
- · apply j.prop.trans_eq
- simp [Composition.length]
+ simp only [Composition.blocksFun, (H.right _).right, List.get_ofFn]
-- 2 - show that the composition gives the `comp_along_composition` application
· rintro ⟨k, blocks_fun⟩ H
rw [h]
@@ -1017,8 +1011,6 @@ theorem length_gather (a : Composition n) (b : Composition a.length) :
rw [length_map, length_splitWrtComposition]
#align composition.length_gather Composition.length_gather
--- porting note: this needs `Composition.blocksFun` to be refactored in order to remove `nthLe`
-set_option linter.deprecated false in
/-- An auxiliary function used in the definition of `sigmaEquivSigmaPi` below, associating to
two compositions `a` of `n` and `b` of `a.length`, and an index `i` bounded by the length of
`a.gather b`, the subcomposition of `a` made of those blocks belonging to the `i`-th block of
@@ -1033,28 +1025,24 @@ def sigmaCompositionAux (a : Composition n) (b : Composition a.length)
(by
rw [← a.blocks.join_splitWrtComposition b]
exact mem_join_of_mem (List.get_mem _ _ _) hi)
- blocks_sum := by simp only [Composition.blocksFun, nthLe_map', Composition.gather]; rfl
+ blocks_sum := by simp only [Composition.blocksFun, get_map, Composition.gather]
#align composition.sigma_composition_aux Composition.sigmaCompositionAux
--- porting note: this needs `Composition.blocksFun` to be refactored in order to remove `nthLe`
-set_option linter.deprecated false in
theorem length_sigmaCompositionAux (a : Composition n) (b : Composition a.length)
(i : Fin b.length) :
Composition.length (Composition.sigmaCompositionAux a b ⟨i, (length_gather a b).symm ▸ i.2⟩) =
Composition.blocksFun b i :=
- show List.length (nthLe (splitWrtComposition a.blocks b) i _) = blocksFun b i by
- rw [nthLe_map_rev List.length, nthLe_of_eq (map_length_splitWrtComposition _ _)]; rfl
+ show List.length ((splitWrtComposition a.blocks b).get ⟨i, _⟩) = blocksFun b i by
+ rw [get_map_rev List.length, get_of_eq (map_length_splitWrtComposition _ _)]; rfl
#align composition.length_sigma_composition_aux Composition.length_sigmaCompositionAux
--- porting note: this needs `Composition.blocksFun` to be refactored in order to remove `nthLe`
-set_option linter.deprecated false in
theorem blocksFun_sigmaCompositionAux (a : Composition n) (b : Composition a.length)
(i : Fin b.length) (j : Fin (blocksFun b i)) :
blocksFun (sigmaCompositionAux a b ⟨i, (length_gather a b).symm ▸ i.2⟩)
⟨j, (length_sigmaCompositionAux a b i).symm ▸ j.2⟩ =
blocksFun a (embedding b i j) :=
- show nthLe (nthLe _ _ _) _ _ = nthLe a.blocks _ _ by
- rw [nthLe_of_eq (nthLe_splitWrtComposition _ _ _), nthLe_drop', nthLe_take']; rfl
+ show get (get _ ⟨_, _⟩) ⟨_, _⟩ = a.blocks.get ⟨_, _⟩ by
+ rw [get_of_eq (get_splitWrtComposition _ _ _), get_drop', get_take']; rfl
#align composition.blocks_fun_sigma_composition_aux Composition.blocksFun_sigmaCompositionAux
set_option linter.deprecated false in
@@ -1088,7 +1076,7 @@ theorem sizeUpTo_sizeUpTo_add (a : Composition n) (b : Composition a.length) {i
take (sum (take i b.blocks)) (take (sum (take (i + 1) b.blocks)) a.blocks) := by
rw [take_take, min_eq_left]
apply monotone_sum_take _ (Nat.le_succ _)
- rw [this, nthLe_map', nthLe_splitWrtComposition, ←
+ rw [this, nthLe_map', nthLe, get_splitWrtComposition, ←
take_append_drop (sum (take i b.blocks)) (take (sum (take (Nat.succ i) b.blocks)) a.blocks),
sum_append]
congr
@@ -1104,8 +1092,7 @@ theorem sizeUpTo_sizeUpTo_add (a : Composition n) (b : Composition a.length) {i
have : sizeUpTo b i + Nat.succ j = (sizeUpTo b i + j).succ := rfl
rw [this, sizeUpTo_succ _ D, IHj A, sizeUpTo_succ _ B]
simp only [sigmaCompositionAux, add_assoc, add_left_inj, Fin.val_mk]
- simp_rw [← nthLe_eq]
- rw [nthLe_of_eq (nthLe_splitWrtComposition _ _ _), nthLe_drop', nthLe_take _ _ C]
+ rw [get_of_eq (get_splitWrtComposition _ _ _), get_drop', get_take _ _ C]
#align composition.size_up_to_size_up_to_add Composition.sizeUpTo_sizeUpTo_add
/-- Natural equivalence between `(Σ (a : composition n), composition a.length)` and
And fix some names in comments where this revealed issues
@@ -42,7 +42,7 @@ summability of the norms, this implies the overall convergence.
* `has_fpower_series_at.comp` states that if two functions `g` and `f` admit power series expansions
`q` and `p`, then `g ∘ f` admits a power series expansion given by `q.comp p`.
* `analytic_at.comp` states that the composition of analytic functions is analytic.
-* `formal_multilinear_series.comp_assoc` states that composition is associative on formal
+* `FormalMultilinearSeries.comp_assoc` states that composition is associative on formal
multilinear series.
## Implementation details
@@ -936,11 +936,11 @@ made of two blocks of length `4` and `9`, i.e., `c = [4, 9]`. But one can also r
the new first block was initially made of two blocks of size `2`, so `d₀ = [2, 2]`, and the new
second block was initially made of three blocks of size `3`, `4` and `2`, so `d₁ = [3, 4, 2]`.
-This equivalence is called `composition.sigma_equiv_sigma_pi n` below.
+This equivalence is called `Composition.sigma_equiv_sigma_pi n` below.
We start with preliminary results on compositions, of a very specialized nature, then define the
-equivalence `composition.sigma_equiv_sigma_pi n`, and we deduce finally the associativity of
-composition of formal multilinear series in `formal_multilinear_series.comp_assoc`.
+equivalence `Composition.sigmaEquivSigmaPi n`, and we deduce finally the associativity of
+composition of formal multilinear series in `FormalMultilinearSeries.comp_assoc`.
-/
@@ -1019,7 +1019,7 @@ theorem length_gather (a : Composition n) (b : Composition a.length) :
-- porting note: this needs `Composition.blocksFun` to be refactored in order to remove `nthLe`
set_option linter.deprecated false in
-/-- An auxiliary function used in the definition of `sigma_equiv_sigma_pi` below, associating to
+/-- An auxiliary function used in the definition of `sigmaEquivSigmaPi` below, associating to
two compositions `a` of `n` and `b` of `a.length`, and an index `i` bounded by the length of
`a.gather b`, the subcomposition of `a` made of those blocks belonging to the `i`-th block of
`a.gather b`. -/
@@ -1205,7 +1205,7 @@ theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinear
simpa only [FormalMultilinearSeries.comp, ContinuousMultilinearMap.sum_apply,
compAlongComposition_apply, Finset.sum_sigma', applyComposition,
ContinuousMultilinearMap.map_sum]
- /- Now, we use `composition.sigma_equiv_sigma_pi n` to change
+ /- Now, we use `Composition.sigmaEquivSigmaPi n` to change
variables in the second sum, and check that we get exactly the same sums. -/
rw [← (sigmaEquivSigmaPi n).sum_comp]
/- To check that we have the same terms, we should check that we apply the same component of
@@ -1216,7 +1216,7 @@ theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinear
apply Finset.sum_congr rfl
rintro ⟨a, b⟩ _
dsimp [sigmaEquivSigmaPi]
- -- check that the `r` components are the same. Based on `composition.length_gather`
+ -- check that the `r` components are the same. Based on `Composition.length_gather`
apply r.congr (Composition.length_gather a b).symm
intro i hi1 hi2
-- check that the `q` components are the same. Based on `length_sigma_composition_aux`
@@ -878,6 +878,16 @@ theorem AnalyticAt.comp {g : F → G} {f : E → F} {x : E} (hg : AnalyticAt
(hq.comp hp).analyticAt
#align analytic_at.comp AnalyticAt.comp
+/-- If two functions `g` and `f` are analytic respectively on `s.image f` and `s`, then `g ∘ f` is
+analytic on `s`. -/
+theorem AnalyticOn.comp' {s : Set E} {g : F → G} {f : E → F} (hg : AnalyticOn 𝕜 g (s.image f))
+ (hf : AnalyticOn 𝕜 f s) : AnalyticOn 𝕜 (g ∘ f) s :=
+ fun z hz => (hg (f z) (Set.mem_image_of_mem f hz)).comp (hf z hz)
+
+theorem AnalyticOn.comp {s : Set E} {t : Set F} {g : F → G} {f : E → F} (hg : AnalyticOn 𝕜 g t)
+ (hf : AnalyticOn 𝕜 f s) (st : Set.MapsTo f s t) : AnalyticOn 𝕜 (g ∘ f) s :=
+ comp' (mono hg (Set.mapsTo'.mp st)) hf
+
/-!
### Associativity of the composition of formal multilinear series
@@ -743,7 +743,7 @@ end FormalMultilinearSeries
open FormalMultilinearSeries
-set_option maxHeartbeats 450000 in
+set_option maxHeartbeats 300000 in
/-- If two functions `g` and `f` have power series `q` and `p` respectively at `f x` and `x`, then
`g ∘ f` admits the power series `q.comp p` at `x`. -/
theorem HasFPowerSeriesAt.comp {g : F → G} {f : E → F} {q : FormalMultilinearSeries 𝕜 F G}
@@ -972,7 +972,6 @@ theorem sigma_pi_composition_eq_iff
ofFn fun i : Fin (Composition.length a') => (b' i).blocks.sum at this
simpa [Composition.blocks_sum, Composition.ofFn_blocksFun] using this
induction h
- simp only [true_and_iff, eq_self_iff_true, heq_iff_eq]
ext1
· rfl
· simp only [heq_eq_eq, ofFn_inj] at H ⊢
@@ -1170,8 +1169,7 @@ def sigmaEquivSigmaPi (n : ℕ) :
rw [get_of_eq (splitWrtComposition_join _ _ _)]
· simp only [get_ofFn]
rfl
- · simp only [map_ofFn]
- congr
+ · congr
· simp only [map_ofFn]
rfl
#align composition.sigma_equiv_sigma_pi Composition.sigmaEquivSigmaPi
Type _
and Sort _
(#6499)
We remove all possible occurences of Type _
and Sort _
in favor of Type*
and Sort*
.
This has nice performance benefits.
@@ -68,7 +68,7 @@ in more details below in the paragraph on associativity.
noncomputable section
-variable {𝕜 : Type _} {E F G H : Type _}
+variable {𝕜 : Type*} {E F G H : Type*}
open Filter List
@@ -649,7 +649,7 @@ and `comp_partial_sum_target m M N`, yielding equal sums for functions that corr
other under the bijection. As `comp_change_of_variables m M N` is a dependent function, stating
that it is a bijection is not directly possible, but the consequence on sums can be stated
more easily. -/
-theorem compChangeOfVariables_sum {α : Type _} [AddCommMonoid α] (m M N : ℕ)
+theorem compChangeOfVariables_sum {α : Type*} [AddCommMonoid α] (m M N : ℕ)
(f : (Σ n : ℕ, Fin n → ℕ) → α) (g : (Σ n, Composition n) → α)
(h : ∀ (e) (he : e ∈ compPartialSumSource m M N), f e = g (compChangeOfVariables m M N e he)) :
∑ e in compPartialSumSource m M N, f e = ∑ e in compPartialSumTarget m M N, g e := by
@@ -2,15 +2,12 @@
Copyright (c) 2020 Sébastien Gouëzel. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Johan Commelin
-
-! This file was ported from Lean 3 source module analysis.analytic.composition
-! leanprover-community/mathlib commit ce11c3c2a285bbe6937e26d9792fda4e51f3fe1a
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathlib.Analysis.Analytic.Basic
import Mathlib.Combinatorics.Composition
+#align_import analysis.analytic.composition from "leanprover-community/mathlib"@"ce11c3c2a285bbe6937e26d9792fda4e51f3fe1a"
+
/-!
# Composition of analytic functions
Co-authored-by: Komyyy <pol_tta@outlook.jp> Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Scott Morrison <scott.morrison@anu.edu.au> Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com> Co-authored-by: Mario Carneiro <di.gama@gmail.com>
@@ -707,7 +707,7 @@ theorem compPartialSumTarget_tendsto_atTop :
aesop
· rintro ⟨n, c⟩
simp only [mem_compPartialSumTarget_iff]
- obtain ⟨n, hn⟩ : BddAbove ↑(Finset.univ.image fun i : Fin c.length => c.blocksFun i) :=
+ obtain ⟨n, hn⟩ : BddAbove ((Finset.univ.image fun i : Fin c.length => c.blocksFun i) : Set ℕ) :=
Finset.bddAbove _
refine'
⟨max n c.length + 1, bot_le, lt_of_le_of_lt (le_max_right n c.length) (lt_add_one _), fun j =>
This is the second half of the changes originally in #5699, removing all occurrences of ;
after a space and implementing a linter rule to enforce it.
In most cases this 2-character substring has a space after it, so the following command was run first:
find . -type f -name "*.lean" -exec sed -i -E 's/ ; /; /g' {} \;
The remaining cases were few enough in number that they were done manually.
@@ -350,7 +350,7 @@ theorem compAlongComposition_norm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F
theorem compAlongComposition_nnnorm {n : ℕ} (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) (c : Composition n) :
‖q.compAlongComposition p c‖₊ ≤ ‖q c.length‖₊ * ∏ i, ‖p (c.blocksFun i)‖₊ := by
- rw [← NNReal.coe_le_coe]; push_cast ; exact q.compAlongComposition_norm p c
+ rw [← NNReal.coe_le_coe]; push_cast; exact q.compAlongComposition_norm p c
#align formal_multilinear_series.comp_along_composition_nnnorm FormalMultilinearSeries.compAlongComposition_nnnorm
/-!
@@ -1131,10 +1131,6 @@ def sigmaEquivSigmaPi (n : ℕ) :
intro k hk
refine' ((forall_mem_ofFn_iff (P := fun i => 0 < i)).2 fun j => _) k hk
exact Composition.length_pos_of_pos _ (Composition.blocks_pos' _ _ _)
- --sorry
- --(forall_mem_ofFn_iff (P := fun i => 0 < i)).2 fun j => by
- -- sorry
- --Composition.length_pos_of_pos _ (Composition.blocks_pos' _ _ _)
blocks_sum := by dsimp only [Composition.length]; simp [sum_ofFn] }⟩
left_inv := by
-- the fact that we have a left inverse is essentially `join_split_wrt_composition`,
@@ -1146,7 +1142,6 @@ def sigmaEquivSigmaPi (n : ℕ) :
· conv_rhs =>
rw [← join_splitWrtComposition a.blocks b, ← ofFn_get (splitWrtComposition a.blocks b)]
have A : length (gather a b) = List.length (splitWrtComposition a.blocks b) := by
- -- length_map (List.sum (α := List ℕ)) (splitWrtComposition a.blocks b)
simp only [length, gather, length_map, length_splitWrtComposition]
congr! 2
· exact (Fin.heq_fun_iff A (α := List ℕ)).2 fun i => rfl
@@ -1173,15 +1168,15 @@ def sigmaEquivSigmaPi (n : ℕ) :
simp only [map_ofFn]
rfl
· rw [Fin.heq_fun_iff]
- · intro i
- dsimp [Composition.sigmaCompositionAux]
- rw [get_of_eq (splitWrtComposition_join _ _ _)]
- · simp only [get_ofFn]
- rfl
- · simp only [map_ofFn]
- congr
- · simp only [map_ofFn]
- rfl
+ intro i
+ dsimp [Composition.sigmaCompositionAux]
+ rw [get_of_eq (splitWrtComposition_join _ _ _)]
+ · simp only [get_ofFn]
+ rfl
+ · simp only [map_ofFn]
+ congr
+ · simp only [map_ofFn]
+ rfl
#align composition.sigma_equiv_sigma_pi Composition.sigmaEquivSigmaPi
end Composition
ext
(#5258)
Co-authored-by: Xavier Roblot <46200072+xroblot@users.noreply.github.com> Co-authored-by: Joël Riou <joel.riou@universite-paris-saclay.fr> Co-authored-by: Riccardo Brasca <riccardo.brasca@gmail.com> Co-authored-by: Yury G. Kudryashov <urkud@urkud.name> Co-authored-by: Scott Morrison <scott.morrison@anu.edu.au> Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Jeremy Tan Jie Rui <reddeloostw@gmail.com> Co-authored-by: Pol'tta / Miyahara Kō <pol_tta@outlook.jp> Co-authored-by: Jason Yuen <jason_yuen2007@hotmail.com> Co-authored-by: Mario Carneiro <di.gama@gmail.com> Co-authored-by: Jireh Loreaux <loreaujy@gmail.com> Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com> Co-authored-by: Kyle Miller <kmill31415@gmail.com> Co-authored-by: Heather Macbeth <25316162+hrmacbeth@users.noreply.github.com> Co-authored-by: Jujian Zhang <jujian.zhang1998@outlook.com> Co-authored-by: Yaël Dillies <yael.dillies@gmail.com>
@@ -137,7 +137,7 @@ theorem applyComposition_single (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
@[simp]
theorem removeZero_applyComposition (p : FormalMultilinearSeries 𝕜 E F) {n : ℕ}
(c : Composition n) : p.removeZero.applyComposition c = p.applyComposition c := by
- ext (v i)
+ ext v i
simp [applyComposition, zero_lt_one.trans_le (c.one_le_blocksFun i), removeZero_of_pos]
#align formal_multilinear_series.remove_zero_apply_composition FormalMultilinearSeries.removeZero_applyComposition
@@ -1193,7 +1193,7 @@ open Composition
set_option maxHeartbeats 500000 in
theorem comp_assoc (r : FormalMultilinearSeries 𝕜 G H) (q : FormalMultilinearSeries 𝕜 F G)
(p : FormalMultilinearSeries 𝕜 E F) : (r.comp q).comp p = r.comp (q.comp p) := by
- ext (n v)
+ ext n v
/- First, rewrite the two compositions appearing in the theorem as two sums over complicated
sigma types, as in the description of the proof above. -/
let f : (Σ a : Composition n, Composition a.length) → H := fun c =>
Co-authored-by: Ruben Van de Velde <65514131+Ruben-VandeVelde@users.noreply.github.com> Co-authored-by: Scott Morrison <scott.morrison@anu.edu.au> Co-authored-by: Johan Commelin <johan@commelin.net> Co-authored-by: Mauricio Collares <mauricio@collares.org>
The unported dependencies are
algebra.order.module
init.core
algebra.order.monoid.cancel.defs
algebra.abs
algebra.group_power.lemmas
init.data.list.basic
algebra.order.monoid.cancel.basic
init.data.list.default
topology.subset_properties
init.logic
The following 1 dependencies have changed in mathlib3 since they were ported, which may complicate porting this file