Documentation

Mathlib.Algebra.DirectSum.Module

Direct sum of modules #

The first part of the file provides constructors for direct sums of modules. It provides a construction of the direct sum using the universal property and proves its uniqueness (DirectSum.toModule.unique).

The second part of the file covers the special case of direct sums of submodules of a fixed module M. There is a canonical linear map from this direct sum to M (DirectSum.coeLinearMap), and the construction is of particular importance when this linear map is an equivalence; that is, when the submodules provide an internal decomposition of M. The property is defined more generally elsewhere as DirectSum.IsInternal, but its basic consequences on Submodules are established in this file.

instance DirectSum.instModule {R : Type u} [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] :
Module R (DirectSum ι fun (i : ι) => M i)
Equations
  • DirectSum.instModule = DFinsupp.module
instance DirectSum.instSMulCommClass {R : Type u} [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] {S : Type u_1} [Semiring S] [(i : ι) → Module S (M i)] [∀ (i : ι), SMulCommClass R S (M i)] :
SMulCommClass R S (DirectSum ι fun (i : ι) => M i)
Equations
  • =
instance DirectSum.instIsScalarTower {R : Type u} [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] {S : Type u_1} [Semiring S] [SMul R S] [(i : ι) → Module S (M i)] [∀ (i : ι), IsScalarTower R S (M i)] :
IsScalarTower R S (DirectSum ι fun (i : ι) => M i)
Equations
  • =
instance DirectSum.instIsCentralScalar {R : Type u} [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [(i : ι) → Module Rᵐᵒᵖ (M i)] [∀ (i : ι), IsCentralScalar R (M i)] :
IsCentralScalar R (DirectSum ι fun (i : ι) => M i)
Equations
  • =
theorem DirectSum.smul_apply {R : Type u} [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] (b : R) (v : DirectSum ι fun (i : ι) => M i) (i : ι) :
(b v) i = b v i
def DirectSum.lmk (R : Type u) [Semiring R] (ι : Type v) (M : ιType w) [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (s : Finset ι) :
((i : s) → M i) →ₗ[R] DirectSum ι fun (i : ι) => M i

Create the direct sum given a family M of R modules indexed over ι.

Equations
Instances For
    def DirectSum.lof (R : Type u) [Semiring R] (ι : Type v) (M : ιType w) [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (i : ι) :
    M i →ₗ[R] DirectSum ι fun (i : ι) => M i

    Inclusion of each component into the direct sum.

    Equations
    Instances For
      theorem DirectSum.lof_eq_of (R : Type u) [Semiring R] (ι : Type v) (M : ιType w) [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (i : ι) (b : M i) :
      (DirectSum.lof R ι M i) b = (DirectSum.of M i) b
      theorem DirectSum.single_eq_lof (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (i : ι) (b : M i) :
      theorem DirectSum.mk_smul (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (s : Finset ι) (c : R) (x : (i : s) → M i) :
      (DirectSum.mk M s) (c x) = c (DirectSum.mk M s) x

      Scalar multiplication commutes with direct sums.

      theorem DirectSum.of_smul (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (i : ι) (c : R) (x : M i) :
      (DirectSum.of M i) (c x) = c (DirectSum.of M i) x

      Scalar multiplication commutes with the inclusion of each component into the direct sum.

      theorem DirectSum.support_smul {R : Type u} [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] [(i : ι) → (x : M i) → Decidable (x 0)] (c : R) (v : DirectSum ι fun (i : ι) => M i) :
      def DirectSum.toModule (R : Type u) [Semiring R] (ι : Type v) {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (N : Type u₁) [AddCommMonoid N] [Module R N] (φ : (i : ι) → M i →ₗ[R] N) :
      (DirectSum ι fun (i : ι) => M i) →ₗ[R] N

      The linear map constructed using the universal property of the coproduct.

      Equations
      Instances For
        theorem DirectSum.coe_toModule_eq_coe_toAddMonoid (R : Type u) [Semiring R] (ι : Type v) {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (N : Type u₁) [AddCommMonoid N] [Module R N] (φ : (i : ι) → M i →ₗ[R] N) :
        (DirectSum.toModule R ι N φ) = (DirectSum.toAddMonoid fun (i : ι) => (φ i).toAddMonoidHom)

        Coproducts in the categories of modules and additive monoids commute with the forgetful functor from modules to additive monoids.

        @[simp]
        theorem DirectSum.toModule_lof (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] {N : Type u₁} [AddCommMonoid N] [Module R N] {φ : (i : ι) → M i →ₗ[R] N} (i : ι) (x : M i) :
        (DirectSum.toModule R ι N φ) ((DirectSum.lof R ι M i) x) = (φ i) x

        The map constructed using the universal property gives back the original maps when restricted to each component.

        theorem DirectSum.toModule.unique (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] {N : Type u₁} [AddCommMonoid N] [Module R N] (ψ : (DirectSum ι fun (i : ι) => M i) →ₗ[R] N) (f : DirectSum ι fun (i : ι) => M i) :
        ψ f = (DirectSum.toModule R ι N fun (i : ι) => ψ ∘ₗ DirectSum.lof R ι M i) f

        Every linear map from a direct sum agrees with the one obtained by applying the universal property to each of its components.

        theorem DirectSum.linearMap_ext_iff {R : Type u} [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] {N : Type u₁} [AddCommMonoid N] [Module R N] {ψ : (DirectSum ι fun (i : ι) => M i) →ₗ[R] N} {ψ' : (DirectSum ι fun (i : ι) => M i) →ₗ[R] N} :
        ψ = ψ' ∀ (i : ι), ψ ∘ₗ DirectSum.lof R ι M i = ψ' ∘ₗ DirectSum.lof R ι M i
        theorem DirectSum.linearMap_ext (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] {N : Type u₁} [AddCommMonoid N] [Module R N] ⦃ψ : (DirectSum ι fun (i : ι) => M i) →ₗ[R] N ⦃ψ' : (DirectSum ι fun (i : ι) => M i) →ₗ[R] N (H : ∀ (i : ι), ψ ∘ₗ DirectSum.lof R ι M i = ψ' ∘ₗ DirectSum.lof R ι M i) :
        ψ = ψ'

        Two LinearMaps out of a direct sum are equal if they agree on the generators.

        See note [partially-applied ext lemmas].

        def DirectSum.lsetToSet (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (S : Set ι) (T : Set ι) (H : S T) :
        (DirectSum S fun (i : S) => M i) →ₗ[R] DirectSum T fun (i : T) => M i

        The inclusion of a subset of the direct summands into a larger subset of the direct summands, as a linear map.

        Equations
        Instances For
          @[simp]
          theorem DirectSum.linearEquivFunOnFintype_apply (R : Type u) [Semiring R] (ι : Type v) (M : ιType w) [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [Fintype ι] :
          ∀ (a : Π₀ (i : ι), (fun (i : ι) => M i) i) (a_1 : ι), (DirectSum.linearEquivFunOnFintype R ι M) a a_1 = a a_1
          def DirectSum.linearEquivFunOnFintype (R : Type u) [Semiring R] (ι : Type v) (M : ιType w) [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [Fintype ι] :
          (DirectSum ι fun (i : ι) => M i) ≃ₗ[R] (i : ι) → M i

          Given Fintype α, linearEquivFunOnFintype R is the natural R-linear equivalence between ⨁ i, M i and ∀ i, M i.

          Equations
          • DirectSum.linearEquivFunOnFintype R ι M = { toFun := DFunLike.coe, map_add' := , map_smul' := , invFun := DFinsupp.equivFunOnFintype.invFun, left_inv := , right_inv := }
          Instances For
            @[simp]
            theorem DirectSum.linearEquivFunOnFintype_lof (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] [Fintype ι] (i : ι) (m : M i) :
            @[simp]
            theorem DirectSum.linearEquivFunOnFintype_symm_single (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] [Fintype ι] (i : ι) (m : M i) :
            @[simp]
            theorem DirectSum.linearEquivFunOnFintype_symm_coe (R : Type u) [Semiring R] (ι : Type v) (M : ιType w) [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [Fintype ι] (f : DirectSum ι fun (i : ι) => M i) :
            def DirectSum.lid (R : Type u) [Semiring R] (M : Type v) (ι : optParam (Type u_1) PUnit.{u_1 + 1} ) [AddCommMonoid M] [Module R M] [Unique ι] :
            (DirectSum ι fun (x : ι) => M) ≃ₗ[R] M

            The natural linear equivalence between ⨁ _ : ι, M and M when Unique ι.

            Equations
            Instances For
              def DirectSum.component (R : Type u) [Semiring R] (ι : Type v) (M : ιType w) [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] (i : ι) :
              (DirectSum ι fun (i : ι) => M i) →ₗ[R] M i

              The projection map onto one component, as a linear map.

              Equations
              Instances For
                theorem DirectSum.apply_eq_component (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] (f : DirectSum ι fun (i : ι) => M i) (i : ι) :
                f i = (DirectSum.component R ι M i) f
                theorem DirectSum.ext (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] {f : DirectSum ι fun (i : ι) => M i} {g : DirectSum ι fun (i : ι) => M i} (h : ∀ (i : ι), (DirectSum.component R ι M i) f = (DirectSum.component R ι M i) g) :
                f = g
                theorem DirectSum.ext_iff (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] {f : DirectSum ι fun (i : ι) => M i} {g : DirectSum ι fun (i : ι) => M i} :
                f = g ∀ (i : ι), (DirectSum.component R ι M i) f = (DirectSum.component R ι M i) g
                @[simp]
                theorem DirectSum.lof_apply (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (i : ι) (b : M i) :
                ((DirectSum.lof R ι M i) b) i = b
                @[simp]
                theorem DirectSum.component.lof_self (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (i : ι) (b : M i) :
                (DirectSum.component R ι M i) ((DirectSum.lof R ι M i) b) = b
                theorem DirectSum.component.of (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] [DecidableEq ι] (i : ι) (j : ι) (b : M j) :
                (DirectSum.component R ι M i) ((DirectSum.lof R ι M j) b) = if h : j = i then Eq.recOn h b else 0
                def DirectSum.lequivCongrLeft (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] {κ : Type u_1} (h : ι κ) :
                (DirectSum ι fun (i : ι) => M i) ≃ₗ[R] DirectSum κ fun (k : κ) => M (h.symm k)

                Reindexing terms of a direct sum is linear.

                Equations
                Instances For
                  @[simp]
                  theorem DirectSum.lequivCongrLeft_apply (R : Type u) [Semiring R] {ι : Type v} {M : ιType w} [(i : ι) → AddCommMonoid (M i)] [(i : ι) → Module R (M i)] {κ : Type u_1} (h : ι κ) (f : DirectSum ι fun (i : ι) => M i) (k : κ) :
                  ((DirectSum.lequivCongrLeft R h) f) k = f (h.symm k)
                  def DirectSum.sigmaLcurry (R : Type u) [Semiring R] {ι : Type v} {α : ιType u_1} {δ : (i : ι) → α iType w} [DecidableEq ι] [(i : ι) → (j : α i) → AddCommMonoid (δ i j)] [(i : ι) → (j : α i) → Module R (δ i j)] :
                  (DirectSum ((x : ι) × α x) fun (i : (x : ι) × α x) => δ i.fst i.snd) →ₗ[R] DirectSum ι fun (i : ι) => DirectSum (α i) fun (j : α i) => δ i j

                  curry as a linear map.

                  Equations
                  Instances For
                    @[simp]
                    theorem DirectSum.sigmaLcurry_apply (R : Type u) [Semiring R] {ι : Type v} {α : ιType u_1} {δ : (i : ι) → α iType w} [DecidableEq ι] [(i : ι) → (j : α i) → AddCommMonoid (δ i j)] [(i : ι) → (j : α i) → Module R (δ i j)] (f : DirectSum ((x : ι) × α x) fun (i : (x : ι) × α x) => δ i.fst i.snd) (i : ι) (j : α i) :
                    (((DirectSum.sigmaLcurry R) f) i) j = f i, j
                    def DirectSum.sigmaLuncurry (R : Type u) [Semiring R] {ι : Type v} {α : ιType u_1} {δ : (i : ι) → α iType w} [DecidableEq ι] [(i : ι) → (j : α i) → AddCommMonoid (δ i j)] [(i : ι) → (j : α i) → Module R (δ i j)] :
                    (DirectSum ι fun (i : ι) => DirectSum (α i) fun (j : α i) => δ i j) →ₗ[R] DirectSum ((x : ι) × α x) fun (i : (x : ι) × α x) => δ i.fst i.snd

                    uncurry as a linear map.

                    Equations
                    Instances For
                      @[simp]
                      theorem DirectSum.sigmaLuncurry_apply (R : Type u) [Semiring R] {ι : Type v} {α : ιType u_1} {δ : (i : ι) → α iType w} [DecidableEq ι] [(i : ι) → (j : α i) → AddCommMonoid (δ i j)] [(i : ι) → (j : α i) → Module R (δ i j)] (f : DirectSum ι fun (i : ι) => DirectSum (α i) fun (j : α i) => δ i j) (i : ι) (j : α i) :
                      ((DirectSum.sigmaLuncurry R) f) i, j = (f i) j
                      def DirectSum.sigmaLcurryEquiv (R : Type u) [Semiring R] {ι : Type v} {α : ιType u_1} {δ : (i : ι) → α iType w} [DecidableEq ι] [(i : ι) → (j : α i) → AddCommMonoid (δ i j)] [(i : ι) → (j : α i) → Module R (δ i j)] :
                      (DirectSum ((x : ι) × α x) fun (i : (x : ι) × α x) => δ i.fst i.snd) ≃ₗ[R] DirectSum ι fun (i : ι) => DirectSum (α i) fun (j : α i) => δ i j

                      curryEquiv as a linear equiv.

                      Equations
                      • DirectSum.sigmaLcurryEquiv R = { toFun := DirectSum.sigmaCurryEquiv.toFun, map_add' := , map_smul' := , invFun := DirectSum.sigmaCurryEquiv.invFun, left_inv := , right_inv := }
                      Instances For
                        @[simp]
                        theorem DirectSum.lequivProdDirectSum_apply (R : Type u) [Semiring R] {ι : Type v} {α : Option ιType w} [(i : Option ι) → AddCommMonoid (α i)] [(i : Option ι) → Module R (α i)] :
                        ∀ (a : DirectSum (Option ι) fun (i : Option ι) => α i), (DirectSum.lequivProdDirectSum R) a = DirectSum.addEquivProdDirectSum.toFun a
                        @[simp]
                        theorem DirectSum.lequivProdDirectSum_symm_apply (R : Type u) [Semiring R] {ι : Type v} {α : Option ιType w} [(i : Option ι) → AddCommMonoid (α i)] [(i : Option ι) → Module R (α i)] :
                        ∀ (a : α none × DirectSum ι fun (i : ι) => α (some i)), (DirectSum.lequivProdDirectSum R).symm a = DirectSum.addEquivProdDirectSum.invFun a
                        noncomputable def DirectSum.lequivProdDirectSum (R : Type u) [Semiring R] {ι : Type v} {α : Option ιType w} [(i : Option ι) → AddCommMonoid (α i)] [(i : Option ι) → Module R (α i)] :
                        (DirectSum (Option ι) fun (i : Option ι) => α i) ≃ₗ[R] α none × DirectSum ι fun (i : ι) => α (some i)

                        Linear isomorphism obtained by separating the term of index none of a direct sum over Option ι.

                        Equations
                        • One or more equations did not get rendered due to their size.
                        Instances For
                          def DirectSum.coeLinearMap {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] (A : ιSubmodule R M) :
                          (DirectSum ι fun (i : ι) => (A i)) →ₗ[R] M

                          The canonical linear map from ⨁ i, A i to M where A is a collection of Submodule R M indexed by ι. This is DirectSum.coeAddMonoidHom as a LinearMap.

                          Equations
                          Instances For
                            theorem DirectSum.coeLinearMap_eq_dfinsupp_sum {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] (A : ιSubmodule R M) [DecidableEq M] (x : DirectSum ι fun (i : ι) => (A i)) :
                            (DirectSum.coeLinearMap A) x = DFinsupp.sum x fun (i : ι) (x : (A i)) => x
                            @[simp]
                            theorem DirectSum.coeLinearMap_of {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] (A : ιSubmodule R M) (i : ι) (x : (A i)) :
                            (DirectSum.coeLinearMap A) ((DirectSum.of (fun (i : ι) => (A i)) i) x) = x
                            theorem DirectSum.range_coeLinearMap {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} :
                            @[simp]
                            theorem DirectSum.IsInternal.ofBijective_coeLinearMap_same {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) {i : ι} (x : (A i)) :
                            @[simp]
                            theorem DirectSum.IsInternal.ofBijective_coeLinearMap_of_ne {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) {i : ι} {j : ι} (hij : i j) (x : (A i)) :
                            theorem DirectSum.IsInternal.ofBijective_coeLinearMap_of_mem {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) {i : ι} {x : M} (hx : x A i) :
                            ((LinearEquiv.ofBijective (DirectSum.coeLinearMap A) h).symm x) i = x, hx
                            theorem DirectSum.IsInternal.ofBijective_coeLinearMap_of_mem_ne {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) {i : ι} {j : ι} (hij : i j) {x : M} (hx : x A i) :
                            theorem DirectSum.IsInternal.submodule_iSup_eq_top {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) :

                            If a direct sum of submodules is internal then the submodules span the module.

                            theorem DirectSum.IsInternal.submodule_independent {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) :

                            If a direct sum of submodules is internal then the submodules are independent.

                            noncomputable def DirectSum.IsInternal.collectedBasis {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) {α : ιType u_2} (v : (i : ι) → Basis (α i) R (A i)) :
                            Basis ((i : ι) × α i) R M

                            Given an internal direct sum decomposition of a module M, and a basis for each of the components of the direct sum, the disjoint union of these bases is a basis for M.

                            Equations
                            • One or more equations did not get rendered due to their size.
                            Instances For
                              @[simp]
                              theorem DirectSum.IsInternal.collectedBasis_coe {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) {α : ιType u_2} (v : (i : ι) → Basis (α i) R (A i)) :
                              (h.collectedBasis v) = fun (a : (i : ι) × α i) => ((v a.fst) a.snd)
                              theorem DirectSum.IsInternal.collectedBasis_mem {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) {α : ιType u_2} (v : (i : ι) → Basis (α i) R (A i)) (a : (i : ι) × α i) :
                              (h.collectedBasis v) a A a.fst
                              theorem DirectSum.IsInternal.collectedBasis_repr_of_mem {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) {α : ιType u_2} (v : (i : ι) → Basis (α i) R (A i)) {x : M} {i : ι} {a : α i} (hx : x A i) :
                              ((h.collectedBasis v).repr x) i, a = ((v i).repr x, hx) a
                              theorem DirectSum.IsInternal.collectedBasis_repr_of_mem_ne {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} (h : DirectSum.IsInternal A) {α : ιType u_2} (v : (i : ι) → Basis (α i) R (A i)) {x : M} {i : ι} {j : ι} (hij : i j) {a : α j} (hx : x A i) :
                              ((h.collectedBasis v).repr x) j, a = 0
                              theorem DirectSum.IsInternal.isCompl {R : Type u} [Semiring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommMonoid M] [Module R M] {A : ιSubmodule R M} {i : ι} {j : ι} (hij : i j) (h : Set.univ = {i, j}) (hi : DirectSum.IsInternal A) :
                              IsCompl (A i) (A j)

                              When indexed by only two distinct elements, DirectSum.IsInternal implies the two submodules are complementary. Over a Ring R, this is true as an iff, as DirectSum.isInternal_submodule_iff_isCompl.

                              theorem DirectSum.isInternal_submodule_of_independent_of_iSup_eq_top {R : Type u} [Ring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommGroup M] [Module R M] {A : ιSubmodule R M} (hi : CompleteLattice.Independent A) (hs : iSup A = ) :

                              Note that this is not generally true for [Semiring R]; see CompleteLattice.Independent.dfinsupp_lsum_injective for details.

                              theorem DirectSum.isInternal_submodule_iff_isCompl {R : Type u} [Ring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommGroup M] [Module R M] (A : ιSubmodule R M) {i : ι} {j : ι} (hij : i j) (h : Set.univ = {i, j}) :

                              If a collection of submodules has just two indices, i and j, then DirectSum.IsInternal is equivalent to isCompl.

                              @[simp]
                              theorem DirectSum.isInternal_ne_bot_iff {R : Type u} [Ring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommGroup M] [Module R M] {A : ιSubmodule R M} :
                              (DirectSum.IsInternal fun (i : { i : ι // A i }) => A i) DirectSum.IsInternal A
                              theorem DirectSum.isInternal_biSup_submodule_of_independent {R : Type u} [Ring R] {ι : Type v} [dec_ι : DecidableEq ι] {M : Type u_1} [AddCommGroup M] [Module R M] {A : ιSubmodule R M} (s : Set ι) (h : CompleteLattice.Independent fun (i : s) => A i) :
                              DirectSum.IsInternal fun (i : s) => Submodule.comap (⨆ is, A i).subtype (A i)

                              Now copy the lemmas for subgroup and submonoids.