Skip to content
This repository was archived by the owner on Jul 24, 2024. It is now read-only.

Commit 117e729

Browse files
eric-wiesersgouezel
andcommitted
chore(linear_algebra/basic, analysis/normed_space/operator_norm): bundle another argument into the homs (#5899)
Co-authored-by: sgouezel <sebastien.gouezel@univ-rennes1.fr>
1 parent 7f11d72 commit 117e729

File tree

2 files changed

+30
-25
lines changed

2 files changed

+30
-25
lines changed

src/analysis/normed_space/operator_norm.lean

Lines changed: 13 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -683,23 +683,19 @@ continuous_linear_map.homothety_norm _ c.norm_smul_right_apply
683683

684684
variables (𝕜 F)
685685

686-
/-- The linear map obtained by applying a continuous linear map at a given vector. -/
687-
def applyₗ (v : E) : (E →L[𝕜] F) →ₗ[𝕜] F :=
688-
{ to_fun := λ f, f v,
689-
map_add' := λ f g, f.add_apply g v,
690-
map_smul' := λ x f, f.smul_apply x v }
691-
692-
lemma continuous_applyₗ (v : E) : continuous (continuous_linear_map.applyₗ 𝕜 F v) :=
693-
begin
694-
apply (continuous_linear_map.applyₗ 𝕜 F v).continuous_of_bound,
695-
intro f,
696-
rw mul_comm,
697-
exact f.le_op_norm v,
698-
end
699-
700-
/-- The continuous linear map obtained by applying a continuous linear map at a given vector. -/
701-
def apply (v : E) : (E →L[𝕜] F) →L[𝕜] F :=
702-
⟨continuous_linear_map.applyₗ 𝕜 F v, continuous_linear_map.continuous_applyₗ _ _ _⟩
686+
/-- The continuous linear map obtained by applying a continuous linear map at a given vector.
687+
688+
This is the continuous version of `linear_map.applyₗ`. -/
689+
def apply : E →L[𝕜] (E →L[𝕜] F) →L[𝕜] F :=
690+
linear_map.mk_continuous
691+
{ to_fun := λ v, linear_map.mk_continuous
692+
{ to_fun := λ f, f v,
693+
map_add' := λ f g, f.add_apply g v,
694+
map_smul' := λ x f, f.smul_apply x v }
695+
∥v∥ (λ f, by simpa [mul_comm] using f.le_op_norm v),
696+
map_add' := λ _ _, ext $ λ f, f.map_add _ _,
697+
map_smul' := λ _ _, ext $ λ f, f.map_smul _ _, }
698+
1 $ λ x, op_norm_le_bound _ (by simp) (λ f, by simpa [mul_comm] using f.le_op_norm x)
703699

704700
variables {𝕜 F}
705701

src/linear_algebra/basic.lean

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -330,11 +330,15 @@ variable (S)
330330

331331
/-- Applying a linear map at `v : M`, seen as `S`-linear map from `M →ₗ[R] M₂` to `M₂`.
332332
333-
See `applyₗ` for a version where `S = R` -/
334-
def applyₗ' (v : M) : (M →ₗ[R] M₂) →ₗ[S] M₂ :=
335-
{ to_fun := λ f, f v,
336-
map_add' := λ f g, f.add_apply g v,
337-
map_smul' := λ x f, f.smul_apply x v }
333+
See `linear_map.applyₗ` for a version where `S = R`. -/
334+
@[simps]
335+
def applyₗ' : M →+ (M →ₗ[R] M₂) →ₗ[S] M₂ :=
336+
{ to_fun := λ v,
337+
{ to_fun := λ f, f v,
338+
map_add' := λ f g, f.add_apply g v,
339+
map_smul' := λ x f, f.smul_apply x v },
340+
map_zero' := linear_map.ext $ λ f, f.map_zero,
341+
map_add' := λ x y, linear_map.ext $ λ f, f.map_add _ _ }
338342

339343
end semimodule
340344

@@ -479,9 +483,14 @@ def comp_right (f : M₂ →ₗ[R] M₃) : (M →ₗ[R] M₂) →ₗ[R] (M →
479483
λ _ _, linear_map.ext $ λ _, f.3 _ _⟩
480484

481485
/-- Applying a linear map at `v : M`, seen as a linear map from `M →ₗ[R] M₂` to `M₂`.
482-
See also `linear_map.applyₗ'` for a version that works with two different semirings. -/
483-
def applyₗ (v : M) : (M →ₗ[R] M₂) →ₗ[R] M₂ :=
484-
applyₗ' R v
486+
See also `linear_map.applyₗ'` for a version that works with two different semirings.
487+
488+
This is the `linear_map` version of `add_monoid_hom.eval`. -/
489+
@[simps]
490+
def applyₗ : M →ₗ[R] (M →ₗ[R] M₂) →ₗ[R] M₂ :=
491+
{ to_fun := λ v, { to_fun := λ f, f v, ..applyₗ' R v },
492+
map_smul' := λ x y, linear_map.ext $ λ f, f.map_smul _ _,
493+
..applyₗ' R }
485494

486495
end comm_semiring
487496

0 commit comments

Comments
 (0)