Skip to content

[Merged by Bors] - feat(Analysis/LocallyConvex/WeakDual): characterise the span of some functionals with continuity#27316

Closed
mans0954 wants to merge 28 commits intoleanprover-community:masterfrom
mans0954:mans0954/functional_mem_span_iff
Closed

[Merged by Bors] - feat(Analysis/LocallyConvex/WeakDual): characterise the span of some functionals with continuity#27316
mans0954 wants to merge 28 commits intoleanprover-community:masterfrom
mans0954:mans0954/functional_mem_span_iff

Conversation

@mans0954
Copy link
Copy Markdown
Collaborator

@mans0954 mans0954 commented Jul 20, 2025

Sufficient and necessary conditions for a linear functional to be in the span of a finite set of linear functionals.

This result is Rudin, Functional Analysis, Second edition, Lemma 3.9 (see also Bourbaki TVS, II.6 Proposition 5).

A key application of this result is the proof that WeakBilin.eval B is surjective i.e. the dual of E with the weak topology is identified with F.


Open in Gitpod

@github-actions github-actions bot added large-import Automatically added label for PRs with a significant increase in transitive imports t-analysis Analysis (normed *, calculus) labels Jul 20, 2025
@github-actions
Copy link
Copy Markdown

github-actions bot commented Jul 20, 2025

PR summary a79ea2e63e

Import changes exceeding 2%

% File
+17.27% Mathlib.Analysis.LocallyConvex.WeakDual

Import changes for modified files

Dependency changes

File Base Count Head Count Change
Mathlib.Analysis.LocallyConvex.WeakDual 1523 1786 +263 (+17.27%)
Import changes for all files
Files Import difference
Mathlib.Analysis.LocallyConvex.WeakDual 263

Declarations diff

+ continuous_iff
+ mem_span_iff_bound
+ mem_span_iff_continuous
+ mem_span_iff_continuous_of_finite

You can run this locally as follows
## summary with just the declaration names:
./scripts/declarations_diff.sh <optional_commit>

## more verbose report:
./scripts/declarations_diff.sh long <optional_commit>

The doc-module for script/declarations_diff.sh contains some details about this script.


No changes to technical debt.

You can run this locally as

./scripts/technical-debt-metrics.sh pr_summary
  • The relative value is the weighted sum of the differences with weight given by the inverse of the current value of the statistic.
  • The absolute value is the relative value divided by the total sum of the inverses of the current values (i.e. the weighted average of the differences).

@ADedecker ADedecker added the awaiting-author A reviewer has asked the author a question or requested changes. label Jul 25, 2025
@mans0954 mans0954 removed the awaiting-author A reviewer has asked the author a question or requested changes. label Jul 28, 2025
@ADedecker
Copy link
Copy Markdown
Member

Here is what I had in mind:

variable {ι 𝕜 E F : Type*}

open Topology TopologicalSpace
open scoped NNReal

section

section TopologicalRing

variable [Finite ι] [Field 𝕜] [t𝕜 : TopologicalSpace 𝕜] [IsTopologicalRing 𝕜]
  [AddCommGroup E] [Module 𝕜 E] [T0Space 𝕜]

theorem LinearMap.mem_span_iff_continuous_of_finite {f : ι → E →ₗ[𝕜] 𝕜} (φ : E →ₗ[𝕜] 𝕜) :
    φ ∈ Submodule.span 𝕜 (Set.range f) ↔
    Continuous[⨅ i, induced (f i) t𝕜, t𝕜] φ := by
  let _ := ⨅ i, induced (f i) t𝕜
  constructor
  · exact Submodule.span_induction
      (Set.forall_mem_range.mpr fun i ↦ continuous_iInf_dom continuous_induced_dom) continuous_zero
      (fun _ _ _ _ ↦ .add) (fun c _ _ h ↦ h.const_smul c)
  · intro φ_cont
    refine mem_span_of_iInf_ker_le_ker fun x hx ↦ ?_
    simp_rw [Submodule.mem_iInf, LinearMap.mem_ker] at hx ⊢
    have : Inseparable x 0 := by
      -- Maybe missing lemmas about `Inseparable`?
      simp_rw [Inseparable, nhds_iInf, nhds_induced, hx, map_zero]
    simpa only [map_zero] using (this.map φ_cont).eq

end TopologicalRing

section NontriviallyNormedField

variable [NontriviallyNormedField 𝕜] [AddCommGroup E] [Module 𝕜 E]

theorem LinearMap.mem_span_iff_continuous {f : ι → E →ₗ[𝕜] 𝕜} (φ : E →ₗ[𝕜] 𝕜) :
    φ ∈ Submodule.span 𝕜 (Set.range f) ↔
    Continuous[⨅ i, induced (f i) inferInstance, inferInstance] φ := by
  letI t𝕜 : TopologicalSpace 𝕜 := inferInstance
  let t := ⨅ i, induced (f i) t𝕜
  constructor
  -- TODO: is it worth factoring the first implication with `mem_span_iff_continuous_of_finite`?
  · exact Submodule.span_induction
      (Set.forall_mem_range.mpr fun i ↦ continuous_iInf_dom continuous_induced_dom) continuous_zero
      (fun _ _ _ _ ↦ .add) (fun c _ _ h ↦ h.const_smul c)
  · intro φ_cont
    obtain ⟨s, hs⟩ : ∃ s : Finset ι, Continuous[⨅ i : s, induced (f i) t𝕜, t𝕜] φ := by
      -- The following should be golfable by using/developping better API
      have : φ ⁻¹' (Metric.ball 0 1) ∈ 𝓝 0 :=
        φ_cont.continuousAt.tendsto (map_zero φ ▸ Metric.ball_mem_nhds (0 : 𝕜) one_pos)
      rw [nhds_iInf, Filter.mem_iInf_finite] at this
      rcases this with ⟨s, hs⟩
      use s
      let t' := ⨅ i : s, induced (f i) t𝕜
      have : IsTopologicalAddGroup E :=
        topologicalAddGroup_iInf fun _ ↦ topologicalAddGroup_induced _
      have : ContinuousSMul 𝕜 E :=
        continuousSMul_iInf fun _ ↦ continuousSMul_induced _
      rw [Seminorm.continuous_iff_continuous_comp (norm_withSeminorms 𝕜 𝕜), forall_const]
      refine Seminorm.continuous (r := 1) ?_
      rwa [nhds_iInf, Seminorm.ball_comp, ball_normSeminorm, iInf_subtype, map_zero]
    rw [← LinearMap.mem_span_iff_continuous_of_finite] at hs
    exact Submodule.span_mono (Set.range_comp_subset_range _ _) hs

theorem LinearMap.mem_span_iff_bound [Nonempty ι] {f : ι → E →ₗ[𝕜] 𝕜} (φ : E →ₗ[𝕜] 𝕜) :
    φ ∈ Submodule.span 𝕜 (Set.range f) ↔
    ∃ s : Finset ι, ∃ c : ℝ≥0, (normSeminorm 𝕜 𝕜).comp φ ≤
      c • (s.sup fun i ↦ (normSeminorm 𝕜 𝕜).comp (f i)) := by
  letI t𝕜 : TopologicalSpace 𝕜 := inferInstance
  let t := ⨅ i, induced (f i) t𝕜
  have : IsTopologicalAddGroup E := topologicalAddGroup_iInf fun _ ↦ topologicalAddGroup_induced _
  have : WithSeminorms (fun i ↦ (normSeminorm 𝕜 𝕜).comp (f i)) := by
    simp_rw [SeminormFamily.withSeminorms_iff_nhds_eq_iInf, nhds_iInf, nhds_induced, map_zero,
      ← comap_norm_nhds_zero (E := 𝕜), Filter.comap_comap]
    rfl
  rw [LinearMap.mem_span_iff_continuous]
  constructor <;> intro H
  · rw [Seminorm.continuous_iff_continuous_comp (norm_withSeminorms 𝕜 𝕜), forall_const] at H
    rcases Seminorm.bound_of_continuous this _ H with ⟨s, C, -, hC⟩
    exact ⟨s, C, hC⟩
  · exact Seminorm.cont_withSeminorms_normedSpace _ this _ H

end NontriviallyNormedField

end

As you can see, this is not completely satisfying: while the core argument is (imho) much nicer, there is a lot of boilerplate due to lack of API around seminorms and the associated topologies...

I'm pretty convinced that this is the right way to go, as it should just be assembling a few blocks to get the final result, but unfortunately it seems a bit more complicated with the current API... I will try to think about it, but, as a middle ground, could you at least include my first lemma and add a TODO explaining that your result should be deduced from it at some point?

@mans0954
Copy link
Copy Markdown
Collaborator Author

I'm pretty convinced that this is the right way to go, as it should just be assembling a few blocks to get the final result, but unfortunately it seems a bit more complicated with the current API... I will try to think about it, but, as a middle ground, could you at least include my first lemma and add a TODO explaining that your result should be deduced from it at some point?

I'm able to use this to prove the Bipolar theorem (#26345) so it's fine with me.

variable [Finite ι] [Field 𝕜] [t𝕜 : TopologicalSpace 𝕜] [IsTopologicalRing 𝕜]
[AddCommGroup E] [Module 𝕜 E] [T0Space 𝕜]

theorem mem_span_iff_continuous_of_finite {f : ι → E →ₗ[𝕜] 𝕜} (φ : E →ₗ[𝕜] 𝕜) :
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this lemma and the next one deserve a small docstring, ideally cross-referencing each other. Also, I would suggest moving this one lower (e.g in Mathlib.Topology.Algebra.Module.LinearMap), but I'm not sure how heavy the import load will get...

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Importing Mathlib.LinearAlgebra.Dual.Lemmas into Mathlib.Topology.Algebra.Module.LinearMap triggers the assert_not_exists Star.star in that file.

@YaelDillies YaelDillies added the awaiting-author A reviewer has asked the author a question or requested changes. label Aug 15, 2025
@YaelDillies YaelDillies changed the title feature(Analysis/LocallyConvex/WeakDual): functional_mem_span_iff feat(Analysis/LocallyConvex/WeakDual): functional_mem_span_iff Aug 15, 2025
@mans0954 mans0954 removed the awaiting-author A reviewer has asked the author a question or requested changes. label Aug 15, 2025
@YaelDillies YaelDillies changed the title feat(Analysis/LocallyConvex/WeakDual): functional_mem_span_iff feat(Analysis/LocallyConvex/WeakDual): characterise the span of some functionals with continuity Aug 15, 2025
Copy link
Copy Markdown
Contributor

@YaelDillies YaelDillies left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

maintainer delegate

@github-actions
Copy link
Copy Markdown

🚀 Pull request has been placed on the maintainer queue by YaelDillies.

@ghost ghost added the maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. label Aug 15, 2025
Copy link
Copy Markdown
Contributor

@bryangingechen bryangingechen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!
bors d+

@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Aug 19, 2025

✌️ mans0954 can now approve this pull request. To approve and merge a pull request, simply reply with bors r+. More detailed instructions are available here.

@ghost ghost added delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). and removed maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. labels Aug 19, 2025
@mans0954
Copy link
Copy Markdown
Collaborator Author

bors r+

mathlib-bors bot pushed a commit that referenced this pull request Aug 19, 2025
…functionals with continuity (#27316)

Sufficient and necessary conditions for a linear functional to be in the span of a finite set of linear functionals.

This result is Rudin, Functional Analysis, Second edition, Lemma 3.9 (see also Bourbaki TVS, II.6 Proposition 5).

A key application of this result is the proof that `WeakBilin.eval B` is surjective i.e. the dual of `E` with the weak topology is identified with `F`.



Co-authored-by: Christopher Hoskin <[email protected]>
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Aug 19, 2025

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title feat(Analysis/LocallyConvex/WeakDual): characterise the span of some functionals with continuity [Merged by Bors] - feat(Analysis/LocallyConvex/WeakDual): characterise the span of some functionals with continuity Aug 19, 2025
@mathlib-bors mathlib-bors bot closed this Aug 19, 2025
pfaffelh pushed a commit to pfaffelh/mathlib4 that referenced this pull request Aug 20, 2025
…functionals with continuity (leanprover-community#27316)

Sufficient and necessary conditions for a linear functional to be in the span of a finite set of linear functionals.

This result is Rudin, Functional Analysis, Second edition, Lemma 3.9 (see also Bourbaki TVS, II.6 Proposition 5).

A key application of this result is the proof that `WeakBilin.eval B` is surjective i.e. the dual of `E` with the weak topology is identified with `F`.



Co-authored-by: Christopher Hoskin <[email protected]>
Paul-Lez pushed a commit to Paul-Lez/mathlib4 that referenced this pull request Aug 23, 2025
…functionals with continuity (leanprover-community#27316)

Sufficient and necessary conditions for a linear functional to be in the span of a finite set of linear functionals.

This result is Rudin, Functional Analysis, Second edition, Lemma 3.9 (see also Bourbaki TVS, II.6 Proposition 5).

A key application of this result is the proof that `WeakBilin.eval B` is surjective i.e. the dual of `E` with the weak topology is identified with `F`.



Co-authored-by: Christopher Hoskin <[email protected]>
pechersky pushed a commit to pechersky/mathlib4 that referenced this pull request Aug 25, 2025
…functionals with continuity (leanprover-community#27316)

Sufficient and necessary conditions for a linear functional to be in the span of a finite set of linear functionals.

This result is Rudin, Functional Analysis, Second edition, Lemma 3.9 (see also Bourbaki TVS, II.6 Proposition 5).

A key application of this result is the proof that `WeakBilin.eval B` is surjective i.e. the dual of `E` with the weak topology is identified with `F`.



Co-authored-by: Christopher Hoskin <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). large-import Automatically added label for PRs with a significant increase in transitive imports t-analysis Analysis (normed *, calculus)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants