Skip to content

Commit 50145cf

Browse files
Merge pull request #49 from wilfwilson/improve-iso-colourings
Improve user-facing isomorphism and canonical labelling functions, especially with colourings
2 parents 402614d + 97c9fae commit 50145cf

15 files changed

Lines changed: 1377 additions & 490 deletions

File tree

doc/attr.xml

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,19 @@
1313
<Attr Name="ChromaticNumber" Arg="digraph"/>
1414
<Returns> A non-negative integer.</Returns>
1515
<Description>
16-
A digraph coloring is a labeling of the vertices (using precisely <A>n</A>
17-
colors) in such a way that two adjacent vertices can not have the same
18-
label. Alternatively, it can be defined to be a <Ref
19-
Oper="DigraphEpimorphism"/> from <A>digraph</A> onto a complete digraph
20-
with <A>n</A> vertices.<P/>
21-
22-
<C>ChromaticNumber</C> returns the least non-negative integer <C>n</C> such
23-
that there is a coloring of the loopless digraph <A>digraph</A> with
24-
<C>n</C> colors. In other words, <C>ChromaticNumber</C> returns the least
25-
value <C>n</C> such that <C>DigraphColoring(<A>digraph</A>, n)</C> does not
26-
return <K>fail</K>.
16+
A <E>proper colouring</E> of a digraph is a labelling of its
17+
vertices in such a way that adjacent vertices have different labels.
18+
Equivalently, a proper digraph colouring can be defined to be a <Ref
19+
Oper="DigraphEpimorphism"/> from a digraph onto a complete digraph. <P/>
20+
21+
If <A>digraph</A> is a digraph without loops (see <Ref
22+
Prop="DigraphHasLoops"/>, then <C>ChromaticNumber</C> returns the least
23+
non-negative integer <C>n</C> such that there is a proper colouring of
24+
<A>digraph</A> with <C>n</C> colours. In other words, for a digraph with at
25+
least one vertex, <C>ChromaticNumber</C> returns the least number <C>n</C>
26+
such that <C>DigraphColouring(<A>digraph</A>, n)</C> does not return
27+
<K>fail</K>. See <Ref Oper="DigraphColouring"
28+
Label="for a digraph and a number of colours"/>.
2729

2830
<Example><![CDATA[
2931
gap> ChromaticNumber(NullDigraph(10));

0 commit comments

Comments
 (0)