Skip to content

feat(Analysis/InnerProductSpace): inner products on exterior powers#40724

Open
justus-springer wants to merge 20 commits into
leanprover-community:masterfrom
justus-springer:justus/exterior-power-inner-product
Open

feat(Analysis/InnerProductSpace): inner products on exterior powers#40724
justus-springer wants to merge 20 commits into
leanprover-community:masterfrom
justus-springer:justus/exterior-power-inner-product

Conversation

@justus-springer

@justus-springer justus-springer commented Jun 17, 2026

Copy link
Copy Markdown
Collaborator

Given a real inner product space E, we construct a canonical inner product on ⋀[ℝ]^n E via the Gram determinant formula: on decomposable elements, ⟪v₁ ∧ ⋯ ∧ vₙ, w₁ ∧ ⋯ ∧ wₙ⟫ = det (⟪vⱼ, wᵢ⟫)ᵢⱼ.

There are two generalizations of this construction: Going from to RCLike, and getting rid of the FiniteDimensional assumption. Both would require some prerequisites, hence they are left as future work for now (see the future work section of the module docstring).


Open in Gitpod

@justus-springer justus-springer changed the title feat(LinearAlgebra/ExteriorPower): Inner products on exterior powers feat(LinearAlgebra/ExteriorPower): inner products on exterior powers Jun 17, 2026
@github-actions

github-actions Bot commented Jun 17, 2026

Copy link
Copy Markdown

PR summary 1935330e30

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference
Mathlib.Analysis.InnerProductSpace.ExteriorPower (new file) 2562

Declarations diff (regex)

+ OrthonormalBasis.exteriorPower
+ OrthonormalBasis.toBasis_exteriorPower
+ flip_innerProductForm
+ gram_eq_one_iff_orthonormal
+ innerProductForm
+ innerProductForm_eq_sum
+ innerProductForm_self
+ innerProductForm_symm
+ innerProductForm_ιMulti_family_of_orthonormal
+ innerProductForm_ιMulti_self
+ innerProductForm_ιMulti_ιMulti
+ inner_ιMulti_self
+ inner_ιMulti_ιMulti
+ instance [FiniteDimensional ℝ E] : InnerProductSpace ℝ (⋀[ℝ]^n E)
+ instance [FiniteDimensional ℝ E] : InnerProductSpace.Core ℝ (⋀[ℝ]^n E)
+ instance [FiniteDimensional ℝ E] : NormedAddCommGroup (⋀[ℝ]^n E)

You can run this locally as follows
## from your `mathlib4` directory:
git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci

## summary with just the declaration names:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh <optional_commit>

## more verbose report:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh long <optional_commit>

The doc-module for scripts/pr_summary/declarations_diff.sh in the mathlib-ci repository contains some details about this script.

Declarations diff (Lean)

Lean-aware diff — post-build, computed from the Lean environment (commit 1935330).

  • +8 new declarations
  • −0 removed declarations
+Matrix.gram_eq_one_iff_orthonormal
+OrthonormalBasis.exteriorPower
+OrthonormalBasis.toBasis_exteriorPower
+exteriorPower.inner_ιMulti_self
+exteriorPower.inner_ιMulti_ιMulti
+exteriorPower.instCoreRealSubtypeExteriorAlgebraMemSubmoduleExteriorPowerOfFiniteDimensional
+exteriorPower.instInnerProductSpaceRealSubtypeExteriorAlgebraMemSubmoduleExteriorPower
+exteriorPower.instNormedAddCommGroupSubtypeExteriorAlgebraRealMemSubmoduleExteriorPowerOfFiniteDimensional

No changes to strong technical debt.

Increase in weak tech debt: (relative, absolute) = (1.00, 0.00)
Current number Change Type (weak)
5021 1 exposed public sections

Current commit 1935330e30
Reference commit 65fe2a1f85

This script lives in the mathlib-ci repository. To run it locally, from your mathlib4 directory:

git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci
../mathlib-ci/scripts/reporting/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).

@github-actions

github-actions Bot commented Jun 17, 2026

Copy link
Copy Markdown

✅ PR Title Formatted Correctly

The title of this PR has been updated to match our commit style conventions.
Thank you!

@justus-springer justus-springer changed the title feat(LinearAlgebra/ExteriorPower): inner products on exterior powers feat(Analysis/InnerProductSpace): inner products on exterior powers Jun 18, 2026
Comment thread Mathlib/Analysis/InnerProductSpace/ExteriorPower.lean Outdated
Comment thread Mathlib/Analysis/InnerProductSpace/GramMatrix.lean Outdated
Comment thread Mathlib/Analysis/InnerProductSpace/ExteriorPower.lean Outdated
Comment thread Mathlib/Analysis/InnerProductSpace/ExteriorPower.lean
Comment thread Mathlib/Analysis/InnerProductSpace/ExteriorPower.lean Outdated
justus-springer and others added 2 commits July 23, 2026 16:36
Co-authored-by: Thomas Browning <tb65536@users.noreply.github.com>
@justus-springer justus-springer added the awaiting-author A reviewer has asked the author a question or requested changes. label Jul 23, 2026
@justus-springer justus-springer removed the awaiting-author A reviewer has asked the author a question or requested changes. label Jul 23, 2026

@tb65536 tb65536 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks!

maintainer delegate

Comment thread Mathlib/Analysis/InnerProductSpace/ExteriorPower.lean Outdated
Comment thread Mathlib/Analysis/InnerProductSpace/ExteriorPower.lean Outdated
@github-actions

Copy link
Copy Markdown

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

@mathlib-triage mathlib-triage Bot added the maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. label Jul 23, 2026
justus-springer and others added 2 commits July 23, 2026 17:39
Co-authored-by: Thomas Browning <tb65536@users.noreply.github.com>
Co-authored-by: Thomas Browning <tb65536@users.noreply.github.com>

@riccardobrasca riccardobrasca left a comment

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.

Thanks!

bors d+

/-- The inner product on `⋀[ℝ]^n E` as a bilinear map. This is an implementation detail
for constructing the `InnerProductSpace` instance and should not be used directly.
Use `⟪·, ·⟫` instead. -/
def innerProductForm : ⋀[ℝ]^n E →ₗ[ℝ] ⋀[ℝ]^n 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.

What about not making this public?

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.

For some reason I thought this wasn't possible, but now I see it is if I put @[no_expose] on the inner product instance. In that case, yes I think that's better.

@mathlib-bors mathlib-bors Bot added the delegated This pull request has been delegated to the PR author (or occasionally another non-maintainer). label Jul 27, 2026
@mathlib-bors

mathlib-bors Bot commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

✌️ justus-springer can now approve this pull request until 2026-08-10 05:44 UTC (in 2 weeks). To approve and merge, reply with bors r+. More detailed instructions are available here.

⚠️ This delegation only covers changes within Archive/**, Counterexamples/**, docs/**, DownstreamTest/**, Mathlib/**, MathlibTest/**, widget/**, Archive.lean, Counterexamples.lean, docs.lean, Mathlib.lean; an author commit touching anything else will revoke it. Bors also revokes it if a later push changes too many files for it to check the full list — even if it stays within scope.

@mathlib-triage mathlib-triage Bot removed the maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. label Jul 27, 2026
@justus-springer justus-springer added the awaiting-CI This PR does not pass CI yet. This label is automatically removed once it does. label Jul 27, 2026
@tb65536

tb65536 commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

@justus-springer The build was failing due to long lines. I've pushed a fix.

@github-actions github-actions Bot removed the awaiting-CI This PR does not pass CI yet. This label is automatically removed once it does. label Jul 27, 2026
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).

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants