  
  [1X6 [33X[0;0YProperties of digraphs[133X[101X
  
  
  [1X6.1 [33X[0;0YVertex properties[133X[101X
  
  [1X6.1-1 DigraphHasAVertex[101X
  
  [33X[1;0Y[29X[2XDigraphHasAVertex[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YReturns [9Xtrue[109X if the digraph [3Xdigraph[103X has at least one vertex, and [9Xfalse[109X if it
  does not.[133X
  
  [33X[0;0YSee also [2XDigraphHasNoVertices[102X ([14X6.1-2[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([]);[127X[104X
    [4X[28X<immutable empty digraph with 0 vertices>[128X[104X
    [4X[25Xgap>[125X [27XDigraphHasAVertex(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[]]);[127X[104X
    [4X[28X<immutable empty digraph with 1 vertex>[128X[104X
    [4X[25Xgap>[125X [27XDigraphHasAVertex(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[], [1]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 1 edge>[128X[104X
    [4X[25Xgap>[125X [27XDigraphHasAVertex(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.1-2 DigraphHasNoVertices[101X
  
  [33X[1;0Y[29X[2XDigraphHasNoVertices[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YReturns  [9Xtrue[109X  if  the  digraph  [3Xdigraph[103X  is  the  unique  digraph with zero
  vertices, and [9Xfalse[109X otherwise.[133X
  
  [33X[0;0YSee also [2XDigraphHasAVertex[102X ([14X6.1-1[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([]);[127X[104X
    [4X[28X<immutable empty digraph with 0 vertices>[128X[104X
    [4X[25Xgap>[125X [27XDigraphHasNoVertices(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[]]);[127X[104X
    [4X[28X<immutable empty digraph with 1 vertex>[128X[104X
    [4X[25Xgap>[125X [27XDigraphHasNoVertices(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[], [1]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 1 edge>[128X[104X
    [4X[25Xgap>[125X [27XDigraphHasNoVertices(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  
  [1X6.2 [33X[0;0YEdge properties[133X[101X
  
  [1X6.2-1 DigraphHasLoops[101X
  
  [33X[1;0Y[29X[2XDigraphHasLoops[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YReturns  [9Xtrue[109X  if the digraph [3Xdigraph[103X has loops, and [9Xfalse[109X if it does not. A
  loop is an edge with equal source and range.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 2], [2]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XDigraphEdges(D);[127X[104X
    [4X[28X[ [ 1, 1 ], [ 1, 2 ], [ 2, 2 ] ][128X[104X
    [4X[25Xgap>[125X [27XDigraphHasLoops(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2, 3], [1], [2]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XDigraphEdges(D);[127X[104X
    [4X[28X[ [ 1, 2 ], [ 1, 3 ], [ 2, 1 ], [ 3, 2 ] ][128X[104X
    [4X[25Xgap>[125X [27XDigraphHasLoops(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := CompleteDigraph(IsMutableDigraph, 4);[127X[104X
    [4X[28X<mutable digraph with 4 vertices, 12 edges>[128X[104X
    [4X[25Xgap>[125X [27XDigraphHasLoops(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.2-2 IsAntiSymmetricDigraph[101X
  
  [33X[1;0Y[29X[2XIsAntiSymmetricDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [33X[1;0Y[29X[2XIsAntisymmetricDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property is [9Xtrue[109X if the digraph [3Xdigraph[103X is antisymmetric, and [9Xfalse[109X if
  it is not.[133X
  
  [33X[0;0YA  digraph  is  [13Xantisymmetric[113X if whenever there is an edge with source [10Xu[110X and
  range  [10Xv[110X,  and  an edge with source [10Xv[110X and range [10Xu[110X, then the vertices [10Xu[110X and [10Xv[110X
  are equal.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27Xgr1 := Digraph([[2], [1, 3], [2, 3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsAntisymmetricDigraph(gr1);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XDigraphEdges(gr1){[1, 2]};[127X[104X
    [4X[28X[ [ 1, 2 ], [ 2, 1 ] ][128X[104X
    [4X[25Xgap>[125X [27Xgr2 := Digraph([[1, 2], [3, 3], [1]]);[127X[104X
    [4X[28X<immutable multidigraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsAntisymmetricDigraph(gr2);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XDigraphEdges(gr2);[127X[104X
    [4X[28X[ [ 1, 1 ], [ 1, 2 ], [ 2, 3 ], [ 2, 3 ], [ 3, 1 ] ][128X[104X
  [4X[32X[104X
  
  [1X6.2-3 IsBipartiteDigraph[101X
  
  [33X[1;0Y[29X[2XIsBipartiteDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property  is [9Xtrue[109X if the digraph [3Xdigraph[103X is bipartite, and [9Xfalse[109X if it
  is not. A digraph is bipartite if and only if the vertices of [3Xdigraph[103X can be
  partitioned  into  two  non-empty sets such that the source and range of any
  edge  of  [3Xdigraph[103X lie in distinct sets. Equivalently, a digraph is bipartite
  if and only if it is 2-colorable; see [2XDigraphGreedyColouring[102X ([14X7.3-16[114X).[133X
  
  [33X[0;0YSee also [2XDigraphBicomponents[102X ([14X5.4-13[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := ChainDigraph(4);[127X[104X
    [4X[28X<immutable chain digraph with 4 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsBipartiteDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := CycleDigraph(3);[127X[104X
    [4X[28X<immutable cycle digraph with 3 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsBipartiteDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := CompleteBipartiteDigraph(IsMutableDigraph, 5, 4);[127X[104X
    [4X[28X<mutable digraph with 9 vertices, 40 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsBipartiteDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.2-4 IsCompleteBipartiteDigraph[101X
  
  [33X[1;0Y[29X[2XIsCompleteBipartiteDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YReturns  [9Xtrue[109X  if  the  digraph [3Xdigraph[103X is a complete bipartite digraph, and
  [9Xfalse[109X if it is not.[133X
  
  [33X[0;0YA  digraph  is  a  [13Xcomplete  bipartite  digraph[113X  if  it  is  bipartite,  see
  [2XIsBipartiteDigraph[102X ([14X6.2-3[114X), and there exists a unique edge with source [10Xi[110X and
  range [10Xj[110X if and only if [10Xi[110X and [10Xj[110X lie in different bicomponents of [3Xdigraph[103X, see
  [2XDigraphBicomponents[102X ([14X5.4-13[114X).[133X
  
  [33X[0;0YEquivalently,  a  bipartite  digraph  with  bicomponents  of size [22Xm[122X and [22Xn[122X is
  complete precisely when it has [22X2mn[122X edges, none of which are multiple edges.[133X
  
  [33X[0;0YSee also [2XCompleteBipartiteDigraph[102X ([14X3.5-12[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := CycleDigraph(2);[127X[104X
    [4X[28X<immutable cycle digraph with 2 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsCompleteBipartiteDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := CycleDigraph(4);[127X[104X
    [4X[28X<immutable cycle digraph with 4 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsBipartiteDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsCompleteBipartiteDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := CompleteBipartiteDigraph(IsMutableDigraph, 5, 4);[127X[104X
    [4X[28X<mutable digraph with 9 vertices, 40 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsCompleteBipartiteDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.2-5 IsCompleteDigraph[101X
  
  [33X[1;0Y[29X[2XIsCompleteDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YReturns [9Xtrue[109X if the digraph [3Xdigraph[103X is complete, and [9Xfalse[109X if it is not.[133X
  
  [33X[0;0YA  digraph  is  [13Xcomplete[113X if it has no loops, and for all [13Xdistinct[113X vertices [10Xi[110X
  and  [10Xj[110X, there is exactly one edge with source [10Xi[110X and range [10Xj[110X. Equivalently, a
  digraph with [22Xn[122X vertices is complete precisely when it has [22Xn(n - 1)[122X edges, no
  loops, and no multiple edges.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2, 3], [1, 3], [1, 2]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 6 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsCompleteDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2, 2], [1]]);[127X[104X
    [4X[28X<immutable multidigraph with 2 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsCompleteDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := CompleteBipartiteDigraph(IsMutableDigraph, 5, 4);[127X[104X
    [4X[28X<mutable digraph with 9 vertices, 40 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsCompleteDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.2-6 IsCompleteMultipartiteDigraph[101X
  
  [33X[1;0Y[29X[2XIsCompleteMultipartiteDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property  returns  [9Xtrue[109X if [3Xdigraph[103X is a complete multipartite digraph,
  and [9Xfalse[109X if not.[133X
  
  [33X[0;0YA digraph is a [13Xcomplete multipartite digraph[113X if and only if its vertices can
  be  partitioned  into  at  least  two  maximal independent sets, where every
  possible  edge  between these independent sets occurs in the digraph exactly
  once.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := CompleteMultipartiteDigraph([2, 4, 6]);[127X[104X
    [4X[28X<immutable complete multipartite digraph with 12 vertices, 88 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsCompleteMultipartiteDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := CompleteBipartiteDigraph(IsMutableDigraph, 5, 4);[127X[104X
    [4X[28X<mutable digraph with 9 vertices, 40 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsCompleteMultipartiteDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.2-7 IsEmptyDigraph[101X
  
  [33X[1;0Y[29X[2XIsEmptyDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [33X[1;0Y[29X[2XIsNullDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YReturns  [9Xtrue[109X  if  the  digraph  [3Xdigraph[103X is empty, and [9Xfalse[109X if it is not. A
  digraph is [13Xempty[113X if it has no edges.[133X
  
  [33X[0;0Y[2XIsNullDigraph[102X  is  a  synonym for [2XIsEmptyDigraph[102X. See also [2XIsNonemptyDigraph[102X
  ([14X6.2-12[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[], []]);[127X[104X
    [4X[28X<immutable empty digraph with 2 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsEmptyDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsNullDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[], [1]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 1 edge>[128X[104X
    [4X[25Xgap>[125X [27XIsEmptyDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsNullDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.2-8 IsEquivalenceDigraph[101X
  
  [33X[1;0Y[29X[2XIsEquivalenceDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YA digraph is an equivalence digraph if and only if the digraph satisfies all
  of    [2XIsReflexiveDigraph[102X    ([14X6.2-13[114X),    [2XIsSymmetricDigraph[102X   ([14X6.2-14[114X)   and
  [2XIsTransitiveDigraph[102X  ([14X6.2-16[114X).  A  partial  order  [3Xdigraph[103X corresponds to an
  equivalence relation.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 3], [2], [1, 3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsEquivalenceDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.2-9 IsFunctionalDigraph[101X
  
  [33X[1;0Y[29X[2XIsFunctionalDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis property is [9Xtrue[109X if the digraph [3Xdigraph[103X is functional.[133X
  
  [33X[0;0YA digraph is [13Xfunctional[113X if every vertex is the source of a unique edge.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27Xgr1 := Digraph([[3], [2], [2], [1], [6], [5]]);[127X[104X
    [4X[28X<immutable digraph with 6 vertices, 6 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsFunctionalDigraph(gr1);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27Xgr2 := Digraph([[1, 2], [1]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsFunctionalDigraph(gr2);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27Xgr3 := Digraph(3, [1, 2, 3], [2, 3, 1]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsFunctionalDigraph(gr3);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.2-10 IsPermutationDigraph[101X
  
  [33X[1;0Y[29X[2XIsPermutationDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis property is [9Xtrue[109X if the digraph [3Xdigraph[103X is functional and each node has
  only one in-neighbour.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27Xgr1 := Digraph([[3], [2], [2], [1], [6], [5]]);[127X[104X
    [4X[28X<immutable digraph with 6 vertices, 6 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsPermutationDigraph(gr1);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27Xgr2 := Digraph([[1, 2], [1]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsPermutationDigraph(gr2);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27Xgr3 := Digraph(3, [1, 2, 3], [2, 3, 1]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsPermutationDigraph(gr3);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.2-11 IsMultiDigraph[101X
  
  [33X[1;0Y[29X[2XIsMultiDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YA  [13Xmultidigraph[113X  is  one  that  has at least two edges with equal source and
  range.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph(["a", "b", "c"], ["a", "b", "b"], ["b", "c", "a"]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsMultiDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := DigraphFromDigraph6String("&Bug");[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 6 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsDuplicateFree(DigraphEdges(D));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsMultiDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 2, 3, 2], [2, 1], [3]]);[127X[104X
    [4X[28X<immutable multidigraph with 3 vertices, 7 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsDuplicateFree(DigraphEdges(D));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsMultiDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := DigraphMutableCopy(D);[127X[104X
    [4X[28X<mutable multidigraph with 3 vertices, 7 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsMultiDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.2-12 IsNonemptyDigraph[101X
  
  [33X[1;0Y[29X[2XIsNonemptyDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YReturns  [9Xtrue[109X  if the digraph [3Xdigraph[103X is nonempty, and [9Xfalse[109X if it is not. A
  digraph is [13Xnonempty[113X if it has at least one edge.[133X
  
  [33X[0;0YSee also [2XIsEmptyDigraph[102X ([14X6.2-7[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[], []]);[127X[104X
    [4X[28X<immutable empty digraph with 2 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsNonemptyDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[], [1]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 1 edge>[128X[104X
    [4X[25Xgap>[125X [27XIsNonemptyDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.2-13 IsReflexiveDigraph[101X
  
  [33X[1;0Y[29X[2XIsReflexiveDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property  is [9Xtrue[109X if the digraph [3Xdigraph[103X is reflexive, and [9Xfalse[109X if it
  is not. A digraph is [13Xreflexive[113X if it has a loop at every vertex.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 2], [2]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsReflexiveDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[3, 1], [4, 2], [3], [2, 1]]);[127X[104X
    [4X[28X<immutable digraph with 4 vertices, 7 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsReflexiveDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.2-14 IsSymmetricDigraph[101X
  
  [33X[1;0Y[29X[2XIsSymmetricDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property  is [9Xtrue[109X if the digraph [3Xdigraph[103X is symmetric, and [9Xfalse[109X if it
  is not.[133X
  
  [33X[0;0YA [13Xsymmetric digraph[113X is one where for each non-loop edge, having source [10Xu[110X and
  range  [10Xv[110X,  there is a corresponding edge with source [10Xv[110X and range [10Xu[110X. If there
  are  [10Xn[110X edges with source [10Xu[110X and range [10Xv[110X, then there must be precisely [10Xn[110X edges
  with  source  [10Xv[110X  and  range  [10Xu[110X.  In  other  words, a symmetric digraph has a
  symmetric adjacency matrix [2XAdjacencyMatrix[102X ([14X5.2-1[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27Xgr1 := Digraph([[2], [1, 3], [2, 3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsSymmetricDigraph(gr1);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27Xadj1 := AdjacencyMatrix(gr1);;[127X[104X
    [4X[25Xgap>[125X [27XDisplay(adj1);[127X[104X
    [4X[28X[ [  0,  1,  0 ],[128X[104X
    [4X[28X  [  1,  0,  1 ],[128X[104X
    [4X[28X  [  0,  1,  1 ] ][128X[104X
    [4X[25Xgap>[125X [27Xadj1 = TransposedMat(adj1);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27Xgr1 = DigraphReverse(gr1);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27Xgr2 := Digraph([[2, 3], [1, 3], [2, 3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 6 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsSymmetricDigraph(gr2);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27Xadj2 := AdjacencyMatrix(gr2);;[127X[104X
    [4X[25Xgap>[125X [27XDisplay(adj2);[127X[104X
    [4X[28X[ [  0,  1,  1 ],[128X[104X
    [4X[28X  [  1,  0,  1 ],[128X[104X
    [4X[28X  [  0,  1,  1 ] ][128X[104X
    [4X[25Xgap>[125X [27Xadj2 = TransposedMat(adj2);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.2-15 IsTournament[101X
  
  [33X[1;0Y[29X[2XIsTournament[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property  is [9Xtrue[109X if the digraph [3Xdigraph[103X is a tournament, and [9Xfalse[109X if
  it is not.[133X
  
  [33X[0;0YA   tournament   is   an  orientation  of  a  complete  (undirected)  graph.
  Specifically, a tournament is a digraph which has a unique directed edge (of
  some orientation) between any pair of distinct vertices, and no loops.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2, 3, 4], [3, 4], [4], []]);[127X[104X
    [4X[28X<immutable digraph with 4 vertices, 6 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsTournament(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2], [1], [3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsTournament(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := CycleDigraph(IsMutableDigraph, 3);[127X[104X
    [4X[28X<mutable digraph with 3 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsTournament(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XDigraphRemoveEdge(D, 1, 2);[127X[104X
    [4X[28X<mutable digraph with 3 vertices, 2 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsTournament(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.2-16 IsTransitiveDigraph[101X
  
  [33X[1;0Y[29X[2XIsTransitiveDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property is [9Xtrue[109X if the digraph [3Xdigraph[103X is transitive, and [9Xfalse[109X if it
  is  not. A digraph is [13Xtransitive[113X if whenever [10X[ i, j ][110X and [10X[ j, k ][110X are edges
  of the digraph, then [10X[ i, k ][110X is also an edge of the digraph.[133X
  
  [33X[0;0YLet  [22Xn[122X  be  the number of vertices of an arbitrary digraph, and let [22Xm[122X be the
  number  of  edges.  For general digraphs, the methods used for this property
  use  a  version of the Floyd-Warshall algorithm, and have complexity [22XO(n^3)[122X.
  However     for     digraphs     which     are     topologically    sortable
  [[2XDigraphTopologicalSort[102X  ([14X5.1-10[114X)], then methods with complexity [22XO(m + n + m
  ⋅ n)[122X will be used when appropriate.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 2], [3], [3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsTransitiveDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27Xgr2 := Digraph([[1, 2, 3], [3], [3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsTransitiveDigraph(gr2);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27Xgr2 = DigraphTransitiveClosure(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27Xgr3 := Digraph([[1, 2, 2, 3], [3, 3], [3]]);[127X[104X
    [4X[28X<immutable multidigraph with 3 vertices, 7 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsTransitiveDigraph(gr3);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  
  [1X6.3 [33X[0;0YEdge Weights[133X[101X
  
  [1X6.3-1 EdgeWeights[101X
  
  [33X[1;0Y[29X[2XEdgeWeights[102X( [3Xdigraph[103X ) [32X attribute[133X
  [33X[1;0Y[29X[2XEdgeWeightsMutableCopy[102X( [3Xdigraph[103X ) [32X operation[133X
  [6XReturns:[106X  [33X[0;10YA list of lists of integers, floats or rationals.[133X
  
  [33X[0;0Y[10XEdgeWeights[110X  returns  the  list of lists of edge weights of the edges of the
  digraph [3Xdigraph[103X.[133X
  
  [33X[0;0YMore  specifically,  [10Xweights[i][j][110X  is the weight given to the [10Xj[110Xth edge from
  vertex    [10Xi[110X,    according    to    the    ordering   of   edges   given   by
  [10XOutNeighbours(digraph)[i][110X.[133X
  
  [33X[0;0YThe  function  [10XEdgeWeights[110X  returns  an  immutable  list of immutable lists,
  whereas  the  function  [10XEdgeWeightsMutableCopy[110X returns a copy of [10XEdgeWeights[110X
  which is a mutable list of mutable lists.[133X
  
  [33X[0;0YThe  edge  weights  of  a  digraph cannot be computed and must be set either
  using [10XSetEdgeWeights[110X or [2XEdgeWeightedDigraph[102X ([14X6.3-2[114X).[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27Xgr := EdgeWeightedDigraph([[2], [3], [1]], [[5], [10], [15]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XEdgeWeights(gr);[127X[104X
    [4X[28X[ [ 5 ], [ 10 ], [ 15 ] ][128X[104X
    [4X[25Xgap>[125X [27Xa := EdgeWeightsMutableCopy(gr);[127X[104X
    [4X[28X[ [ 5 ], [ 10 ], [ 15 ] ][128X[104X
    [4X[25Xgap>[125X [27Xa[1][1] := 100;[127X[104X
    [4X[28X100[128X[104X
    [4X[25Xgap>[125X [27Xa;[127X[104X
    [4X[28X[ [ 100 ], [ 10 ], [ 15 ] ][128X[104X
    [4X[25Xgap>[125X [27Xb := EdgeWeights(gr);[127X[104X
    [4X[28X[ [ 5 ], [ 10 ], [ 15 ] ][128X[104X
    [4X[25Xgap>[125X [27Xb[1][1] := 534;[127X[104X
    [4X[28XError, List Assignment: <list> must be a mutable list[128X[104X
  [4X[32X[104X
  
  [1X6.3-2 EdgeWeightedDigraph[101X
  
  [33X[1;0Y[29X[2XEdgeWeightedDigraph[102X( [3Xdigraph[103X, [3Xweights[103X ) [32X function[133X
  [6XReturns:[106X  [33X[0;10YA digraph or [9Xfail[109X[133X
  
  [33X[0;0YThe argument [3Xdigraph[103X may be a digraph or a list of lists of integers, floats
  or rationals.[133X
  
  [33X[0;0Y[3Xweights[103X must be a list of lists of integers, floats or rationals of an equal
  size and shape to [10XOutNeighbours(digraph)[110X, otherwise it will fail.[133X
  
  [33X[0;0YThis will create a digraph and set the EdgeWeights to [3Xweights[103X.[133X
  
  [33X[0;0YSee [2XEdgeWeights[102X ([14X6.3-1[114X).[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27Xg := EdgeWeightedDigraph(Digraph([[2], [1]]), [[5], [15]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 2 edges>[128X[104X
    [4X[25Xgap>[125X [27Xg := EdgeWeightedDigraph([[2], [1]], [[5], [15]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 2 edges>[128X[104X
    [4X[25Xgap>[125X [27XEdgeWeights(g);[127X[104X
    [4X[28X[ [ 5 ], [ 15 ] ][128X[104X
  [4X[32X[104X
  
  [1X6.3-3 EdgeWeightedDigraphTotalWeight[101X
  
  [33X[1;0Y[29X[2XEdgeWeightedDigraphTotalWeight[102X( [3Xdigraph[103X ) [32X attribute[133X
  [6XReturns:[106X  [33X[0;10YAn integer, float or rational.[133X
  
  [33X[0;0YIf  [3Xdigraph[103X  is a digraph with edge weights, then this attribute returns the
  sum of the weights of its edges.[133X
  
  [33X[0;0YIf  the argument [3Xdigraph[103X is mutable, then the return value of this attribute
  is recomputed every time it is called.[133X
  
  [33X[0;0YSee [2XEdgeWeights[102X ([14X6.3-1[114X).[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := EdgeWeightedDigraph([[2], [1], [1, 2]],[127X[104X
    [4X[25X>[125X [27X                            [[12], [5], [6, 9]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XEdgeWeightedDigraphTotalWeight(D);[127X[104X
    [4X[28X32[128X[104X
  [4X[32X[104X
  
  [1X6.3-4 EdgeWeightedDigraphMinimumSpanningTree[101X
  
  [33X[1;0Y[29X[2XEdgeWeightedDigraphMinimumSpanningTree[102X( [3Xdigraph[103X ) [32X attribute[133X
  [6XReturns:[106X  [33X[0;10YA digraph.[133X
  
  [33X[0;0YIf  [3Xdigraph[103X  is  a  connected digraph with edge weights, then this attribute
  returns a digraph which is a minimum spanning tree of [3Xdigraph[103X.[133X
  
  [33X[0;0YA  [13Xspanning  tree[113X  of a digraph is a subdigraph with the same vertices but a
  subset  of  its  edges that form an undirected tree. It is [13Xminimum[113X if it has
  the smallest possible total weight for a spanning tree of that digraph.[133X
  
  [33X[0;0YIf  the argument [3Xdigraph[103X is mutable, then the return value of this attribute
  is recomputed every time it is called.[133X
  
  [33X[0;0YSee   [2XEdgeWeights[102X   ([14X6.3-1[114X),   [2XEdgeWeightedDigraphTotalWeight[102X   ([14X6.3-3[114X)  and
  [2XIsConnectedDigraph[102X ([14X6.6-3[114X).[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := EdgeWeightedDigraph([[2], [1], [1, 2]],[127X[104X
    [4X[25X>[125X [27X                            [[12], [5], [6, 9]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XT := EdgeWeightedDigraphMinimumSpanningTree(D);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 2 edges>[128X[104X
    [4X[25Xgap>[125X [27XEdgeWeights(T);[127X[104X
    [4X[28X[ [  ], [ 5 ], [ 6 ] ][128X[104X
  [4X[32X[104X
  
  
  [1X6.4 [33X[0;0YOrders[133X[101X
  
  [1X6.4-1 IsPreorderDigraph[101X
  
  [33X[1;0Y[29X[2XIsPreorderDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [33X[1;0Y[29X[2XIsQuasiorderDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YA  digraph  is  a preorder digraph if and only if the digraph satisfies both
  [2XIsReflexiveDigraph[102X  ([14X6.2-13[114X)  and  [2XIsTransitiveDigraph[102X  ([14X6.2-16[114X). A preorder
  digraph (or quasiorder digraph) [3Xdigraph[103X corresponds to the preorder relation
  [22X≤[122X defined by [22Xx ≤ y[122X if and only if [10X[x, y][110X is an edge of [3Xdigraph[103X.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1], [2, 3], [2, 3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsPreorderDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1 .. 4], [1 .. 4], [1 .. 4], [1 .. 4]]);[127X[104X
    [4X[28X<immutable digraph with 4 vertices, 16 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsPreorderDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2], [3], [4], [5], [1]]);[127X[104X
    [4X[28X<immutable digraph with 5 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsPreorderDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1], [1, 2], [2, 3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsQuasiorderDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.4-2 IsPartialOrderDigraph[101X
  
  [33X[1;0Y[29X[2XIsPartialOrderDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YA  digraph  is  a partial order digraph if and only if the digraph satisfies
  all  of  [2XIsReflexiveDigraph[102X  ([14X6.2-13[114X),  [2XIsAntisymmetricDigraph[102X  ([14X6.2-2[114X)  and
  [2XIsTransitiveDigraph[102X  ([14X6.2-16[114X).  A  partial  order [3Xdigraph[103X corresponds to the
  partial  order  relation [22X≤[122X defined by [22Xx ≤ y[122X if and only if [10X[x, y][110X is an edge
  of [3Xdigraph[103X.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 3], [2, 3], [3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsPartialOrderDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := CycleDigraph(5);[127X[104X
    [4X[28X<immutable cycle digraph with 5 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsPartialOrderDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 1], [1, 1, 2], [3], [3, 3, 4, 4]]);[127X[104X
    [4X[28X<immutable multidigraph with 4 vertices, 10 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsPartialOrderDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.4-3 IsMeetSemilatticeDigraph[101X
  
  [33X[1;0Y[29X[2XIsMeetSemilatticeDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [33X[1;0Y[29X[2XIsJoinSemilatticeDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [33X[1;0Y[29X[2XIsLatticeDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0Y[10XIsMeetSemilatticeDigraph[110X  returns  [9Xtrue[109X  if  the  digraph  [3Xdigraph[103X is a meet
  semilattice; [10XIsJoinSemilatticeDigraph[110X returns [9Xtrue[109X if the digraph [3Xdigraph[103X is
  a join semilattice; and [10XIsLatticeDigraph[110X returns [9Xtrue[109X if the digraph [3Xdigraph[103X
  is both a meet and a join semilattice.[133X
  
  [33X[0;0YFor  a partial order digraph [2XIsPartialOrderDigraph[102X ([14X6.4-2[114X) the corresponding
  partial  order  is the relation [22X≤[122X, defined by [22Xx ≤ y[122X if and only if [10X[x, y][110X is
  an  edge. A digraph is a [13Xmeet semilattice[113X if it is a partial order and every
  pair  of  vertices  has  a  greatest  lower bound (meet) with respect to the
  aforementioned  relation.  A [13Xjoin semilattice[113X is a partial order where every
  pair  of  vertices  has  a  least  upper  bound  (join)  with respect to the
  relation.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 3], [2, 3], [3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsMeetSemilatticeDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsJoinSemilatticeDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsLatticeDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1], [2], [1 .. 3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsJoinSemilatticeDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsMeetSemilatticeDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsLatticeDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1 .. 4], [2, 4], [3, 4], [4]]);[127X[104X
    [4X[28X<immutable digraph with 4 vertices, 9 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsMeetSemilatticeDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsJoinSemilatticeDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsLatticeDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.4-4 DigraphMeetTable[101X
  
  [33X[1;0Y[29X[2XDigraphMeetTable[102X( [3Xdigraph[103X ) [32X attribute[133X
  [33X[1;0Y[29X[2XDigraphJoinTable[102X( [3Xdigraph[103X ) [32X attribute[133X
  [6XReturns:[106X  [33X[0;10YA matrix or [9Xfail[109X.[133X
  
  [33X[0;0Y[10XDigraphMeetTable[110X  returns  the  [13Xmeet  table[113X  of [3Xdigraph[103X if [3Xdigraph[103X is a meet
  semilattice    digraph    [2XIsMeetSemilatticeDigraph[102X    ([14X6.4-3[114X).    Similarly,
  [10XDigraphJoinTable[110X  returns  the  [13Xjoin  table[113X  of [3Xdigraph[103X if [3Xdigraph[103X is a join
  semilattice digraph. [2XIsJoinSemilatticeDigraph[102X ([14X6.4-3[114X).[133X
  
  [33X[0;0YWhen  [3Xdigraph[103X  is a meet semilattice digraph with [22Xn[122X vertices, the [13Xmeet table[113X
  of  [3Xdigraph[103X  is  the matrix [22XA[122X such that the [22X(i, j)[122X entry of [22XA[122X is the meet of
  vertices [22Xi[122X and [22Xj[122X.[133X
  
  [33X[0;0YSimilarly,  when  [3Xdigraph[103X is a join semilattice digraph with [22Xn[122X vertices, the
  [13Xjoin table[113X of [3Xdigraph[103X is the matrix [22XA[122X such that the [22X(i, j)[122X entry of [22XA[122X is the
  join of vertices [22Xi[122X and [22Xj[122X. Otherwise, each function returns [9Xfail[109X.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 2, 3, 4], [2, 4], [3, 4], [4]]);[127X[104X
    [4X[28X<immutable digraph with 4 vertices, 9 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsJoinSemilatticeDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XDisplay(DigraphJoinTable(D));[127X[104X
    [4X[28X[ [  1,  2,  3,  4 ],[128X[104X
    [4X[28X  [  2,  2,  4,  4 ],[128X[104X
    [4X[28X  [  3,  4,  3,  4 ],[128X[104X
    [4X[28X  [  4,  4,  4,  4 ] ][128X[104X
    [4X[25Xgap>[125X [27XD := CycleDigraph(5);[127X[104X
    [4X[28X<immutable cycle digraph with 5 vertices>[128X[104X
    [4X[25Xgap>[125X [27XDigraphJoinTable(D);[127X[104X
    [4X[28Xfail[128X[104X
  [4X[32X[104X
  
  [1X6.4-5 IsUpperSemimodularDigraph[101X
  
  [33X[1;0Y[29X[2XIsUpperSemimodularDigraph[102X( [3XD[103X ) [32X property[133X
  [33X[1;0Y[29X[2XIsLowerSemimodularDigraph[102X( [3XD[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0Y[10XIsUpperSemimodularDigraph[110X  returns [9Xtrue[109X if the digraph [3XD[103X represents an upper
  semimodular    lattice    and    [9Xfalse[109X    if   it   does   not.   Similarly,
  [10XIsLowerSemimodularDigraph[110X  returns  [9Xtrue[109X if [3XD[103X represents a lower semimodular
  lattice and [9Xfalse[109X if it does not.[133X
  
  [33X[0;0YIn  a  lattice we say that a vertex [10Xa[110X [13Xcovers[113X a vertex [10Xb[110X if [10Xa[110X is greater than
  [10Xb[110X,  and  there  are  no further vertices between [10Xa[110X and [10Xb[110X. A lattice is [13Xupper
  semimodular[113X  if  whenever the meet of [10Xa[110X and [10Xb[110X is covered by [10Xa[110X, the join of [10Xa[110X
  and [10Xb[110X covers [10Xb[110X. [13XLower semimodularity[113X is defined analogously.[133X
  
  [33X[0;0YSee  also  [2XIsLatticeDigraph[102X  ([14X6.4-3[114X),  [2XNonUpperSemimodularPair[102X  ([14X5.3-2[114X), and
  [2XNonLowerSemimodularPair[102X  ([14X5.3-2[114X).  If  the argument [3Xdigraph[103X is mutable, then
  the return value of this property is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := DigraphFromDigraph6String([127X[104X
    [4X[25X>[125X [27X"&M~~sc`lYUZO__KIBboC_@h?U_?_GL?A_?c");[127X[104X
    [4X[28X<immutable digraph with 14 vertices, 66 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsUpperSemimodularDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsLowerSemimodularDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.4-6 IsDistributiveLatticeDigraph[101X
  
  [33X[1;0Y[29X[2XIsDistributiveLatticeDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0Y[10XIsDistributiveLatticeDigraph[110X  returns  [9Xtrue[109X  if  the  digraph  [3Xdigraph[103X  is a
  distributive lattice digraph.[133X
  
  [33X[0;0YA  [13Xdistributive  lattice  digraph[113X  is  a  lattice  digraph ([2XIsLatticeDigraph[102X
  ([14X6.4-3[114X))   which   is   distributive.   That   is   to  say,  the  functions
  [2XPartialOrderDigraphMeetOfVertices[102X                 ([14X5.3-1[114X)                and
  [2XPartialOrderDigraphJoinOfVertices[102X ([14X5.3-1[114X) distribute over each other.[133X
  
  [33X[0;0YEquivalently,  a  distributive lattice digraph is a lattice digraph in which
  the  [13Xlattice  digraphs[113X representing [22XM3[122X and [22XN5[122X are not embeddable as lattices
  (see          [7Xhttps://en.wikipedia.org/wiki/Distributive_lattice[107X         and
  [2XIsLatticeEmbedding[102X ([14X7.3-21[114X)).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2, 3], [4], [4], []]);[127X[104X
    [4X[28X<immutable digraph with 4 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XD := DigraphReflexiveTransitiveClosure(D);[127X[104X
    [4X[28X<immutable preorder digraph with 4 vertices, 9 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsDistributiveLatticeDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XN5 := Digraph([[2, 4], [3], [5], [5], []]);[127X[104X
    [4X[28X<immutable digraph with 5 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XN5 := DigraphReflexiveTransitiveClosure(N5);[127X[104X
    [4X[28X<immutable preorder digraph with 5 vertices, 13 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsDistributiveLatticeDigraph(N5);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.4-7 IsModularLatticeDigraph[101X
  
  [33X[1;0Y[29X[2XIsModularLatticeDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0Y[10XIsModularLatticeDigraph[110X  returns  [9Xtrue[109X  if  the digraph [3Xdigraph[103X is a modular
  lattice digraph.[133X
  
  [33X[0;0YA  [13Xmodular  lattice  digraph[113X is a lattice digraph ([2XIsLatticeDigraph[102X ([14X6.4-3[114X))
  which is modular. That is to say, the lattice digraph representing [22XN5[122X is not
  embeddable  as  a lattice (see [7Xhttps://en.wikipedia.org/wiki/Modular_lattice[107X
  and [2XIsLatticeEmbedding[102X ([14X7.3-21[114X)).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := ChainDigraph(5);[127X[104X
    [4X[28X<immutable chain digraph with 5 vertices>[128X[104X
    [4X[25Xgap>[125X [27XD := DigraphReflexiveTransitiveClosure(D);[127X[104X
    [4X[28X<immutable preorder digraph with 5 vertices, 15 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsModularLatticeDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XN5 := Digraph([[2, 3], [4], [4], []]);[127X[104X
    [4X[28X<immutable digraph with 4 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XDigraphReflexiveTransitiveClosure(N5);[127X[104X
    [4X[28X<immutable preorder digraph with 4 vertices, 9 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsModularLatticeDigraph(N5);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  
  [1X6.5 [33X[0;0YRegularity[133X[101X
  
  [1X6.5-1 IsInRegularDigraph[101X
  
  [33X[1;0Y[29X[2XIsInRegularDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property is [9Xtrue[109X if there is an integer [10Xn[110X such that for every vertex [10Xv[110X
  of  digraph  [3Xdigraph[103X  there  are  exactly [10Xn[110X edges terminating in [10Xv[110X. See also
  [2XIsOutRegularDigraph[102X ([14X6.5-2[114X) and [2XIsRegularDigraph[102X ([14X6.5-3[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XIsInRegularDigraph(CompleteDigraph(4));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsInRegularDigraph(ChainDigraph(4));[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.5-2 IsOutRegularDigraph[101X
  
  [33X[1;0Y[29X[2XIsOutRegularDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property is [9Xtrue[109X if there is an integer [10Xn[110X such that for every vertex [10Xv[110X
  of digraph [3Xdigraph[103X there are exactly [10Xn[110X edges starting at [10Xv[110X.[133X
  
  [33X[0;0YSee also [2XIsInRegularDigraph[102X ([14X6.5-1[114X) and [2XIsRegularDigraph[102X ([14X6.5-3[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XIsOutRegularDigraph(CompleteDigraph(4));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsOutRegularDigraph(ChainDigraph(4));[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.5-3 IsRegularDigraph[101X
  
  [33X[1;0Y[29X[2XIsRegularDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property is [9Xtrue[109X if there is an integer [10Xn[110X such that for every vertex [10Xv[110X
  of  digraph [3Xdigraph[103X there are exactly [10Xn[110X edges starting and terminating at [10Xv[110X.
  In  other  words, the property is [9Xtrue[109X if [3Xdigraph[103X is both in-regular and and
  out-regular.  See  also  [2XIsInRegularDigraph[102X  ([14X6.5-1[114X) and [2XIsOutRegularDigraph[102X
  ([14X6.5-2[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XIsRegularDigraph(CompleteDigraph(4));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsRegularDigraph(ChainDigraph(4));[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.5-4 IsDistanceRegularDigraph[101X
  
  [33X[1;0Y[29X[2XIsDistanceRegularDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YIf [3Xdigraph[103X is a connected symmetric graph, this property returns [9Xtrue[109X if for
  any  two  vertices [10Xu[110X and [10Xv[110X of [3Xdigraph[103X and any two integers [10Xi[110X and [10Xj[110X between [10X0[110X
  and the diameter of [3Xdigraph[103X, the number of vertices at distance [10Xi[110X from [10Xu[110X and
  distance  [10Xj[110X from [10Xv[110X depends only on [10Xi[110X, [10Xj[110X, and the distance between vertices [10Xu[110X
  and [10Xv[110X.[133X
  
  [33X[0;0YAlternatively,  a  distance  regular  graph is a graph for which there exist
  integers  [10Xb_i[110X,  [10Xc_i[110X,  and  [10Xi[110X  such that for any two vertices [10Xu[110X, [10Xv[110X in [3Xdigraph[103X
  which  are  distance [10Xi[110X apart, there are exactly [10Xb_i[110X neighbors of [10Xv[110X which are
  at  distance [10Xi - 1[110X away from [10Xu[110X, and [10Xc_i[110X neighbors of [10Xv[110X which are at distance
  [10Xi  +  1[110X  away  from  [10Xu[110X.  This definition is used to check whether [3Xdigraph[103X is
  distance regular.[133X
  
  [33X[0;0YIn the case where [3Xdigraph[103X is not symmetric or not connected, the property is
  [9Xfalse[109X.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := DigraphSymmetricClosure(ChainDigraph(5));;[127X[104X
    [4X[25Xgap>[125X [27XIsDistanceRegularDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2, 3, 4], [1, 3, 4], [1, 2, 4], [1, 2, 3]]);[127X[104X
    [4X[28X<immutable digraph with 4 vertices, 12 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsDistanceRegularDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  
  [1X6.6 [33X[0;0YConnectivity and cycles[133X[101X
  
  [1X6.6-1 IsAcyclicDigraph[101X
  
  [33X[1;0Y[29X[2XIsAcyclicDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property is [9Xtrue[109X if the digraph [3Xdigraph[103X is acyclic, and [9Xfalse[109X if it is
  not. A digraph is [13Xacyclic[113X if every directed cycle on the digraph is trivial.
  See  Section  [14X1.1-1[114X for the definition of a directed cycle, and of a trivial
  directed cycle.[133X
  
  [33X[0;0YThe  method  used  in  this  operation  has complexity [22XO(m+n)[122X where [22Xm[122X is the
  number  of  edges  (counting  multiple  edges as one) and [22Xn[122X is the number of
  vertices in the digraph.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XPetersen := Graph(SymmetricGroup(5), [[1, 2]], OnSets,[127X[104X
    [4X[25X>[125X [27Xfunction(x, y)[127X[104X
    [4X[25X>[125X [27X  return IsEmpty(Intersection(x, y));[127X[104X
    [4X[25X>[125X [27Xend);;[127X[104X
    [4X[25Xgap>[125X [27XD := Digraph(Petersen);[127X[104X
    [4X[28X<immutable digraph with 10 vertices, 30 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsAcyclicDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := DigraphFromDiSparse6String([127X[104X
    [4X[25X>[125X [27X".b_OGCIDBaPGkULEbQHCeRIdrHcuZMfRyDAbPhTi|zF");[127X[104X
    [4X[28X<immutable digraph with 35 vertices, 34 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsAcyclicDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsAcyclicDigraph(ChainDigraph(10));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := CompleteDigraph(IsMutableDigraph, 4);[127X[104X
    [4X[28X<mutable digraph with 4 vertices, 12 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsAcyclicDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsAcyclicDigraph(CycleDigraph(10));[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.6-2 IsChainDigraph[101X
  
  [33X[1;0Y[29X[2XIsChainDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0Y[10XIsChainDigraph[110X  returns  [9Xtrue[109X  if  the  digraph [3Xdigraph[103X is isomorphic to the
  chain  digraph  with the same number of vertices as [3Xdigraph[103X, and [9Xfalse[109X if it
  is not; see [2XChainDigraph[102X ([14X3.5-9[114X).[133X
  
  [33X[0;0YA  digraph  is  a [13Xchain[113X if and only if it is a directed tree, in which every
  vertex has out degree at most one; see [2XIsDirectedTree[102X ([14X6.6-8[114X) and [2XOutDegrees[102X
  ([14X5.2-8[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 3], [2, 3], [3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsChainDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := ChainDigraph(5);[127X[104X
    [4X[28X<immutable chain digraph with 5 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsChainDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := DigraphReverse(D);[127X[104X
    [4X[28X<immutable digraph with 5 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsChainDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := ChainDigraph(IsMutableDigraph, 5);[127X[104X
    [4X[28X<mutable digraph with 5 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsChainDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XDigraphReverse(D);[127X[104X
    [4X[28X<mutable digraph with 5 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsChainDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.6-3 IsConnectedDigraph[101X
  
  [33X[1;0Y[29X[2XIsConnectedDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property  is [9Xtrue[109X if the digraph [3Xdigraph[103X is weakly connected and [9Xfalse[109X
  if  it  is  not.  A digraph [3Xdigraph[103X is [13Xweakly connected[113X if it is possible to
  travel  from  any  vertex  to any other vertex by traversing edges in either
  direction (possibly against the orientation of some of them).[133X
  
  [33X[0;0YThe  method  used  in  this  function  has  complexity [22XO(m)[122X if the digraph's
  [2XDigraphSource[102X  ([14X5.2-5[114X)  attribute is set, otherwise it has complexity [22XO(m+n)[122X
  (where  [22Xm[122X  is  the  number  of  edges and [22Xn[122X is the number of vertices of the
  digraph).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2], [3], []]);;[127X[104X
    [4X[25Xgap>[125X [27XIsConnectedDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 3], [4], [3], []]);;[127X[104X
    [4X[25Xgap>[125X [27XIsConnectedDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph(IsMutableDigraph, [[2], [3], []]);;[127X[104X
    [4X[25Xgap>[125X [27XIsConnectedDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph(IsMutableDigraph, [[1, 3], [4], [3], []]);;[127X[104X
    [4X[25Xgap>[125X [27XIsConnectedDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.6-4 IsBiconnectedDigraph[101X
  
  [33X[1;0Y[29X[2XIsBiconnectedDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YA connected digraph is [13Xbiconnected[113X if it is still connected (in the sense of
  [2XIsConnectedDigraph[102X  ([14X6.6-3[114X)) when any vertex is removed. If [3XD[103X has at least 3
  vertices, then [10XIsBiconnectedDigraph[110X implies [2XIsBridgelessDigraph[102X ([14X6.6-5[114X); see
  [2XArticulationPoints[102X   ([14X5.4-14[114X)  or  [2XBridges[102X  ([14X5.4-15[114X)  for  a  more  detailed
  explanation.[133X
  
  [33X[0;0Y[10XIsBiconnectedDigraph[110X returns [9Xtrue[109X if the digraph [3Xdigraph[103X is biconnected, and
  [9Xfalse[109X  if  it  is  not. In particular, [10XIsBiconnectedDigraph[110X returns [9Xfalse[109X if
  [3Xdigraph[103X is not connected.[133X
  
  [33X[0;0YMultiple edges are ignored by this method.[133X
  
  [33X[0;0YThe  method  used  in  this  operation  has complexity [22XO(m+n)[122X where [22Xm[122X is the
  number of edges and [22Xn[122X is the number of vertices in the digraph.[133X
  
  [33X[0;0YSee    also    [2XBridges[102X    ([14X5.4-15[114X),    [2XArticulationPoints[102X    ([14X5.4-14[114X),   and
  [2XIsBridgelessDigraph[102X ([14X6.6-5[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XIsBiconnectedDigraph(Digraph([[1, 3], [2, 3], [3]]));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsBiconnectedDigraph(CycleDigraph(5));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 1], [1, 1, 2], [3], [3, 3, 4, 4]]);;[127X[104X
    [4X[25Xgap>[125X [27XIsBiconnectedDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := CompleteBipartiteDigraph(IsMutableDigraph, 5, 4);[127X[104X
    [4X[28X<mutable digraph with 9 vertices, 40 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsBiconnectedDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.6-5 IsBridgelessDigraph[101X
  
  [33X[1;0Y[29X[2XIsBridgelessDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YA  connected digraph is [13Xbridgeless[113X if it is still connected (in the sense of
  [2XIsConnectedDigraph[102X  ([14X6.6-3[114X))  when  any  edge  is removed. If [3Xdigraph[103X has at
  least    3    vertices,    then    [2XIsBiconnectedDigraph[102X    ([14X6.6-4[114X)   implies
  [10XIsBridgelessDigraph[110X; see [2XArticulationPoints[102X ([14X5.4-14[114X) or [2XBridges[102X ([14X5.4-15[114X) for
  a more detailed explanation.[133X
  
  [33X[0;0Y[10XIsBridgelessDigraph[110X  returns  [9Xtrue[109X if the digraph [3Xdigraph[103X is bridgeless, and
  [9Xfalse[109X  if  it  is  not.  In particular, [10XIsBridgelessDigraph[110X returns [9Xfalse[109X if
  [3Xdigraph[103X is not connected.[133X
  
  [33X[0;0YMultiple edges are ignored by this method.[133X
  
  [33X[0;0YThe  method  used  in  this  operation  has complexity [22XO(m+n)[122X where [22Xm[122X is the
  number of edges and [22Xn[122X is the number of vertices in the digraph.[133X
  
  [33X[0;0YSee    also    [2XBridges[102X    ([14X5.4-15[114X),    [2XArticulationPoints[102X    ([14X5.4-14[114X),   and
  [2XIsBiconnectedDigraph[102X ([14X6.6-4[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XIsBridgelessDigraph(Digraph([[1, 3], [2, 3], [3]]));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsBridgelessDigraph(CycleDigraph(5));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 1], [1, 1, 2], [3], [3, 3, 4, 4]]);;[127X[104X
    [4X[25Xgap>[125X [27XIsBridgelessDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := CompleteBipartiteDigraph(IsMutableDigraph, 5, 4);[127X[104X
    [4X[28X<mutable digraph with 9 vertices, 40 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsBridgelessDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2, 5], [1, 3, 4, 5], [2, 4], [2, 3], [1, 2]]);[127X[104X
    [4X[28X<immutable digraph with 5 vertices, 12 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsBridgelessDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsBiconnectedDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2], [3], [4], [2]]);[127X[104X
    [4X[28X<immutable digraph with 4 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsBridgelessDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsBiconnectedDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsBridgelessDigraph(ChainDigraph(2));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsBiconnectedDigraph(ChainDigraph(2));[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.6-6 IsStronglyConnectedDigraph[101X
  
  [33X[1;0Y[29X[2XIsStronglyConnectedDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis property is [9Xtrue[109X if the digraph [3Xdigraph[103X is strongly connected and [9Xfalse[109X
  if it is not.[133X
  
  [33X[0;0YA  digraph  [3Xdigraph[103X  is  [13Xstrongly connected[113X if there is a directed path from
  every  vertex to every other vertex. See Section [14X1.1-1[114X for the definition of
  a directed path.[133X
  
  [33X[0;0YThe  method used in this operation is based on Gabow's Algorithm [Gab00] and
  has  complexity  [22XO(m+n)[122X,  where  [22Xm[122X is the number of edges (counting multiple
  edges as one) and [22Xn[122X is the number of vertices in the digraph.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := CycleDigraph(250000);[127X[104X
    [4X[28X<immutable cycle digraph with 250000 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsStronglyConnectedDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := DigraphRemoveEdges(D, [[250000, 1]]);[127X[104X
    [4X[28X<immutable digraph with 250000 vertices, 249999 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsStronglyConnectedDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := CycleDigraph(IsMutableDigraph, 250000);[127X[104X
    [4X[28X<mutable digraph with 250000 vertices, 250000 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsStronglyConnectedDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XDigraphRemoveEdge(D, [250000, 1]);[127X[104X
    [4X[28X<mutable digraph with 250000 vertices, 249999 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsStronglyConnectedDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.6-7 IsAperiodicDigraph[101X
  
  [33X[1;0Y[29X[2XIsAperiodicDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis  property  is  [9Xtrue[109X  if  the  digraph [3Xdigraph[103X is aperiodic, i.e. if its
  [2XDigraphPeriod[102X ([14X5.4-17[114X) is equal to 1. Otherwise, the property is [9Xfalse[109X.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[6], [1], [2], [3], [4, 4], [5]]);[127X[104X
    [4X[28X<immutable multidigraph with 6 vertices, 7 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsAperiodicDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2], [3, 5], [4], [5], [1, 2]]);[127X[104X
    [4X[28X<immutable digraph with 5 vertices, 7 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsAperiodicDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph(IsMutableDigraph, [[2], [3, 5], [4], [5], [1, 2]]);[127X[104X
    [4X[28X<mutable digraph with 5 vertices, 7 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsAperiodicDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.6-8 IsDirectedTree[101X
  
  [33X[1;0Y[29X[2XIsDirectedTree[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YReturns  [9Xtrue[109X  if the digraph [3Xdigraph[103X is a directed tree, and [9Xfalse[109X if it is
  not.[133X
  
  [33X[0;0YA  [13Xdirected tree[113X is an acyclic digraph with precisely 1 source, such that no
  two  vertices  share an out-neighbour. Note that the empty digraph with zero
  vertices is not considered to be a directed tree, because it has no source.[133X
  
  [33X[0;0YSee also [2XDigraphSources[102X ([14X5.1-9[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[], [2]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 1 edge>[128X[104X
    [4X[25Xgap>[125X [27XIsDirectedTree(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[3], [3], []]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 2 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsDirectedTree(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2], [3], []]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 2 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsDirectedTree(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2, 3], [6], [4, 5], [], [], []]);[127X[104X
    [4X[28X<immutable digraph with 6 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsDirectedTree(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.6-9 IsUndirectedTree[101X
  
  [33X[1;0Y[29X[2XIsUndirectedTree[102X( [3Xdigraph[103X ) [32X property[133X
  [33X[1;0Y[29X[2XIsUndirectedForest[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThe  property  [10XIsUndirectedTree[110X  returns  [9Xtrue[109X  if the digraph [3Xdigraph[103X is an
  undirected tree, and the property [10XIsUndirectedForest[110X returns [9Xtrue[109X if [3Xdigraph[103X
  is an undirected forest; otherwise, these properties return [9Xfalse[109X.[133X
  
  [33X[0;0YAn  [13Xundirected  tree[113X  is a symmetric digraph without loops, in which for any
  pair of distinct vertices [10Xu[110X and [10Xv[110X, there is exactly one directed path from [10Xu[110X
  to  [10Xv[110X.  See [2XIsSymmetricDigraph[102X ([14X6.2-14[114X) and [2XDigraphHasLoops[102X ([14X6.2-1[114X), and see
  Section  [14X1.1-1[114X  for the definition of directed path. This definition implies
  that an undirected tree has no multiple edges.[133X
  
  [33X[0;0YAn  [13Xundirected forest[113X is a digraph, each of whose connected components is an
  undirected  tree.  In  other  words, an undirected forest is isomorphic to a
  disjoint  union  of undirected trees. See [2XDigraphConnectedComponents[102X ([14X5.4-9[114X)
  and  [2XDigraphDisjointUnion[102X  ([14X3.3-29[114X). In particular, every undirected tree is
  an undirected forest.[133X
  
  [33X[0;0YPlease  note that the digraph with zero vertices is considered to be neither
  an undirected tree nor an undirected forest.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[3], [3], [1, 2]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsUndirectedTree(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsSymmetricDigraph(D) and not DigraphHasLoops(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[3], [5], [1, 4], [3], [2]]);[127X[104X
    [4X[28X<immutable digraph with 5 vertices, 6 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsConnectedDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsUndirectedTree(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsUndirectedForest(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 2], [1], [2]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 4 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsUndirectedTree(D) or IsUndirectedForest(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsSymmetricDigraph(D) or not DigraphHasLoops(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.6-10 IsEulerianDigraph[101X
  
  [33X[1;0Y[29X[2XIsEulerianDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis property returns true if the digraph [3Xdigraph[103X is Eulerian.[133X
  
  [33X[0;0YA connected digraph is called [13XEulerian[113X if there exists a directed circuit on
  the  digraph  which  includes every edge exactly once. See Section [14X1.1-1[114X for
  the  definition  of  a directed circuit. Note that the empty digraph with at
  most one vertex is considered to be Eulerian.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[]]);[127X[104X
    [4X[28X<immutable empty digraph with 1 vertex>[128X[104X
    [4X[25Xgap>[125X [27XIsEulerianDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2], []]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 1 edge>[128X[104X
    [4X[25Xgap>[125X [27XIsEulerianDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[3], [], [2]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 2 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsEulerianDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[2], [3], [1]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsEulerianDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.6-11 IsHamiltonianDigraph[101X
  
  [33X[1;0Y[29X[2XIsHamiltonianDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YIf  [3Xdigraph[103X is Hamiltonian, then this property returns [9Xtrue[109X, and [9Xfalse[109X if it
  is not.[133X
  
  [33X[0;0YA  digraph  with  [10Xn[110X  vertices  is  [13XHamiltonian[113X if it has a directed cycle of
  length [10Xn[110X. See Section [14X1.1-1[114X for the definition of a directed cycle. Note the
  empty digraphs on 0 and 1 vertices are considered to be Hamiltonian.[133X
  
  [33X[0;0YThe  method  used  in  this  operation  has  the  worst  case  complexity as
  [2XDigraphMonomorphism[102X ([14X7.3-4[114X).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27Xg := Digraph([[]]);[127X[104X
    [4X[28X<immutable empty digraph with 1 vertex>[128X[104X
    [4X[25Xgap>[125X [27XIsHamiltonianDigraph(g);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27Xg := Digraph([[2], [1]]);[127X[104X
    [4X[28X<immutable digraph with 2 vertices, 2 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsHamiltonianDigraph(g);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27Xg := Digraph([[3], [], [2]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 2 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsHamiltonianDigraph(g);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27Xg := Digraph([[2], [3], [1]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 3 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsHamiltonianDigraph(g);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  [1X6.6-12 IsCycleDigraph[101X
  
  [33X[1;0Y[29X[2XIsCycleDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0Y[10XIsCycleDigraph[110X  returns  [9Xtrue[109X  if  the  digraph [3Xdigraph[103X is isomorphic to the
  cycle  digraph  with the same number of vertices as [3Xdigraph[103X, and [9Xfalse[109X if it
  is not; see [2XCycleDigraph[102X ([14X3.5-14[114X).[133X
  
  [33X[0;0YA  digraph  is  a  [13Xcycle[113X if and only if it is strongly connected and has the
  same number of edges as vertices.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := Digraph([[1, 3], [2, 3], [3]]);[127X[104X
    [4X[28X<immutable digraph with 3 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XIsCycleDigraph(D);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XD := CycleDigraph(5);[127X[104X
    [4X[28X<immutable cycle digraph with 5 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsCycleDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := OnDigraphs(D, (1, 2, 3));[127X[104X
    [4X[28X<immutable digraph with 5 vertices, 5 edges>[128X[104X
    [4X[25Xgap>[125X [27XD = CycleDigraph(5);[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsCycleDigraph(D);[127X[104X
    [4X[28Xtrue[128X[104X
  [4X[32X[104X
  
  
  [1X6.7 [33X[0;0YPlanarity[133X[101X
  
  [1X6.7-1 IsPlanarDigraph[101X
  
  [33X[1;0Y[29X[2XIsPlanarDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YA  [13Xplanar[113X  digraph  is a digraph that can be embedded in the plane in such a
  way  that  its edges do not intersect. A digraph is planar if and only if it
  does not have a subdigraph that is homeomorphic to either the complete graph
  on  [10X5[110X  vertices  or the complete bipartite graph with vertex sets of sizes [10X3[110X
  and [10X3[110X.[133X
  
  [33X[0;0Y[10XIsPlanarDigraph[110X  returns  [9Xtrue[109X if the digraph [3Xdigraph[103X is planar and [9Xfalse[109X if
  it  is  not.  The  directions and multiplicities of any edges in [3Xdigraph[103X are
  ignored by [10XIsPlanarDigraph[110X.[133X
  
  [33X[0;0YSee also [2XIsOuterPlanarDigraph[102X ([14X6.7-2[114X).[133X
  
  [33X[0;0YThis      method      uses      the      reference     implementation     in
  [5Xedge-addition-planarity-suite[105X  by  John Boyer of the algorithms described in
  [BM06].[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XIsPlanarDigraph(CompleteDigraph(4));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsPlanarDigraph(CompleteDigraph(5));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsPlanarDigraph(CompleteBipartiteDigraph(2, 3));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsPlanarDigraph(CompleteBipartiteDigraph(3, 3));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsPlanarDigraph(CompleteDigraph(IsMutableDigraph, 4));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsPlanarDigraph(CompleteDigraph(IsMutableDigraph, 5));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsPlanarDigraph(CompleteBipartiteDigraph(IsMutableDigraph, 2, 3));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsPlanarDigraph(CompleteBipartiteDigraph(IsMutableDigraph, 3, 3));[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.7-2 IsOuterPlanarDigraph[101X
  
  [33X[1;0Y[29X[2XIsOuterPlanarDigraph[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YAn  [13Xouter  planar[113X  digraph is a digraph that can be embedded in the plane in
  such  a  way that its edges do not intersect, and all vertices belong to the
  unbounded face of the embedding. A digraph is outer planar if and only if it
  does not have a subdigraph that is homeomorphic to either the complete graph
  on  [10X4[110X  vertices  or the complete bipartite graph with vertex sets of sizes [10X2[110X
  and [10X3[110X.[133X
  
  [33X[0;0Y[10XIsOuterPlanarDigraph[110X returns [9Xtrue[109X if the digraph [3Xdigraph[103X is outer planar and
  [9Xfalse[109X  if  it  is  not.  The  directions  and multiplicities of any edges in
  [3Xdigraph[103X are ignored by [10XIsPlanarDigraph[110X.[133X
  
  [33X[0;0YSee   also   [2XIsPlanarDigraph[102X   ([14X6.7-1[114X).   This  method  uses  the  reference
  implementation   in  [5Xedge-addition-planarity-suite[105X  by  John  Boyer  of  the
  algorithms described in [BM06].[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XIsOuterPlanarDigraph(CompleteDigraph(4));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsOuterPlanarDigraph(CompleteDigraph(5));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsOuterPlanarDigraph(CompleteBipartiteDigraph(2, 3));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsOuterPlanarDigraph(CompleteBipartiteDigraph(3, 3));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsOuterPlanarDigraph(CycleDigraph(10));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsOuterPlanarDigraph(CompleteDigraph(IsMutableDigraph, 4));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsOuterPlanarDigraph(CompleteDigraph(IsMutableDigraph, 5));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsOuterPlanarDigraph(CompleteBipartiteDigraph(IsMutableDigraph,[127X[104X
    [4X[25X>[125X [27X                                                 2, 3));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsOuterPlanarDigraph(CompleteBipartiteDigraph(IsMutableDigraph,[127X[104X
    [4X[25X>[125X [27X                                                 3, 3));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsOuterPlanarDigraph(CycleDigraph(IsMutableDigraph, 10));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[28X[128X[104X
  [4X[32X[104X
  
  
  [1X6.8 [33X[0;0YHomomorphisms and transformations[133X[101X
  
  [1X6.8-1 IsDigraphCore[101X
  
  [33X[1;0Y[29X[2XIsDigraphCore[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YThis property returns [9Xtrue[109X if [3Xdigraph[103X is a core, and [9Xfalse[109X if it is not.[133X
  
  [33X[0;0YA  digraph  [10XD[110X  is  a [13Xcore[113X if and only if it has no proper subdigraphs [10XA[110X such
  that there exists a homomorphism from [10XD[110X to [10XA[110X. In other words, a digraph [10XD[110X is
  a core if and only if every endomorphism on [10XD[110X is an automorphism on [10XD[110X.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XD := CompleteDigraph(6);[127X[104X
    [4X[28X<immutable complete digraph with 6 vertices>[128X[104X
    [4X[25Xgap>[125X [27XIsDigraphCore(D);[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XD := DigraphSymmetricClosure(CycleDigraph(6));[127X[104X
    [4X[28X<immutable symmetric digraph with 6 vertices, 12 edges>[128X[104X
    [4X[25Xgap>[125X [27XDigraphHomomorphism(D, CompleteDigraph(2));[127X[104X
    [4X[28XTransformation( [ 1, 2, 1, 2, 1, 2 ] )[128X[104X
    [4X[25Xgap>[125X [27XIsDigraphCore(D);[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
  [1X6.8-2 IsEdgeTransitive[101X
  
  [33X[1;0Y[29X[2XIsEdgeTransitive[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YIf  [3Xdigraph[103X  is  a  digraph  without  multiple  edges, then [10XIsEdgeTransitive[110X
  returns  [9Xtrue[109X  if [3Xdigraph[103X is edge transitive, and [9Xfalse[109X otherwise. A digraph
  is  [13Xedge transitive[113X if its automorphism group acts transitively on its edges
  (via the action [2XOnPairs[102X ([14XReference: OnPairs[114X)).[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XIsEdgeTransitive(CompleteDigraph(2));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsEdgeTransitive(ChainDigraph(3));[127X[104X
    [4X[28Xfalse[128X[104X
    [4X[25Xgap>[125X [27XIsEdgeTransitive(Digraph([[2], [3, 3, 3], []]));[127X[104X
    [4X[28XError, the argument <D> must be a digraph with no multiple edges,[128X[104X
  [4X[32X[104X
  
  [1X6.8-3 IsVertexTransitive[101X
  
  [33X[1;0Y[29X[2XIsVertexTransitive[102X( [3Xdigraph[103X ) [32X property[133X
  [6XReturns:[106X  [33X[0;10Y[9Xtrue[109X or [9Xfalse[109X.[133X
  
  [33X[0;0YIf  [3Xdigraph[103X is a digraph, then [10XIsVertexTransitive[110X returns [9Xtrue[109X if [3Xdigraph[103X is
  vertex  transitive,  and  [9Xfalse[109X otherwise. A digraph is [13Xvertex transitive[113X if
  its automorphism group acts transitively on its vertices.[133X
  
  [33X[0;0YIf  the  argument [3Xdigraph[103X is mutable, then the return value of this property
  is recomputed every time it is called.[133X
  
  [4X[32X  Example  [32X[104X
    [4X[25Xgap>[125X [27XIsVertexTransitive(CompleteDigraph(2));[127X[104X
    [4X[28Xtrue[128X[104X
    [4X[25Xgap>[125X [27XIsVertexTransitive(ChainDigraph(3));[127X[104X
    [4X[28Xfalse[128X[104X
  [4X[32X[104X
  
