Ask Your Question
0

Generate multigraphs with given underlying graph

asked 2023-12-15 05:03:57 +0100

licheng gravatar image

updated 2023-12-15 05:07:43 +0100

Given an underlying graph G, to obtain all non-isomorphic directed graphs, I know that nauty has the directg function, and such function was been integrated in sagemath.

Read undirected loop-free graphs and replace their edges with multiple. Nauty's multigcan achieve this. (Isomorphic multigraphs derived from the same input are suppressed. If the input graphs are non-isomorphic then the output graphs are also.) ; see https://www.mankier.com/1/nauty-multi...

Does SageMath have similar functionality, or is such functionality integrated?

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
1

answered 2023-12-16 20:54:45 +0100

Max Alekseyev gravatar image

Check the source code for function graphs.nauty_geng() by running

??graphs.nauty_geng

and write a similar function that calls Nauty's multig rather than geng.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2023-12-15 05:03:57 +0100

Seen: 312 times

Last updated: Dec 16 '23