mathlib documentation

linear_algebra.matrix.bilinear_form

Bilinear form #

This file defines the conversion between bilinear forms and matrices.

Main definitions #

Notations #

In this file we use the following type variables:

Tags #

bilinear_form, matrix, basis

def matrix.to_bilin'_aux {R₂ : Type u_5} [comm_semiring R₂] {n : Type u_11} [fintype n] (M : matrix n n R₂) :
bilin_form R₂ (n → R₂)

The map from matrix n n R to bilinear forms on n → R.

This is an auxiliary definition for the equivalence matrix.to_bilin_form'.

Equations
theorem matrix.to_bilin'_aux_std_basis {R₂ : Type u_5} [comm_semiring R₂] {n : Type u_11} [fintype n] [decidable_eq n] (M : matrix n n R₂) (i j : n) :
(M.to_bilin'_aux) ((linear_map.std_basis R₂ (λ (_x : n), R₂) i) 1) ((linear_map.std_basis R₂ (λ (_x : n), R₂) j) 1) = M i j
def bilin_form.to_matrix_aux {R₂ : Type u_5} {M₂ : Type u_6} [comm_semiring R₂] [add_comm_monoid M₂] [module R₂ M₂] {n : Type u_11} (b : n → M₂) :
bilin_form R₂ M₂ →ₗ[R₂] matrix n n R₂

The linear map from bilinear forms to matrix n n R given an n-indexed basis.

This is an auxiliary definition for the equivalence matrix.to_bilin_form'.

Equations
theorem to_bilin'_aux_to_matrix_aux {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (B₃ : bilin_form R₃ (n → R₃)) :
((bilin_form.to_matrix_aux (λ (j : n), (linear_map.std_basis R₃ (λ (_x : n), R₃) j) 1)) B₃).to_bilin'_aux = B₃

to_matrix' section #

This section deals with the conversion between matrices and bilinear forms on n → R₃.

def bilin_form.to_matrix' {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] :
bilin_form R₃ (n → R₃) ≃ₗ[R₃] matrix n n R₃

The linear equivalence between bilinear forms on n → R and n × n matrices

Equations
@[simp]
theorem bilin_form.to_matrix_aux_std_basis {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (B : bilin_form R₃ (n → R₃)) :
(bilin_form.to_matrix_aux (λ (j : n), (linear_map.std_basis R₃ (λ (_x : n), R₃) j) 1)) B = bilin_form.to_matrix' B
def matrix.to_bilin' {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] :
matrix n n R₃ ≃ₗ[R₃] bilin_form R₃ (n → R₃)

The linear equivalence between n × n matrices and bilinear forms on n → R

Equations
@[simp]
theorem matrix.to_bilin'_aux_eq {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (M : matrix n n R₃) :
theorem matrix.to_bilin'_apply {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (M : matrix n n R₃) (x y : n → R₃) :
(matrix.to_bilin' M) x y = ∑ (i j : n), ((x i) * M i j) * y j
theorem matrix.to_bilin'_apply' {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (M : matrix n n R₃) (v w : n → R₃) :
@[simp]
theorem matrix.to_bilin'_std_basis {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (M : matrix n n R₃) (i j : n) :
(matrix.to_bilin' M) ((linear_map.std_basis R₃ (λ (_x : n), R₃) i) 1) ((linear_map.std_basis R₃ (λ (_x : n), R₃) j) 1) = M i j
@[simp]
theorem bilin_form.to_matrix'_symm {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] :
@[simp]
theorem matrix.to_bilin'_symm {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] :
@[simp]
theorem matrix.to_bilin'_to_matrix' {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (B : bilin_form R₃ (n → R₃)) :
@[simp]
theorem bilin_form.to_matrix'_to_bilin' {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (M : matrix n n R₃) :
@[simp]
theorem bilin_form.to_matrix'_apply {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (B : bilin_form R₃ (n → R₃)) (i j : n) :
bilin_form.to_matrix' B i j = B ((linear_map.std_basis R₃ (λ (_x : n), R₃) i) 1) ((linear_map.std_basis R₃ (λ (_x : n), R₃) j) 1)
@[simp]
theorem bilin_form.to_matrix'_comp {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} {o : Type u_12} [fintype n] [fintype o] [decidable_eq n] [decidable_eq o] (B : bilin_form R₃ (n → R₃)) (l r : (o → R₃) →ₗ[R₃] n → R₃) :
theorem bilin_form.to_matrix'_comp_left {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (B : bilin_form R₃ (n → R₃)) (f : (n → R₃) →ₗ[R₃] n → R₃) :
theorem bilin_form.to_matrix'_comp_right {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (B : bilin_form R₃ (n → R₃)) (f : (n → R₃) →ₗ[R₃] n → R₃) :
theorem bilin_form.mul_to_matrix'_mul {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} {o : Type u_12} [fintype n] [fintype o] [decidable_eq n] [decidable_eq o] (B : bilin_form R₃ (n → R₃)) (M : matrix o n R₃) (N : matrix n o R₃) :
theorem bilin_form.mul_to_matrix' {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (B : bilin_form R₃ (n → R₃)) (M : matrix n n R₃) :
theorem bilin_form.to_matrix'_mul {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] (B : bilin_form R₃ (n → R₃)) (M : matrix n n R₃) :
theorem matrix.to_bilin'_comp {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} {o : Type u_12} [fintype n] [fintype o] [decidable_eq n] [decidable_eq o] (M : matrix n n R₃) (P Q : matrix n o R₃) :

to_matrix section #

This section deals with the conversion between matrices and bilinear forms on a module with a fixed basis.

noncomputable def bilin_form.to_matrix {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) :
bilin_form R₃ M₃ ≃ₗ[R₃] matrix n n R₃

bilin_form.to_matrix b is the equivalence between R-bilinear forms on M and n-by-n matrices with entries in R, if b is an R-basis for M.

Equations
noncomputable def matrix.to_bilin {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) :
matrix n n R₃ ≃ₗ[R₃] bilin_form R₃ M₃

bilin_form.to_matrix b is the equivalence between R-bilinear forms on M and n-by-n matrices with entries in R, if b is an R-basis for M.

Equations
@[simp]
theorem basis.equiv_fun_symm_std_basis {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) (i : n) :
(b.equiv_fun.symm) ((linear_map.std_basis R₃ (λ (_x : n), R₃) i) 1) = b i
@[simp]
theorem bilin_form.to_matrix_apply {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) (B : bilin_form R₃ M₃) (i j : n) :
(bilin_form.to_matrix b) B i j = B (b i) (b j)
@[simp]
theorem matrix.to_bilin_apply {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) (M : matrix n n R₃) (x y : M₃) :
((matrix.to_bilin b) M) x y = ∑ (i j : n), ((((b.repr) x) i) * M i j) * ((b.repr) y) j
theorem bilinear_form.to_matrix_aux_eq {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) (B : bilin_form R₃ M₃) :
@[simp]
theorem bilin_form.to_matrix_symm {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) :
@[simp]
theorem matrix.to_bilin_symm {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) :
theorem matrix.to_bilin_basis_fun {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] :
theorem bilin_form.to_matrix_basis_fun {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] [decidable_eq n] :
@[simp]
theorem matrix.to_bilin_to_matrix {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) (B : bilin_form R₃ M₃) :
@[simp]
theorem bilin_form.to_matrix_to_bilin {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) (M : matrix n n R₃) :
theorem bilin_form.to_matrix_comp {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} {o : Type u_12} [fintype n] [fintype o] [decidable_eq n] (b : basis n R₃ M₃) {M₃' : Type u_13} [add_comm_group M₃'] [module R₃ M₃'] (c : basis o R₃ M₃') [decidable_eq o] (B : bilin_form R₃ M₃) (l r : M₃' →ₗ[R₃] M₃) :
theorem bilin_form.to_matrix_comp_left {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) (B : bilin_form R₃ M₃) (f : M₃ →ₗ[R₃] M₃) :
theorem bilin_form.to_matrix_comp_right {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) (B : bilin_form R₃ M₃) (f : M₃ →ₗ[R₃] M₃) :
@[simp]
theorem bilin_form.to_matrix_mul_basis_to_matrix {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} {o : Type u_12} [fintype n] [fintype o] [decidable_eq n] (b : basis n R₃ M₃) [decidable_eq o] (c : basis o R₃ M₃) (B : bilin_form R₃ M₃) :
theorem bilin_form.mul_to_matrix_mul {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} {o : Type u_12} [fintype n] [fintype o] [decidable_eq n] (b : basis n R₃ M₃) {M₃' : Type u_13} [add_comm_group M₃'] [module R₃ M₃'] (c : basis o R₃ M₃') [decidable_eq o] (B : bilin_form R₃ M₃) (M : matrix o n R₃) (N : matrix n o R₃) :
theorem bilin_form.mul_to_matrix {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) (B : bilin_form R₃ M₃) (M : matrix n n R₃) :
theorem bilin_form.to_matrix_mul {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] [decidable_eq n] (b : basis n R₃ M₃) (B : bilin_form R₃ M₃) (M : matrix n n R₃) :
theorem matrix.to_bilin_comp {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} {o : Type u_12} [fintype n] [fintype o] [decidable_eq n] (b : basis n R₃ M₃) {M₃' : Type u_13} [add_comm_group M₃'] [module R₃ M₃'] (c : basis o R₃ M₃') [decidable_eq o] (M : matrix n n R₃) (P Q : matrix n o R₃) :
def matrix.is_adjoint_pair {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J J₃ A A' : matrix n n R₃) :
Prop

The condition for the square matrices A, A' to be an adjoint pair with respect to the square matrices J, J₃.

Equations
def matrix.is_self_adjoint {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J A : matrix n n R₃) :
Prop

The condition for a square matrix A to be self-adjoint with respect to the square matrix J.

Equations
def matrix.is_skew_adjoint {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J A : matrix n n R₃) :
Prop

The condition for a square matrix A to be skew-adjoint with respect to the square matrix J.

Equations
@[simp]
theorem is_adjoint_pair_to_bilin' {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J J₃ A A' : matrix n n R₃) [decidable_eq n] :
@[simp]
theorem is_adjoint_pair_to_bilin {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {n : Type u_11} [fintype n] (b : basis n R₃ M₃) (J J₃ A A' : matrix n n R₃) [decidable_eq n] :
theorem matrix.is_adjoint_pair_equiv {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J A A' : matrix n n R₃) [decidable_eq n] (P : matrix n n R₃) (h : is_unit P) :
(P J P).is_adjoint_pair (P J P) A A' J.is_adjoint_pair J (P A P⁻¹) (P A' P⁻¹)
def pair_self_adjoint_matrices_submodule {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J J₃ : matrix n n R₃) [decidable_eq n] :
submodule R₃ (matrix n n R₃)

The submodule of pair-self-adjoint matrices with respect to bilinear forms corresponding to given matrices J, J₂.

Equations
@[simp]
theorem mem_pair_self_adjoint_matrices_submodule {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J J₃ A : matrix n n R₃) [decidable_eq n] :
def self_adjoint_matrices_submodule {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J : matrix n n R₃) [decidable_eq n] :
submodule R₃ (matrix n n R₃)

The submodule of self-adjoint matrices with respect to the bilinear form corresponding to the matrix J.

Equations
@[simp]
theorem mem_self_adjoint_matrices_submodule {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J A : matrix n n R₃) [decidable_eq n] :
def skew_adjoint_matrices_submodule {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J : matrix n n R₃) [decidable_eq n] :
submodule R₃ (matrix n n R₃)

The submodule of skew-adjoint matrices with respect to the bilinear form corresponding to the matrix J.

Equations
@[simp]
theorem mem_skew_adjoint_matrices_submodule {R₃ : Type u_7} [comm_ring R₃] {n : Type u_11} [fintype n] (J A : matrix n n R₃) [decidable_eq n] :
theorem matrix.nondegenerate_to_bilin'_iff_nondegenerate_to_bilin {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {ι : Type u_12} [decidable_eq ι] [fintype ι] {M : matrix ι ι R₃} (b : basis ι R₃ M₃) :
theorem matrix.nondegenerate.to_bilin' {R₃ : Type u_7} [comm_ring R₃] {ι : Type u_12} [decidable_eq ι] [fintype ι] {M : matrix ι ι R₃} (h : M.nondegenerate) :
@[simp]
theorem matrix.nondegenerate_to_bilin'_iff {R₃ : Type u_7} [comm_ring R₃] {ι : Type u_12} [decidable_eq ι] [fintype ι] {M : matrix ι ι R₃} :
theorem matrix.nondegenerate.to_bilin {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {ι : Type u_12} [decidable_eq ι] [fintype ι] {M : matrix ι ι R₃} (h : M.nondegenerate) (b : basis ι R₃ M₃) :
@[simp]
theorem matrix.nondegenerate_to_bilin_iff {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {ι : Type u_12} [decidable_eq ι] [fintype ι] {M : matrix ι ι R₃} (b : basis ι R₃ M₃) :
@[simp]
theorem bilin_form.nondegenerate_to_matrix'_iff {R₃ : Type u_7} [comm_ring R₃] {ι : Type u_12} [decidable_eq ι] [fintype ι] {B : bilin_form R₃ (ι → R₃)} :
theorem bilin_form.nondegenerate.to_matrix' {R₃ : Type u_7} [comm_ring R₃] {ι : Type u_12} [decidable_eq ι] [fintype ι] {B : bilin_form R₃ (ι → R₃)} (h : B.nondegenerate) :
@[simp]
theorem bilin_form.nondegenerate_to_matrix_iff {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {ι : Type u_12} [decidable_eq ι] [fintype ι] {B : bilin_form R₃ M₃} (b : basis ι R₃ M₃) :
theorem bilin_form.nondegenerate.to_matrix {R₃ : Type u_7} {M₃ : Type u_8} [comm_ring R₃] [add_comm_group M₃] [module R₃ M₃] {ι : Type u_12} [decidable_eq ι] [fintype ι] {B : bilin_form R₃ M₃} (h : B.nondegenerate) (b : basis ι R₃ M₃) :
theorem bilin_form.nondegenerate_to_bilin'_iff_det_ne_zero {A : Type u_11} [comm_ring A] [is_domain A] {ι : Type u_12} [decidable_eq ι] [fintype ι] {M : matrix ι ι A} :
theorem bilin_form.nondegenerate_to_bilin'_of_det_ne_zero' {A : Type u_11} [comm_ring A] [is_domain A] {ι : Type u_12} [decidable_eq ι] [fintype ι] (M : matrix ι ι A) (h : M.det 0) :
theorem bilin_form.nondegenerate_iff_det_ne_zero {M₃ : Type u_8} [add_comm_group M₃] {A : Type u_11} [comm_ring A] [is_domain A] [module A M₃] {ι : Type u_12} [decidable_eq ι] [fintype ι] {B : bilin_form A M₃} (b : basis ι A M₃) :
theorem bilin_form.nondegenerate_of_det_ne_zero {M₃ : Type u_8} [add_comm_group M₃] {A : Type u_11} [comm_ring A] [is_domain A] [module A M₃] (B₃ : bilin_form A M₃) {ι : Type u_12} [decidable_eq ι] [fintype ι] (b : basis ι A M₃) (h : ((bilin_form.to_matrix b) B₃).det 0) :