@@ -2222,11 +2222,13 @@ InstallMethod(Graph6String, "for a digraph by out-neighbours",
22222222[ IsDigraphByOutNeighboursRep] ,
22232223function (D )
22242224 local list, adj, n, lenlist, tablen, blist, i, j, pos, block;
2225- if (IsMultiDigraph(D) or not IsSymmetricDigraph(D)
2226- or DigraphHasLoops(D)) then
2227- ErrorNoReturn(" the argument <D> must be a symmetric digraph " ,
2228- " with no loops or multiple edges," );
2229- fi ;
2225+ if IsMultiDigraph(D) then
2226+ ErrorNoReturn(" the argument <D> must not have multiple edges; consider encoding in Disparse6 or Digraph6" );
2227+ elif not IsSymmetricDigraph(D) then
2228+ ErrorNoReturn(" the argument <D> must be a symmetric digraph; consider encoding in Sparse6 or Disparse6" );
2229+ elif DigraphHasLoops(D) then
2230+ ErrorNoReturn(" the argument <D> must not have loops; consider encoding in Sparse6 or Disparse6" );
2231+ fi ;
22302232
22312233 list := [] ;
22322234 adj := OutNeighbours(D);
@@ -2294,6 +2296,15 @@ function(D)
22942296 adj := OutNeighbours(D);
22952297 n := Length(DigraphVertices(D));
22962298
2299+ if IsMultiDigraph(D) then
2300+ if IsSymmetricDigraph(D) then
2301+ ErrorNoReturn(" the argument <D> must not have multiple edges " ,
2302+ " consider encoding in Sparse6 or Disparse6, " );
2303+ fi ;
2304+ ErrorNoReturn(" the argument <D> must not have multiple edges " ,
2305+ " consider encoding in Disparse6, " );
2306+ fi ;
2307+
22972308 # First write the special character '&'
22982309 Add(list, - 25 );
22992310
@@ -2354,6 +2365,14 @@ function(D)
23542365 ErrorNoReturn(" the argument <D> must be a symmetric digraph consider encoding in Digraph6 or Disparse6," );
23552366 fi ;
23562367
2368+ if not IsSymmetricDigraph(D) then
2369+ if IsMultiDigraph(D) then
2370+ ErrorNoReturn(" the argument <D> must be a symmetric digraph consider encoding in Disparse6," );
2371+ else
2372+ ErrorNoReturn(" the argument <D> must be a symmetric digraph consider encoding in Digraph6 or Disparse6," );
2373+ fi ;
2374+ fi ;
2375+
23572376 list := [] ;
23582377 n := Length(DigraphVertices(D));
23592378
0 commit comments