Dear Stavros,
unfortunately, there was a *slight* misunderstanding:
Since graphs are usually rather large data-structures, I provided
functions like edges(g), vertices(g), adjacency_matrix(g)...
But as usual output I'd like to have maxima print only the number of
vertices and edges, its dimension (ie. is it a graph, a 3-graph, ... or
a mixed hypergraph) and the name of the graph.
I will probably have a problem with my current internal format, which is
((%hypergraph) (prop1 . value1) (prop2 . value2) ...)
won't I ?
I don't think that it is necessary (or even wise) that a graph can be
reconstructed from its output.
(not even wise, because as it is set up currently, a graph which is not
assigned to a variable gets garbage collected, which is a good thing in my
opinion)
eg:
(c1) complete_graph(5);
(d1) "5 vertices, 10 2-edges"
and forget the graph. (Alternatively, assign it to d1, but I'm not sure
whether this is a good idea)
(c1) z:complete_graph(5);
(d1) "5 vertices, 10 2-edges"
(c2) length(spanning_trees(z));
(d2) 125
Maybe its better to have a unique symbol assigned to each graph. I don't
know.
Thanks a lot,
Martin