While this submission is a draft, it cannot be used by other submissions.

Chromatic number

Lax825442.ChromaticNumber · concepts/Lax825442/ChromaticNumber.lean · lax-825442

definition

Loading review…

Sign in with ORCID

Community review

Flags

Each flag is tied to a public ORCID identity and explains why this concept may be incorrect.

No flags have been submitted.

    Community review

    Flag this concept

    State precisely what appears incorrect. This explanation will be public under your ORCID name.

    No source line selected.

    Natural Language Statement

    Definition

    The chromatic number is the minimum number of colors in a proper vertex coloring. This interface takes the natural part of mathlib’s chromatic number, which is finite on finite graphs. Mathlib's SimpleGraph.colorableoffintypeSimpleGraph.colorable_of_fintype gives a coloring with at most the number of vertices, so conversion to a natural number loses no information.

    Concept map
    1 concept
    100%
    DefinitionThis concept

    Lean source view on GitHub

    1import Mathlib.Combinatorics.SimpleGraph.Coloring.Vertex
    2
    3/-!
    4---
    5title: Chromatic number
    6type: definition
    7---
    8The chromatic number is the minimum number of colors in a proper vertex
    9coloring. This interface takes the natural part of mathlib’s chromatic number,
    10which is finite on finite graphs.
    11Mathlib's `SimpleGraph.colorable_of_fintype` gives a coloring with at most
    12the number of vertices, so conversion to a natural number loses no information.
    13-/
    14
    15namespace Lax825442.ChromaticNumber
    16
    17/-- The natural-valued chromatic number of a finite graph. -/
    18noncomputable def chromaticNumber {V : Type} [Fintype V] [DecidableEq V]
    19 (G : SimpleGraph V) : ℕ :=
    20 G.chromaticNumber.toNat
    21
    22end Lax825442.ChromaticNumber
    23
    24
    Builds on

    none

    Used by

    none

    From Mathlib

    Discussion

    Ask a question or add context. Endorsements and structured flags are kept in the review panel above.

    Loading discussion…