Documentation

Mathlib.Combinatorics.SimpleGraph.Sum

Disjoint sum of graphs #

This file defines the disjoint sum of graphs. The disjoint sum of G : SimpleGraph α and H : SimpleGraph β is a graph on α ⊕ β where u and v are adjacent if and only if they are both in G and adjacent in G, or they are both in H and adjacent in H.

Main declarations #

Notation #

def SimpleGraph.sum {α : Type u_1} {β : Type u_2} (G : SimpleGraph α) (H : SimpleGraph β) :

Disjoint sum of G and H.

Equations
  • One or more equations did not get rendered due to their size.
Instances For
    @[simp]
    theorem SimpleGraph.sum_adj {α : Type u_1} {β : Type u_2} (G : SimpleGraph α) (H : SimpleGraph β) (x✝ x✝¹ : α β) :
    (G ⊕g H).Adj x✝ x✝¹ = match x✝, x✝¹ with | Sum.inl u, Sum.inl v => G.Adj u v | Sum.inr u, Sum.inr v => H.Adj u v | x, x_1 => False

    Disjoint sum of G and H.

    Equations
    Instances For
      def SimpleGraph.Iso.sumComm {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} :
      G ⊕g H ≃g H ⊕g G

      The disjoint sum is commutative up to isomorphism. Iso.sumComm as a graph isomorphism.

      Equations
      Instances For
        @[simp]
        theorem SimpleGraph.Iso.sumComm_symm_apply {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} (a✝ : β α) :
        @[simp]
        theorem SimpleGraph.Iso.sumComm_apply {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} (a✝ : α β) :
        sumComm a✝ = a✝.swap
        def SimpleGraph.Iso.sumAssoc {α : Type u_1} {β : Type u_2} {γ : Type u_3} {G : SimpleGraph α} {H : SimpleGraph β} {I : SimpleGraph γ} :
        G ⊕g H ⊕g I ≃g G ⊕g (H ⊕g I)

        The disjoint sum is associative up to isomorphism. Iso.sumAssoc as a graph isomorphism.

        Equations
        Instances For
          @[simp]
          theorem SimpleGraph.Iso.sumAssoc_symm_apply {α : Type u_1} {β : Type u_2} {γ : Type u_3} {G : SimpleGraph α} {H : SimpleGraph β} {I : SimpleGraph γ} (a✝ : α β γ) :
          @[simp]
          theorem SimpleGraph.Iso.sumAssoc_apply {α : Type u_1} {β : Type u_2} {γ : Type u_3} {G : SimpleGraph α} {H : SimpleGraph β} {I : SimpleGraph γ} (a✝ : (α β) γ) :
          def SimpleGraph.Embedding.sumInl {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} :
          G ↪g G ⊕g H

          The embedding of G into G ⊕g H.

          Equations
          Instances For
            @[simp]
            theorem SimpleGraph.Embedding.sumInl_apply {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} (u : α) :
            def SimpleGraph.Embedding.sumInr {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} :
            H ↪g G ⊕g H

            The embedding of H into G ⊕g H.

            Equations
            Instances For
              @[simp]
              theorem SimpleGraph.Embedding.sumInr_apply {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} (u : β) :
              def SimpleGraph.Coloring.sum {α : Type u_1} {β : Type u_2} {γ : Type u_3} {G : SimpleGraph α} {H : SimpleGraph β} (cG : G.Coloring γ) (cH : H.Coloring γ) :
              (G ⊕g H).Coloring γ

              Color G ⊕g H with colorings of G and H

              Equations
              • cG.sum cH = { toFun := Sum.elim cG cH, map_rel' := }
              Instances For
                def SimpleGraph.Coloring.sumLeft {α : Type u_1} {β : Type u_2} {γ : Type u_3} {G : SimpleGraph α} {H : SimpleGraph β} (c : (G ⊕g H).Coloring γ) :

                Get coloring of G from coloring of G ⊕g H

                Equations
                Instances For
                  def SimpleGraph.Coloring.sumRight {α : Type u_1} {β : Type u_2} {γ : Type u_3} {G : SimpleGraph α} {H : SimpleGraph β} (c : (G ⊕g H).Coloring γ) :

                  Get coloring of H from coloring of G ⊕g H

                  Equations
                  Instances For
                    @[simp]
                    theorem SimpleGraph.Coloring.sumLeft_sum {α : Type u_1} {β : Type u_2} {γ : Type u_3} {G : SimpleGraph α} {H : SimpleGraph β} (cG : G.Coloring γ) (cH : H.Coloring γ) :
                    (cG.sum cH).sumLeft = cG
                    @[simp]
                    theorem SimpleGraph.Coloring.sumRight_sum {α : Type u_1} {β : Type u_2} {γ : Type u_3} {G : SimpleGraph α} {H : SimpleGraph β} (cG : G.Coloring γ) (cH : H.Coloring γ) :
                    (cG.sum cH).sumRight = cH
                    @[simp]
                    theorem SimpleGraph.Coloring.sum_sumLeft_sumRight {α : Type u_1} {β : Type u_2} {γ : Type u_3} {G : SimpleGraph α} {H : SimpleGraph β} (c : (G ⊕g H).Coloring γ) :
                    def SimpleGraph.Coloring.sumEquiv {α : Type u_1} {β : Type u_2} {γ : Type u_3} {G : SimpleGraph α} {H : SimpleGraph β} :
                    (G ⊕g H).Coloring γ G.Coloring γ × H.Coloring γ

                    Bijection between (G ⊕g H).Coloring γ and G.Coloring γ × H.Coloring γ

                    Equations
                    • One or more equations did not get rendered due to their size.
                    Instances For
                      def SimpleGraph.Coloring.sumFin {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} {n m : } (cG : G.Coloring (Fin n)) (cH : H.Coloring (Fin m)) :
                      (G ⊕g H).Coloring (Fin (n m))

                      Color G ⊕g H with Fin (n + m) given a coloring of G with Fin n and a coloring of H with Fin m

                      Equations
                      Instances For
                        theorem SimpleGraph.Colorable.sum_max {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} {n m : } (hG : G.Colorable n) (hH : H.Colorable m) :
                        (G ⊕g H).Colorable (n m)
                        theorem SimpleGraph.Colorable.of_sum_left {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} {n : } (h : (G ⊕g H).Colorable n) :
                        theorem SimpleGraph.Colorable.of_sum_right {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} {n : } (h : (G ⊕g H).Colorable n) :
                        @[simp]
                        theorem SimpleGraph.colorable_sum {α : Type u_1} {β : Type u_2} {G : SimpleGraph α} {H : SimpleGraph β} {n : } :