Skip to content

Commit

Permalink
feat(linear_algebra/dual): define the algebraic dual pairing (#12827)
Browse files Browse the repository at this point in the history
We define the pairing of algebraic dual and show that it is nondegenerate.

Co-authored-by: Kevin Buzzard <k.buzzard@imperial.ac.uk>
  • Loading branch information
mcdoll and kbuzzard committed Mar 30, 2022
1 parent c594e2b commit d28a163
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 1 deletion.
31 changes: 31 additions & 0 deletions src/linear_algebra/dual.lean
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ Authors: Johan Commelin, Fabian Glöckle
-/
import linear_algebra.finite_dimensional
import linear_algebra.projection
import linear_algebra.sesquilinear_form

/-!
# Dual vector spaces
Expand Down Expand Up @@ -52,6 +53,12 @@ instance {S : Type*} [comm_ring S] {N : Type*} [add_comm_group N] [module S N] :
instance : add_monoid_hom_class (dual R M) M R :=
linear_map.add_monoid_hom_class

/-- The canonical pairing of a vector space and its algebraic dual. -/
def dual_pairing (R M) [comm_semiring R] [add_comm_monoid M] [module R M] :
module.dual R M →ₗ[R] M →ₗ[R] R := linear_map.id

@[simp] lemma dual_pairing_apply (v x) : dual_pairing R M v x = v x := rfl

namespace dual

instance : inhabited (dual R M) := by dunfold dual; apply_instance
Expand Down Expand Up @@ -705,4 +712,28 @@ end

end finite_dimensional

section field

variables {K V : Type*}
variables [field K] [add_comm_group V] [module K V]

lemma dual_pairing_nondegenerate : (dual_pairing K V).nondegenerate :=
begin
refine ⟨separating_left_iff_ker_eq_bot.mpr ker_id, _⟩,
intros x,
contrapose,
rintros hx : x ≠ 0,
rw [not_forall],
let f : V →ₗ[K] K := classical.some (linear_pmap.mk_span_singleton x 1 hx).to_fun.exists_extend,
use [f],
refine ne_zero_of_eq_one _,
have h : f.comp (K ∙ x).subtype = (linear_pmap.mk_span_singleton x 1 hx).to_fun :=
classical.some_spec (linear_pmap.mk_span_singleton x (1 : K) hx).to_fun.exists_extend,
rw linear_map.ext_iff at h,
convert h ⟨x, submodule.mem_span_singleton_self x⟩,
exact (linear_pmap.mk_span_singleton_apply' K hx 1).symm,
end

end field

end linear_map
1 change: 0 additions & 1 deletion src/linear_algebra/sesquilinear_form.lean
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ Authors: Andreas Swerdlow
import algebra.module.linear_map
import linear_algebra.bilinear_map
import linear_algebra.matrix.basis
import linear_algebra.dual
import linear_algebra.linear_pmap

/-!
Expand Down

0 comments on commit d28a163

Please sign in to comment.