Documentation

Mathlib.LinearAlgebra.BilinearForm

Bilinear form #

This file defines a bilinear form over a module. Basic ideas such as orthogonality are also introduced, as well as reflexive, symmetric, non-degenerate and alternating bilinear forms. Adjoints of linear maps with respect to a bilinear form are also introduced.

A bilinear form on an R-(semi)module M, is a function from M × M to R, that is linear in both arguments. Comments will typically abbreviate "(semi)module" as just "module", but the definitions should be as general as possible.

The result that there exists an orthogonal basis with respect to a symmetric, nondegenerate bilinear form can be found in QuadraticForm.lean with exists_orthogonal_basis.

Notations #

Given any term B of type BilinForm, due to a coercion, can use the notation B x y to refer to the function field, ie. B x y = B.bilin x y.

In this file we use the following type variables:

References #

Tags #

Bilinear form,

structure BilinForm (R : Type u_1) (M : Type u_2) [Semiring R] [AddCommMonoid M] [Module R M] :
Type (max u_1 u_2)

BilinForm R M is the type of R-bilinear functions M → M → R.

Instances For
    instance BilinForm.instCoeFunBilinFormForAll {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :
    CoeFun (BilinForm R M) fun x => MMR
    Equations
    • BilinForm.instCoeFunBilinFormForAll = { coe := BilinForm.bilin }
    theorem BilinForm.coeFn_mk {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (f : MMR) (h₁ : ∀ (x y z : M), f (x + y) z = f x z + f y z) (h₂ : ∀ (a : R) (x y : M), f (a x) y = a * f x y) (h₃ : ∀ (x y z : M), f x (y + z) = f x y + f x z) (h₄ : ∀ (a : R) (x y : M), f x (a y) = a * f x y) :
    { bilin := f, bilin_add_left := h₁, bilin_smul_left := h₂, bilin_add_right := h₃, bilin_smul_right := h₄ }.bilin = f
    theorem BilinForm.coeFn_congr {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {x : M} {x' : M} {y : M} {y' : M} :
    x = x'y = y'BilinForm.bilin B x y = BilinForm.bilin B x' y'
    @[simp]
    theorem BilinForm.add_left {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (x : M) (y : M) (z : M) :
    @[simp]
    theorem BilinForm.smul_left {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (a : R) (x : M) (y : M) :
    @[simp]
    theorem BilinForm.add_right {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (x : M) (y : M) (z : M) :
    @[simp]
    theorem BilinForm.smul_right {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (a : R) (x : M) (y : M) :
    @[simp]
    theorem BilinForm.zero_left {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (x : M) :
    @[simp]
    theorem BilinForm.zero_right {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (x : M) :
    @[simp]
    theorem BilinForm.neg_left {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B₁ : BilinForm R₁ M₁} (x : M₁) (y : M₁) :
    BilinForm.bilin B₁ (-x) y = -BilinForm.bilin B₁ x y
    @[simp]
    theorem BilinForm.neg_right {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B₁ : BilinForm R₁ M₁} (x : M₁) (y : M₁) :
    BilinForm.bilin B₁ x (-y) = -BilinForm.bilin B₁ x y
    @[simp]
    theorem BilinForm.sub_left {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B₁ : BilinForm R₁ M₁} (x : M₁) (y : M₁) (z : M₁) :
    BilinForm.bilin B₁ (x - y) z = BilinForm.bilin B₁ x z - BilinForm.bilin B₁ y z
    @[simp]
    theorem BilinForm.sub_right {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B₁ : BilinForm R₁ M₁} (x : M₁) (y : M₁) (z : M₁) :
    BilinForm.bilin B₁ x (y - z) = BilinForm.bilin B₁ x y - BilinForm.bilin B₁ x z
    theorem BilinForm.coe_injective {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :
    Function.Injective BilinForm.bilin
    theorem BilinForm.ext {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {D : BilinForm R M} (H : ∀ (x y : M), BilinForm.bilin B x y = BilinForm.bilin D x y) :
    B = D
    theorem BilinForm.congr_fun {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {D : BilinForm R M} (h : B = D) (x : M) (y : M) :
    theorem BilinForm.ext_iff {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {D : BilinForm R M} :
    B = D ∀ (x y : M), BilinForm.bilin B x y = BilinForm.bilin D x y
    instance BilinForm.instZeroBilinForm {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :
    Equations
    • One or more equations did not get rendered due to their size.
    @[simp]
    theorem BilinForm.coe_zero {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :
    0.bilin = 0
    @[simp]
    theorem BilinForm.zero_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (x : M) (y : M) :
    instance BilinForm.instAddBilinForm {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :
    Equations
    • One or more equations did not get rendered due to their size.
    @[simp]
    theorem BilinForm.coe_add {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (D : BilinForm R M) :
    (B + D).bilin = B.bilin + D.bilin
    @[simp]
    theorem BilinForm.add_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (D : BilinForm R M) (x : M) (y : M) :
    instance BilinForm.instSMulBilinForm {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {α : Type u_11} [Monoid α] [DistribMulAction α R] [SMulCommClass α R R] :
    SMul α (BilinForm R M)

    BilinForm R M inherits the scalar action by α on R if this is compatible with multiplication.

    When R itself is commutative, this provides an R-action via Algebra.id.

    Equations
    • One or more equations did not get rendered due to their size.
    @[simp]
    theorem BilinForm.coe_smul {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {α : Type u_11} [Monoid α] [DistribMulAction α R] [SMulCommClass α R R] (a : α) (B : BilinForm R M) :
    (a B).bilin = a B.bilin
    @[simp]
    theorem BilinForm.smul_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {α : Type u_11} [Monoid α] [DistribMulAction α R] [SMulCommClass α R R] (a : α) (B : BilinForm R M) (x : M) (y : M) :
    Equations
    • One or more equations did not get rendered due to their size.
    instance BilinForm.instNegBilinFormToSemiringToAddCommMonoid {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] :
    Neg (BilinForm R₁ M₁)
    Equations
    • One or more equations did not get rendered due to their size.
    @[simp]
    theorem BilinForm.coe_neg {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] (B₁ : BilinForm R₁ M₁) :
    (-B₁).bilin = -B₁.bilin
    @[simp]
    theorem BilinForm.neg_apply {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] (B₁ : BilinForm R₁ M₁) (x : M₁) (y : M₁) :
    BilinForm.bilin (-B₁) x y = -BilinForm.bilin B₁ x y
    instance BilinForm.instSubBilinFormToSemiringToAddCommMonoid {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] :
    Sub (BilinForm R₁ M₁)
    Equations
    • One or more equations did not get rendered due to their size.
    @[simp]
    theorem BilinForm.coe_sub {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] (B₁ : BilinForm R₁ M₁) (D₁ : BilinForm R₁ M₁) :
    (B₁ - D₁).bilin = B₁.bilin - D₁.bilin
    @[simp]
    theorem BilinForm.sub_apply {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] (B₁ : BilinForm R₁ M₁) (D₁ : BilinForm R₁ M₁) (x : M₁) (y : M₁) :
    BilinForm.bilin (B₁ - D₁) x y = BilinForm.bilin B₁ x y - BilinForm.bilin D₁ x y
    instance BilinForm.instAddCommGroupBilinFormToSemiringToAddCommMonoid {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] :
    Equations
    • One or more equations did not get rendered due to their size.
    instance BilinForm.instInhabitedBilinForm {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :
    Equations
    • BilinForm.instInhabitedBilinForm = { default := 0 }
    def BilinForm.coeFnAddMonoidHom {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :
    BilinForm R M →+ MMR

    coeFn as an AddMonoidHom

    Equations
    • BilinForm.coeFnAddMonoidHom = { toZeroHom := { toFun := BilinForm.bilin, map_zero' := (_ : 0.bilin = 0) }, map_add' := (_ : ∀ (B D : BilinForm R M), (B + D).bilin = B.bilin + D.bilin) }
    Instances For
      Equations
      • One or more equations did not get rendered due to their size.
      instance BilinForm.instModuleBilinFormInstAddCommMonoidBilinForm {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {α : Type u_11} [Semiring α] [Module α R] [SMulCommClass α R R] :
      Module α (BilinForm R M)
      Equations
      • One or more equations did not get rendered due to their size.
      def BilinForm.flipHomAux {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (R₂ : Type u_5) [CommSemiring R₂] [Algebra R₂ R] :

      Auxiliary construction for the flip of a bilinear form, obtained by exchanging the left and right arguments. This version is a LinearMap; it is later upgraded to a LinearEquiv in flipHom.

      Equations
      • One or more equations did not get rendered due to their size.
      Instances For
        theorem BilinForm.flip_flip_aux {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {R₂ : Type u_5} [CommSemiring R₂] [Algebra R₂ R] (A : BilinForm R M) :
        ↑(BilinForm.flipHomAux R₂) (↑(BilinForm.flipHomAux R₂) A) = A
        def BilinForm.flipHom {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (R₂ : Type u_5) [CommSemiring R₂] [Algebra R₂ R] :

        The flip of a bilinear form, obtained by exchanging the left and right arguments. This is a less structured version of the equiv which applies to general (noncommutative) rings R with a distinguished commutative subring R₂; over a commutative ring use flip.

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          @[simp]
          theorem BilinForm.flip_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {R₂ : Type u_5} [CommSemiring R₂] [Algebra R₂ R] (A : BilinForm R M) (x : M) (y : M) :
          theorem BilinForm.flip_flip {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {R₂ : Type u_5} [CommSemiring R₂] [Algebra R₂ R] :
          @[inline, reducible]
          abbrev BilinForm.flip' {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :

          The flip of a bilinear form over a ring, obtained by exchanging the left and right arguments, here considered as an -linear equivalence, i.e. an additive equivalence.

          Equations
          Instances For
            @[inline, reducible]
            abbrev BilinForm.flip {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] :
            BilinForm R₂ M₂ ≃ₗ[R₂] BilinForm R₂ M₂

            The flip of a bilinear form over a commutative ring, obtained by exchanging the left and right arguments.

            Equations
            Instances For
              def BilinForm.toLinHomAux₁ {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (A : BilinForm R M) (x : M) :

              Auxiliary definition to define toLinHom; see below.

              Equations
              • One or more equations did not get rendered due to their size.
              Instances For
                def BilinForm.toLinHomAux₂ {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {R₂ : Type u_5} [CommSemiring R₂] [Algebra R₂ R] [Module R₂ M] [IsScalarTower R₂ R M] (A : BilinForm R M) :
                M →ₗ[R₂] M →ₗ[R] R

                Auxiliary definition to define toLinHom; see below.

                Equations
                • One or more equations did not get rendered due to their size.
                Instances For
                  def BilinForm.toLinHom {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (R₂ : Type u_5) [CommSemiring R₂] [Algebra R₂ R] [Module R₂ M] [IsScalarTower R₂ R M] :
                  BilinForm R M →ₗ[R₂] M →ₗ[R₂] M →ₗ[R] R

                  The linear map obtained from a BilinForm by fixing the left co-ordinate and evaluating in the right. This is the most general version of the construction; it is R₂-linear for some distinguished commutative subsemiring R₂ of the scalar ring. Over a semiring with no particular distinguished such subsemiring, use toLin', which is -linear. Over a commutative semiring, use toLin, which is linear.

                  Equations
                  • One or more equations did not get rendered due to their size.
                  Instances For
                    @[simp]
                    theorem BilinForm.toLin'_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {R₂ : Type u_5} [CommSemiring R₂] [Algebra R₂ R] [Module R₂ M] [IsScalarTower R₂ R M] (A : BilinForm R M) (x : M) :
                    ↑(↑(↑(BilinForm.toLinHom R₂) A) x) = BilinForm.bilin A x
                    @[inline, reducible]
                    abbrev BilinForm.toLin' {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :

                    The linear map obtained from a BilinForm by fixing the left co-ordinate and evaluating in the right. Over a commutative semiring, use toLin, which is linear rather than -linear.

                    Equations
                    Instances For
                      @[simp]
                      theorem BilinForm.sum_left {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) {α : Type u_11} (t : Finset α) (g : αM) (w : M) :
                      BilinForm.bilin B (Finset.sum t fun i => g i) w = Finset.sum t fun i => BilinForm.bilin B (g i) w
                      @[simp]
                      theorem BilinForm.sum_right {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) {α : Type u_11} (t : Finset α) (w : M) (g : αM) :
                      BilinForm.bilin B w (Finset.sum t fun i => g i) = Finset.sum t fun i => BilinForm.bilin B w (g i)
                      def BilinForm.toLinHomFlip {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (R₂ : Type u_5) [CommSemiring R₂] [Algebra R₂ R] [Module R₂ M] [IsScalarTower R₂ R M] :
                      BilinForm R M →ₗ[R₂] M →ₗ[R₂] M →ₗ[R] R

                      The linear map obtained from a BilinForm by fixing the right co-ordinate and evaluating in the left. This is the most general version of the construction; it is R₂-linear for some distinguished commutative subsemiring R₂ of the scalar ring. Over semiring with no particular distinguished such subsemiring, use toLin'Flip, which is -linear. Over a commutative semiring, use toLinFlip, which is linear.

                      Equations
                      Instances For
                        @[simp]
                        theorem BilinForm.toLin'Flip_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {R₂ : Type u_5} [CommSemiring R₂] [Algebra R₂ R] [Module R₂ M] [IsScalarTower R₂ R M] (A : BilinForm R M) (x : M) :
                        ↑(↑(↑(BilinForm.toLinHomFlip R₂) A) x) = fun y => BilinForm.bilin A y x
                        @[inline, reducible]

                        The linear map obtained from a BilinForm by fixing the right co-ordinate and evaluating in the left. Over a commutative semiring, use toLinFlip, which is linear rather than -linear.

                        Equations
                        Instances For
                          def LinearMap.toBilinAux {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] (f : M₂ →ₗ[R₂] M₂ →ₗ[R₂] R₂) :
                          BilinForm R₂ M₂

                          A map with two arguments that is linear in both is a bilinear form.

                          This is an auxiliary definition for the full linear equivalence LinearMap.toBilin.

                          Equations
                          • One or more equations did not get rendered due to their size.
                          Instances For
                            def BilinForm.toLin {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] :
                            BilinForm R₂ M₂ ≃ₗ[R₂] M₂ →ₗ[R₂] M₂ →ₗ[R₂] R₂

                            Bilinear forms are linearly equivalent to maps with two arguments that are linear in both.

                            Equations
                            • One or more equations did not get rendered due to their size.
                            Instances For
                              def LinearMap.toBilin {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] :
                              (M₂ →ₗ[R₂] M₂ →ₗ[R₂] R₂) ≃ₗ[R₂] BilinForm R₂ M₂

                              A map with two arguments that is linear in both is linearly equivalent to bilinear form.

                              Equations
                              Instances For
                                @[simp]
                                theorem LinearMap.toBilinAux_eq {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] (f : M₂ →ₗ[R₂] M₂ →ₗ[R₂] R₂) :
                                LinearMap.toBilinAux f = LinearMap.toBilin f
                                @[simp]
                                theorem LinearMap.toBilin_symm {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] :
                                LinearEquiv.symm LinearMap.toBilin = BilinForm.toLin
                                @[simp]
                                theorem BilinForm.toLin_symm {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] :
                                LinearEquiv.symm BilinForm.toLin = LinearMap.toBilin
                                @[simp]
                                theorem LinearMap.toBilin_apply {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] (f : M₂ →ₗ[R₂] M₂ →ₗ[R₂] R₂) (x : M₂) (y : M₂) :
                                BilinForm.bilin (LinearMap.toBilin f) x y = ↑(f x) y
                                @[simp]
                                theorem BilinForm.toLin_apply {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {B₂ : BilinForm R₂ M₂} (x : M₂) :
                                ↑(↑(BilinForm.toLin B₂) x) = BilinForm.bilin B₂ x
                                @[simp]
                                theorem LinearMap.compBilinForm_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {R' : Type u_11} [CommSemiring R'] [Algebra R' R] [Module R' M] [IsScalarTower R' R M] (f : R →ₗ[R'] R') (B : BilinForm R M) (x : M) (y : M) :
                                def LinearMap.compBilinForm {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {R' : Type u_11} [CommSemiring R'] [Algebra R' R] [Module R' M] [IsScalarTower R' R M] (f : R →ₗ[R'] R') (B : BilinForm R M) :

                                Apply a linear map on the output of a bilinear form.

                                Equations
                                • One or more equations did not get rendered due to their size.
                                Instances For
                                  def BilinForm.comp {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {M' : Type w} [AddCommMonoid M'] [Module R M'] (B : BilinForm R M') (l : M →ₗ[R] M') (r : M →ₗ[R] M') :

                                  Apply a linear map on the left and right argument of a bilinear form.

                                  Equations
                                  • One or more equations did not get rendered due to their size.
                                  Instances For
                                    def BilinForm.compLeft {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (f : M →ₗ[R] M) :

                                    Apply a linear map to the left argument of a bilinear form.

                                    Equations
                                    Instances For
                                      def BilinForm.compRight {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (f : M →ₗ[R] M) :

                                      Apply a linear map to the right argument of a bilinear form.

                                      Equations
                                      Instances For
                                        theorem BilinForm.comp_comp {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {M' : Type w} [AddCommMonoid M'] [Module R M'] {M'' : Type u_11} [AddCommMonoid M''] [Module R M''] (B : BilinForm R M'') (l : M →ₗ[R] M') (r : M →ₗ[R] M') (l' : M' →ₗ[R] M'') (r' : M' →ₗ[R] M'') :
                                        @[simp]
                                        theorem BilinForm.compLeft_compRight {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (l : M →ₗ[R] M) (r : M →ₗ[R] M) :
                                        @[simp]
                                        theorem BilinForm.compRight_compLeft {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (l : M →ₗ[R] M) (r : M →ₗ[R] M) :
                                        @[simp]
                                        theorem BilinForm.comp_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {M' : Type w} [AddCommMonoid M'] [Module R M'] (B : BilinForm R M') (l : M →ₗ[R] M') (r : M →ₗ[R] M') (v : M) (w : M) :
                                        BilinForm.bilin (BilinForm.comp B l r) v w = BilinForm.bilin B (l v) (r w)
                                        @[simp]
                                        theorem BilinForm.compLeft_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (f : M →ₗ[R] M) (v : M) (w : M) :
                                        @[simp]
                                        theorem BilinForm.compRight_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (f : M →ₗ[R] M) (v : M) (w : M) :
                                        @[simp]
                                        theorem BilinForm.comp_id_left {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (r : M →ₗ[R] M) :
                                        BilinForm.comp B LinearMap.id r = BilinForm.compRight B r
                                        @[simp]
                                        theorem BilinForm.comp_id_right {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (l : M →ₗ[R] M) :
                                        BilinForm.comp B l LinearMap.id = BilinForm.compLeft B l
                                        @[simp]
                                        theorem BilinForm.compLeft_id {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) :
                                        BilinForm.compLeft B LinearMap.id = B
                                        @[simp]
                                        theorem BilinForm.compRight_id {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) :
                                        BilinForm.compRight B LinearMap.id = B
                                        @[simp]
                                        theorem BilinForm.comp_id_id {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) :
                                        BilinForm.comp B LinearMap.id LinearMap.id = B
                                        theorem BilinForm.comp_inj {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {M' : Type w} [AddCommMonoid M'] [Module R M'] (B₁ : BilinForm R M') (B₂ : BilinForm R M') {l : M →ₗ[R] M'} {r : M →ₗ[R] M'} (hₗ : Function.Surjective l) (hᵣ : Function.Surjective r) :
                                        BilinForm.comp B₁ l r = BilinForm.comp B₂ l r B₁ = B₂
                                        def BilinForm.congr {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {M₂' : Type u_11} [AddCommMonoid M₂'] [Module R₂ M₂'] (e : M₂ ≃ₗ[R₂] M₂') :
                                        BilinForm R₂ M₂ ≃ₗ[R₂] BilinForm R₂ M₂'

                                        Apply a linear equivalence on the arguments of a bilinear form.

                                        Equations
                                        • One or more equations did not get rendered due to their size.
                                        Instances For
                                          @[simp]
                                          theorem BilinForm.congr_apply {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {M₂' : Type u_11} [AddCommMonoid M₂'] [Module R₂ M₂'] (e : M₂ ≃ₗ[R₂] M₂') (B : BilinForm R₂ M₂) (x : M₂') (y : M₂') :
                                          @[simp]
                                          theorem BilinForm.congr_symm {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {M₂' : Type u_11} [AddCommMonoid M₂'] [Module R₂ M₂'] (e : M₂ ≃ₗ[R₂] M₂') :
                                          @[simp]
                                          theorem BilinForm.congr_refl {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] :
                                          theorem BilinForm.congr_trans {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {M₂' : Type u_11} {M₂'' : Type u_12} [AddCommMonoid M₂'] [AddCommMonoid M₂''] [Module R₂ M₂'] [Module R₂ M₂''] (e : M₂ ≃ₗ[R₂] M₂') (f : M₂' ≃ₗ[R₂] M₂'') :
                                          theorem BilinForm.congr_congr {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {M₂' : Type u_11} {M₂'' : Type u_12} [AddCommMonoid M₂'] [AddCommMonoid M₂''] [Module R₂ M₂'] [Module R₂ M₂''] (e : M₂' ≃ₗ[R₂] M₂'') (f : M₂ ≃ₗ[R₂] M₂') (B : BilinForm R₂ M₂) :
                                          theorem BilinForm.congr_comp {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {M₂' : Type u_11} {M₂'' : Type u_12} [AddCommMonoid M₂'] [AddCommMonoid M₂''] [Module R₂ M₂'] [Module R₂ M₂''] (e : M₂ ≃ₗ[R₂] M₂') (B : BilinForm R₂ M₂) (l : M₂'' →ₗ[R₂] M₂') (r : M₂'' →ₗ[R₂] M₂') :
                                          theorem BilinForm.comp_congr {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {M₂' : Type u_11} {M₂'' : Type u_12} [AddCommMonoid M₂'] [AddCommMonoid M₂''] [Module R₂ M₂'] [Module R₂ M₂''] (e : M₂' ≃ₗ[R₂] M₂'') (B : BilinForm R₂ M₂) (l : M₂' →ₗ[R₂] M₂) (r : M₂' →ₗ[R₂] M₂) :
                                          def BilinForm.linMulLin {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] (f : M₂ →ₗ[R₂] R₂) (g : M₂ →ₗ[R₂] R₂) :
                                          BilinForm R₂ M₂

                                          linMulLin f g is the bilinear form mapping x and y to f x * g y

                                          Equations
                                          • One or more equations did not get rendered due to their size.
                                          Instances For
                                            @[simp]
                                            theorem BilinForm.linMulLin_apply {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {f : M₂ →ₗ[R₂] R₂} {g : M₂ →ₗ[R₂] R₂} (x : M₂) (y : M₂) :
                                            BilinForm.bilin (BilinForm.linMulLin f g) x y = f x * g y
                                            @[simp]
                                            theorem BilinForm.linMulLin_comp {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {M₂' : Type u_11} [AddCommMonoid M₂'] [Module R₂ M₂'] {f : M₂ →ₗ[R₂] R₂} {g : M₂ →ₗ[R₂] R₂} (l : M₂' →ₗ[R₂] M₂) (r : M₂' →ₗ[R₂] M₂) :
                                            @[simp]
                                            theorem BilinForm.linMulLin_compLeft {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {f : M₂ →ₗ[R₂] R₂} {g : M₂ →ₗ[R₂] R₂} (l : M₂ →ₗ[R₂] M₂) :
                                            @[simp]
                                            theorem BilinForm.linMulLin_compRight {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {f : M₂ →ₗ[R₂] R₂} {g : M₂ →ₗ[R₂] R₂} (r : M₂ →ₗ[R₂] M₂) :
                                            def BilinForm.IsOrtho {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (x : M) (y : M) :

                                            The proposition that two elements of a bilinear form space are orthogonal. For orthogonality of an indexed set of elements, use BilinForm.iIsOrtho.

                                            Equations
                                            Instances For
                                              theorem BilinForm.isOrtho_def {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {x : M} {y : M} :
                                              theorem BilinForm.isOrtho_zero_left {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (x : M) :
                                              theorem BilinForm.isOrtho_zero_right {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (x : M) :
                                              theorem BilinForm.ne_zero_of_not_isOrtho_self {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] {B : BilinForm K V} (x : V) (hx₁ : ¬BilinForm.IsOrtho B x x) :
                                              x 0
                                              def BilinForm.iIsOrtho {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {n : Type w} (B : BilinForm R M) (v : nM) :

                                              A set of vectors v is orthogonal with respect to some bilinear form B if and only if for all i ≠ j, B (v i) (v j) = 0. For orthogonality between two elements, use BilinForm.IsOrtho

                                              Equations
                                              Instances For
                                                theorem BilinForm.iIsOrtho_def {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {n : Type w} {B : BilinForm R M} {v : nM} :
                                                BilinForm.iIsOrtho B v ∀ (i j : n), i jBilinForm.bilin B (v i) (v j) = 0
                                                @[simp]
                                                theorem BilinForm.isOrtho_smul_left {R₄ : Type u_13} {M₄ : Type u_14} [Ring R₄] [IsDomain R₄] [AddCommGroup M₄] [Module R₄ M₄] {G : BilinForm R₄ M₄} {x : M₄} {y : M₄} {a : R₄} (ha : a 0) :
                                                @[simp]
                                                theorem BilinForm.isOrtho_smul_right {R₄ : Type u_13} {M₄ : Type u_14} [Ring R₄] [IsDomain R₄] [AddCommGroup M₄] [Module R₄ M₄] {G : BilinForm R₄ M₄} {x : M₄} {y : M₄} {a : R₄} (ha : a 0) :
                                                theorem BilinForm.linearIndependent_of_iIsOrtho {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] {n : Type w} {B : BilinForm K V} {v : nV} (hv₁ : BilinForm.iIsOrtho B v) (hv₂ : ∀ (i : n), ¬BilinForm.IsOrtho B (v i) (v i)) :

                                                A set of orthogonal vectors v with respect to some bilinear form B is linearly independent if for all i, B (v i) (v i) ≠ 0.

                                                theorem BilinForm.ext_basis {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {B₂ : BilinForm R₂ M₂} {F₂ : BilinForm R₂ M₂} {ι : Type u_13} (b : Basis ι R₂ M₂) (h : ∀ (i j : ι), BilinForm.bilin B₂ (b i) (b j) = BilinForm.bilin F₂ (b i) (b j)) :
                                                B₂ = F₂

                                                Two bilinear forms are equal when they are equal on all basis vectors.

                                                theorem BilinForm.sum_repr_mul_repr_mul {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {B₂ : BilinForm R₂ M₂} {ι : Type u_13} (b : Basis ι R₂ M₂) (x : M₂) (y : M₂) :
                                                (Finsupp.sum (b.repr x) fun i xi => Finsupp.sum (b.repr y) fun j yj => xi yj BilinForm.bilin B₂ (b i) (b j)) = BilinForm.bilin B₂ x y

                                                Write out B x y as a sum over B (b i) (b j) if b is a basis.

                                                Reflexivity, symmetry, and alternativity #

                                                def BilinForm.IsRefl {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) :

                                                The proposition that a bilinear form is reflexive

                                                Equations
                                                Instances For
                                                  theorem BilinForm.IsRefl.eq_zero {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (H : BilinForm.IsRefl B) {x : M} {y : M} :
                                                  BilinForm.bilin B x y = 0BilinForm.bilin B y x = 0
                                                  theorem BilinForm.IsRefl.ortho_comm {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (H : BilinForm.IsRefl B) {x : M} {y : M} :
                                                  theorem BilinForm.IsRefl.neg {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B : BilinForm R₁ M₁} (hB : BilinForm.IsRefl B) :
                                                  theorem BilinForm.IsRefl.smul {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {α : Type u_13} [Semiring α] [Module α R] [SMulCommClass α R R] [NoZeroSMulDivisors α R] (a : α) {B : BilinForm R M} (hB : BilinForm.IsRefl B) :
                                                  theorem BilinForm.IsRefl.groupSMul {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {α : Type u_13} [Group α] [DistribMulAction α R] [SMulCommClass α R R] (a : α) {B : BilinForm R M} (hB : BilinForm.IsRefl B) :
                                                  @[simp]
                                                  theorem BilinForm.isRefl_zero {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :
                                                  @[simp]
                                                  theorem BilinForm.isRefl_neg {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B : BilinForm R₁ M₁} :
                                                  def BilinForm.IsSymm {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) :

                                                  The proposition that a bilinear form is symmetric

                                                  Equations
                                                  Instances For
                                                    theorem BilinForm.IsSymm.eq {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (H : BilinForm.IsSymm B) (x : M) (y : M) :
                                                    theorem BilinForm.IsSymm.isRefl {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (H : BilinForm.IsSymm B) :
                                                    theorem BilinForm.IsSymm.ortho_comm {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (H : BilinForm.IsSymm B) {x : M} {y : M} :
                                                    theorem BilinForm.IsSymm.add {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B₁ : BilinForm R M} {B₂ : BilinForm R M} (hB₁ : BilinForm.IsSymm B₁) (hB₂ : BilinForm.IsSymm B₂) :
                                                    BilinForm.IsSymm (B₁ + B₂)
                                                    theorem BilinForm.IsSymm.sub {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B₁ : BilinForm R₁ M₁} {B₂ : BilinForm R₁ M₁} (hB₁ : BilinForm.IsSymm B₁) (hB₂ : BilinForm.IsSymm B₂) :
                                                    BilinForm.IsSymm (B₁ - B₂)
                                                    theorem BilinForm.IsSymm.neg {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B : BilinForm R₁ M₁} (hB : BilinForm.IsSymm B) :
                                                    theorem BilinForm.IsSymm.smul {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {α : Type u_13} [Monoid α] [DistribMulAction α R] [SMulCommClass α R R] (a : α) {B : BilinForm R M} (hB : BilinForm.IsSymm B) :
                                                    @[simp]
                                                    theorem BilinForm.isSymm_zero {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :
                                                    @[simp]
                                                    theorem BilinForm.isSymm_neg {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B : BilinForm R₁ M₁} :
                                                    theorem BilinForm.isSymm_iff_flip {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (R₂ : Type u_5) [CommSemiring R₂] {B : BilinForm R M} [Algebra R₂ R] :
                                                    def BilinForm.IsAlt {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) :

                                                    The proposition that a bilinear form is alternating

                                                    Equations
                                                    Instances For
                                                      theorem BilinForm.IsAlt.self_eq_zero {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} (H : BilinForm.IsAlt B) (x : M) :
                                                      theorem BilinForm.IsAlt.neg_eq {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B₁ : BilinForm R₁ M₁} (H : BilinForm.IsAlt B₁) (x : M₁) (y : M₁) :
                                                      theorem BilinForm.IsAlt.isRefl {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B₁ : BilinForm R₁ M₁} (H : BilinForm.IsAlt B₁) :
                                                      theorem BilinForm.IsAlt.ortho_comm {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B₁ : BilinForm R₁ M₁} (H : BilinForm.IsAlt B₁) {x : M₁} {y : M₁} :
                                                      theorem BilinForm.IsAlt.add {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B₁ : BilinForm R M} {B₂ : BilinForm R M} (hB₁ : BilinForm.IsAlt B₁) (hB₂ : BilinForm.IsAlt B₂) :
                                                      BilinForm.IsAlt (B₁ + B₂)
                                                      theorem BilinForm.IsAlt.sub {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B₁ : BilinForm R₁ M₁} {B₂ : BilinForm R₁ M₁} (hB₁ : BilinForm.IsAlt B₁) (hB₂ : BilinForm.IsAlt B₂) :
                                                      BilinForm.IsAlt (B₁ - B₂)
                                                      theorem BilinForm.IsAlt.neg {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B : BilinForm R₁ M₁} (hB : BilinForm.IsAlt B) :
                                                      theorem BilinForm.IsAlt.smul {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {α : Type u_13} [Monoid α] [DistribMulAction α R] [SMulCommClass α R R] (a : α) {B : BilinForm R M} (hB : BilinForm.IsAlt B) :
                                                      @[simp]
                                                      theorem BilinForm.isAlt_zero {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] :
                                                      @[simp]
                                                      theorem BilinForm.isAlt_neg {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B : BilinForm R₁ M₁} :

                                                      Linear adjoints #

                                                      def BilinForm.IsAdjointPair {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) {M' : Type u_13} [AddCommMonoid M'] [Module R M'] (B' : BilinForm R M') (f : M →ₗ[R] M') (g : M' →ₗ[R] M) :

                                                      Given a pair of modules equipped with bilinear forms, this is the condition for a pair of maps between them to be mutually adjoint.

                                                      Equations
                                                      Instances For
                                                        theorem BilinForm.IsAdjointPair.eq {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {M' : Type u_13} [AddCommMonoid M'] [Module R M'] {B' : BilinForm R M'} {f : M →ₗ[R] M'} {g : M' →ₗ[R] M} (h : BilinForm.IsAdjointPair B B' f g) {x : M} {y : M'} :
                                                        BilinForm.bilin B' (f x) y = BilinForm.bilin B x (g y)
                                                        theorem BilinForm.isAdjointPair_zero {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {M' : Type u_13} [AddCommMonoid M'] [Module R M'] {B' : BilinForm R M'} :
                                                        theorem BilinForm.isAdjointPair_id {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} :
                                                        theorem BilinForm.IsAdjointPair.add {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {M' : Type u_13} [AddCommMonoid M'] [Module R M'] {B' : BilinForm R M'} {f : M →ₗ[R] M'} {f' : M →ₗ[R] M'} {g : M' →ₗ[R] M} {g' : M' →ₗ[R] M} (h : BilinForm.IsAdjointPair B B' f g) (h' : BilinForm.IsAdjointPair B B' f' g') :
                                                        BilinForm.IsAdjointPair B B' (f + f') (g + g')
                                                        theorem BilinForm.IsAdjointPair.sub {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] {B₁ : BilinForm R₁ M₁} {M₁' : Type u_14} [AddCommGroup M₁'] [Module R₁ M₁'] {B₁' : BilinForm R₁ M₁'} {f₁ : M₁ →ₗ[R₁] M₁'} {f₁' : M₁ →ₗ[R₁] M₁'} {g₁ : M₁' →ₗ[R₁] M₁} {g₁' : M₁' →ₗ[R₁] M₁} (h : BilinForm.IsAdjointPair B₁ B₁' f₁ g₁) (h' : BilinForm.IsAdjointPair B₁ B₁' f₁' g₁') :
                                                        BilinForm.IsAdjointPair B₁ B₁' (f₁ - f₁') (g₁ - g₁')
                                                        theorem BilinForm.IsAdjointPair.smul {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {B₂ : BilinForm R₂ M₂} {M₂' : Type u_11} [AddCommMonoid M₂'] [Module R₂ M₂'] {B₂' : BilinForm R₂ M₂'} {f₂ : M₂ →ₗ[R₂] M₂'} {g₂ : M₂' →ₗ[R₂] M₂} (c : R₂) (h : BilinForm.IsAdjointPair B₂ B₂' f₂ g₂) :
                                                        BilinForm.IsAdjointPair B₂ B₂' (c f₂) (c g₂)
                                                        theorem BilinForm.IsAdjointPair.comp {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {M' : Type u_13} [AddCommMonoid M'] [Module R M'] {B' : BilinForm R M'} {f : M →ₗ[R] M'} {g : M' →ₗ[R] M} {M'' : Type u_15} [AddCommMonoid M''] [Module R M''] (B'' : BilinForm R M'') {f' : M' →ₗ[R] M''} {g' : M'' →ₗ[R] M'} (h : BilinForm.IsAdjointPair B B' f g) (h' : BilinForm.IsAdjointPair B' B'' f' g') :
                                                        theorem BilinForm.IsAdjointPair.mul {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {f : Module.End R M} {g : Module.End R M} {f' : Module.End R M} {g' : Module.End R M} (h : BilinForm.IsAdjointPair B B f g) (h' : BilinForm.IsAdjointPair B B f' g') :
                                                        BilinForm.IsAdjointPair B B (f * f') (g' * g)
                                                        def BilinForm.IsPairSelfAdjoint {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (F : BilinForm R M) (f : Module.End R M) :

                                                        The condition for an endomorphism to be "self-adjoint" with respect to a pair of bilinear forms on the underlying module. In the case that these two forms are identical, this is the usual concept of self adjointness. In the case that one of the forms is the negation of the other, this is the usual concept of skew adjointness.

                                                        Equations
                                                        Instances For
                                                          def BilinForm.isPairSelfAdjointSubmodule {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] (B₂ : BilinForm R₂ M₂) (F₂ : BilinForm R₂ M₂) :
                                                          Submodule R₂ (Module.End R₂ M₂)

                                                          The set of pair-self-adjoint endomorphisms are a submodule of the type of all endomorphisms.

                                                          Equations
                                                          • One or more equations did not get rendered due to their size.
                                                          Instances For
                                                            @[simp]
                                                            theorem BilinForm.mem_isPairSelfAdjointSubmodule {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] (B₂ : BilinForm R₂ M₂) (F₂ : BilinForm R₂ M₂) (f : Module.End R₂ M₂) :
                                                            theorem BilinForm.isPairSelfAdjoint_equiv {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] (B₂ : BilinForm R₂ M₂) {M₂' : Type u_11} [AddCommMonoid M₂'] [Module R₂ M₂'] (F₂ : BilinForm R₂ M₂) (e : M₂' ≃ₗ[R₂] M₂) (f : Module.End R₂ M₂) :
                                                            def BilinForm.IsSelfAdjoint {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (f : Module.End R M) :

                                                            An endomorphism of a module is self-adjoint with respect to a bilinear form if it serves as an adjoint for itself.

                                                            Equations
                                                            Instances For
                                                              def BilinForm.IsSkewAdjoint {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] (B₁ : BilinForm R₁ M₁) (f : Module.End R₁ M₁) :

                                                              An endomorphism of a module is skew-adjoint with respect to a bilinear form if its negation serves as an adjoint.

                                                              Equations
                                                              Instances For
                                                                theorem BilinForm.isSkewAdjoint_iff_neg_self_adjoint {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] (B₁ : BilinForm R₁ M₁) (f : Module.End R₁ M₁) :
                                                                def BilinForm.selfAdjointSubmodule {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] (B₂ : BilinForm R₂ M₂) :
                                                                Submodule R₂ (Module.End R₂ M₂)

                                                                The set of self-adjoint endomorphisms of a module with bilinear form is a submodule. (In fact it is a Jordan subalgebra.)

                                                                Equations
                                                                Instances For
                                                                  @[simp]
                                                                  theorem BilinForm.mem_selfAdjointSubmodule {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] (B₂ : BilinForm R₂ M₂) (f : Module.End R₂ M₂) :
                                                                  def BilinForm.skewAdjointSubmodule {R₃ : Type u_7} {M₃ : Type u_8} [CommRing R₃] [AddCommGroup M₃] [Module R₃ M₃] (B₃ : BilinForm R₃ M₃) :
                                                                  Submodule R₃ (Module.End R₃ M₃)

                                                                  The set of skew-adjoint endomorphisms of a module with bilinear form is a submodule. (In fact it is a Lie subalgebra.)

                                                                  Equations
                                                                  Instances For
                                                                    @[simp]
                                                                    theorem BilinForm.mem_skewAdjointSubmodule {R₃ : Type u_7} {M₃ : Type u_8} [CommRing R₃] [AddCommGroup M₃] [Module R₃ M₃] (B₃ : BilinForm R₃ M₃) (f : Module.End R₃ M₃) :
                                                                    def BilinForm.orthogonal {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (N : Submodule R M) :

                                                                    The orthogonal complement of a submodule N with respect to some bilinear form is the set of elements x which are orthogonal to all elements of N; i.e., for all y in N, B x y = 0.

                                                                    Note that for general (neither symmetric nor antisymmetric) bilinear forms this definition has a chirality; in addition to this "left" orthogonal complement one could define a "right" orthogonal complement for which, for all y in N, B y x = 0. This variant definition is not currently provided in mathlib.

                                                                    Equations
                                                                    • One or more equations did not get rendered due to their size.
                                                                    Instances For
                                                                      @[simp]
                                                                      theorem BilinForm.mem_orthogonal_iff {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {N : Submodule R M} {m : M} :
                                                                      m BilinForm.orthogonal B N ∀ (n : M), n NBilinForm.IsOrtho B n m
                                                                      theorem BilinForm.orthogonal_le {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {B : BilinForm R M} {N : Submodule R M} {L : Submodule R M} (h : N L) :
                                                                      theorem BilinForm.orthogonal_span_singleton_eq_toLin_ker {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] {B : BilinForm K V} (x : V) :
                                                                      BilinForm.orthogonal B (Submodule.span K {x}) = LinearMap.ker (↑(BilinForm.toLin B) x)
                                                                      theorem BilinForm.isCompl_span_singleton_orthogonal {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] {B : BilinForm K V} {x : V} (hx : ¬BilinForm.IsOrtho B x x) :

                                                                      Given a bilinear form B and some x such that B x x ≠ 0, the span of the singleton of x is complement to its orthogonal complement.

                                                                      @[simp]
                                                                      theorem BilinForm.restrict_apply {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (W : Submodule R M) (a : { x // x W }) (b : { x // x W }) :
                                                                      def BilinForm.restrict {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (W : Submodule R M) :
                                                                      BilinForm R { x // x W }

                                                                      The restriction of a bilinear form on a submodule.

                                                                      Equations
                                                                      • One or more equations did not get rendered due to their size.
                                                                      Instances For
                                                                        theorem BilinForm.restrictSymm {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) (b : BilinForm.IsSymm B) (W : Submodule R M) :

                                                                        The restriction of a symmetric bilinear form on a submodule is also symmetric.

                                                                        def BilinForm.Nondegenerate {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] (B : BilinForm R M) :

                                                                        A nondegenerate bilinear form is a bilinear form such that the only element that is orthogonal to every other element is 0; i.e., for all nonzero m in M, there exists n in M with B m n ≠ 0.

                                                                        Note that for general (neither symmetric nor antisymmetric) bilinear forms this definition has a chirality; in addition to this "left" nondegeneracy condition one could define a "right" nondegeneracy condition that in the situation described, B n m ≠ 0. This variant definition is not currently provided in mathlib. In finite dimension either definition implies the other.

                                                                        Equations
                                                                        Instances For

                                                                          In a non-trivial module, zero is not non-degenerate.

                                                                          theorem BilinForm.Nondegenerate.ne_zero {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] [Nontrivial M] {B : BilinForm R M} (h : BilinForm.Nondegenerate B) :
                                                                          B 0
                                                                          theorem BilinForm.Nondegenerate.congr {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {M₂' : Type u_11} [AddCommMonoid M₂'] [Module R₂ M₂'] {B : BilinForm R₂ M₂} (e : M₂ ≃ₗ[R₂] M₂') (h : BilinForm.Nondegenerate B) :
                                                                          @[simp]
                                                                          theorem BilinForm.nondegenerate_congr_iff {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {M₂' : Type u_11} [AddCommMonoid M₂'] [Module R₂ M₂'] {B : BilinForm R₂ M₂} (e : M₂ ≃ₗ[R₂] M₂') :
                                                                          theorem BilinForm.nondegenerate_iff_ker_eq_bot {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {B : BilinForm R₂ M₂} :
                                                                          BilinForm.Nondegenerate B LinearMap.ker (BilinForm.toLin B) =

                                                                          A bilinear form is nondegenerate if and only if it has a trivial kernel.

                                                                          theorem BilinForm.Nondegenerate.ker_eq_bot {R₂ : Type u_5} {M₂ : Type u_6} [CommSemiring R₂] [AddCommMonoid M₂] [Module R₂ M₂] {B : BilinForm R₂ M₂} (h : BilinForm.Nondegenerate B) :
                                                                          LinearMap.ker (BilinForm.toLin B) =
                                                                          theorem BilinForm.nondegenerateRestrictOfDisjointOrthogonal {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] (B : BilinForm R₁ M₁) (b : BilinForm.IsRefl B) {W : Submodule R₁ M₁} (hW : Disjoint W (BilinForm.orthogonal B W)) :

                                                                          The restriction of a reflexive bilinear form B onto a submodule W is nondegenerate if Disjoint W (B.orthogonal W).

                                                                          theorem BilinForm.iIsOrtho.not_isOrtho_basis_self_of_nondegenerate {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {n : Type w} [Nontrivial R] {B : BilinForm R M} {v : Basis n R M} (h : BilinForm.iIsOrtho B v) (hB : BilinForm.Nondegenerate B) (i : n) :
                                                                          ¬BilinForm.IsOrtho B (v i) (v i)

                                                                          An orthogonal basis with respect to a nondegenerate bilinear form has no self-orthogonal elements.

                                                                          theorem BilinForm.iIsOrtho.nondegenerate_iff_not_isOrtho_basis_self {R : Type u_1} {M : Type u_2} [Semiring R] [AddCommMonoid M] [Module R M] {n : Type w} [Nontrivial R] [NoZeroDivisors R] (B : BilinForm R M) (v : Basis n R M) (hO : BilinForm.iIsOrtho B v) :
                                                                          BilinForm.Nondegenerate B ∀ (i : n), ¬BilinForm.IsOrtho B (v i) (v i)

                                                                          Given an orthogonal basis with respect to a bilinear form, the bilinear form is nondegenerate iff the basis has no elements which are self-orthogonal.

                                                                          A subspace is complement to its orthogonal complement with respect to some reflexive bilinear form if that bilinear form restricted on to the subspace is nondegenerate.

                                                                          A subspace is complement to its orthogonal complement with respect to some reflexive bilinear form if and only if that bilinear form restricted on to the subspace is nondegenerate.

                                                                          noncomputable def BilinForm.toDual {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] [FiniteDimensional K V] (B : BilinForm K V) (b : BilinForm.Nondegenerate B) :

                                                                          Given a nondegenerate bilinear form B on a finite-dimensional vector space, B.toDual is the linear equivalence between a vector space and its dual with the underlying linear map B.toLin.

                                                                          Equations
                                                                          • One or more equations did not get rendered due to their size.
                                                                          Instances For
                                                                            theorem BilinForm.toDual_def {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] [FiniteDimensional K V] {B : BilinForm K V} (b : BilinForm.Nondegenerate B) {m : V} {n : V} :
                                                                            ↑(↑(BilinForm.toDual B b) m) n = BilinForm.bilin B m n
                                                                            noncomputable def BilinForm.dualBasis {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] [FiniteDimensional K V] {ι : Type u_12} [DecidableEq ι] [Fintype ι] (B : BilinForm K V) (hB : BilinForm.Nondegenerate B) (b : Basis ι K V) :
                                                                            Basis ι K V

                                                                            The B-dual basis B.dualBasis hB b to a finite basis b satisfies B (B.dualBasis hB b i) (b j) = B (b i) (B.dualBasis hB b j) = if i = j then 1 else 0, where B is a nondegenerate (symmetric) bilinear form and b is a finite basis.

                                                                            Equations
                                                                            Instances For
                                                                              @[simp]
                                                                              theorem BilinForm.dualBasis_repr_apply {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] [FiniteDimensional K V] {ι : Type u_12} [DecidableEq ι] [Fintype ι] (B : BilinForm K V) (hB : BilinForm.Nondegenerate B) (b : Basis ι K V) (x : V) (i : ι) :
                                                                              ↑((BilinForm.dualBasis B hB b).repr x) i = BilinForm.bilin B x (b i)
                                                                              theorem BilinForm.apply_dualBasis_left {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] [FiniteDimensional K V] {ι : Type u_12} [DecidableEq ι] [Fintype ι] (B : BilinForm K V) (hB : BilinForm.Nondegenerate B) (b : Basis ι K V) (i : ι) (j : ι) :
                                                                              BilinForm.bilin B (↑(BilinForm.dualBasis B hB b) i) (b j) = if j = i then 1 else 0
                                                                              theorem BilinForm.apply_dualBasis_right {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] [FiniteDimensional K V] {ι : Type u_12} [DecidableEq ι] [Fintype ι] (B : BilinForm K V) (hB : BilinForm.Nondegenerate B) (sym : BilinForm.IsSymm B) (b : Basis ι K V) (i : ι) (j : ι) :
                                                                              BilinForm.bilin B (b i) (↑(BilinForm.dualBasis B hB b) j) = if i = j then 1 else 0

                                                                              We note that we cannot use BilinForm.restrict_nondegenerate_iff_isCompl_orthogonal for the lemma below since the below lemma does not require V to be finite dimensional. However, BilinForm.restrict_nondegenerate_iff_isCompl_orthogonal does not require B to be nondegenerate on the whole space.

                                                                              The restriction of a reflexive, non-degenerate bilinear form on the orthogonal complement of the span of a singleton is also non-degenerate.

                                                                              theorem BilinForm.compLeft_injective {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] (B : BilinForm R₁ M₁) (b : BilinForm.Nondegenerate B) :
                                                                              theorem BilinForm.isAdjointPair_unique_of_nondegenerate {R₁ : Type u_3} {M₁ : Type u_4} [Ring R₁] [AddCommGroup M₁] [Module R₁ M₁] (B : BilinForm R₁ M₁) (b : BilinForm.Nondegenerate B) (φ : M₁ →ₗ[R₁] M₁) (ψ₁ : M₁ →ₗ[R₁] M₁) (ψ₂ : M₁ →ₗ[R₁] M₁) (hψ₁ : BilinForm.IsAdjointPair B B ψ₁ φ) (hψ₂ : BilinForm.IsAdjointPair B B ψ₂ φ) :
                                                                              ψ₁ = ψ₂
                                                                              noncomputable def BilinForm.symmCompOfNondegenerate {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] [FiniteDimensional K V] (B₁ : BilinForm K V) (B₂ : BilinForm K V) (b₂ : BilinForm.Nondegenerate B₂) :

                                                                              Given bilinear forms B₁, B₂ where B₂ is nondegenerate, symmCompOfNondegenerate is the linear map B₂.toLin⁻¹ ∘ B₁.toLin.

                                                                              Equations
                                                                              Instances For
                                                                                theorem BilinForm.comp_symmCompOfNondegenerate_apply {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] [FiniteDimensional K V] (B₁ : BilinForm K V) {B₂ : BilinForm K V} (b₂ : BilinForm.Nondegenerate B₂) (v : V) :
                                                                                ↑(BilinForm.toLin B₂) (↑(BilinForm.symmCompOfNondegenerate B₁ B₂ b₂) v) = ↑(BilinForm.toLin B₁) v
                                                                                @[simp]
                                                                                theorem BilinForm.symmCompOfNondegenerate_left_apply {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] [FiniteDimensional K V] (B₁ : BilinForm K V) {B₂ : BilinForm K V} (b₂ : BilinForm.Nondegenerate B₂) (v : V) (w : V) :
                                                                                BilinForm.bilin B₂ (↑(BilinForm.symmCompOfNondegenerate B₁ B₂ b₂) w) v = BilinForm.bilin B₁ w v
                                                                                noncomputable def BilinForm.leftAdjointOfNondegenerate {V : Type u_9} {K : Type u_10} [Field K] [AddCommGroup V] [Module K V] [FiniteDimensional K V] (B : BilinForm K V) (b : BilinForm.Nondegenerate B) (φ : V →ₗ[K] V) :

                                                                                Given the nondegenerate bilinear form B and the linear map φ, leftAdjointOfNondegenerate provides the left adjoint of φ with respect to B. The lemma proving this property is BilinForm.isAdjointPairLeftAdjointOfNondegenerate.

                                                                                Equations
                                                                                Instances For

                                                                                  Given the nondegenerate bilinear form B, the linear map φ has a unique left adjoint given by BilinForm.leftAdjointOfNondegenerate.