#19586: Add is_cayley_graph
-------------------------------------+-------------------------------------
Reporter: jaanos | Owner:
Type: enhancement | Status: new
Priority: major | Milestone: sage-6.10
Component: graph theory | Resolution:
Keywords: Cayley graphs | Merged in:
groups | Reviewers:
Authors: Janoš Vidali | Work issues:
Report Upstream: N/A | Commit:
Branch: | fbff6b8e22c419beef4a5d991c00d5c512a933f9
u/jaanos/add_is_cayley_graph | Stopgaps:
Dependencies: |
-------------------------------------+-------------------------------------
Comment (by ncohen):
Hellooooo,
> I should point out some questions and issues I have with this before it
goes into review.
I will try t answer them.
> * Should the method be called `is_cayley_graph`, or just `is_cayley`?
We have 'is_perfect', 'is_chordal', 'is_cartesian_product', so I'd vote
for 'is_cayley'.
> Now, I guess that maybe this doesn't really belong in
`generic_graph.py`. But maybe we could have a method in
`PermutationGroup_generic` which checks for the existence of such a group
(and have it returned if requested)?
Do you know how such a function could be named? Having 'nice and natural
name' for this function would rule out the alternative of having a 'hidden
helper function' for this code.
> * I should probably check whether the function works correctly with
graphs with loops and multigraphs (my instinct says yes for the former and
no for the latter).
You are not 'forced' to make it work in those cases. If it is complicated
or if you do not want to deal with those cases, you should look at
'scream_if_not_simple'. It happens very often throughout the graph/ code.
> * Can we have Unicode characters in the docstrings?
We can, and you can add this directive to the top of the file if you need
to. Now, I am not really a big fan of adding a name every time one adds a
function. That's just me, and perhaps some others. We already have 'git
blame' to figure out who wrote a function, and having in each function the
names of all people who ever touched it could quickly grow out of hands.
And I personally don't see the added value, and I personally don't want to
see Sage's source code turn out into a way to advertise its developers.
I added 'personally' everywhere to insist that it is my view, and that
other developers have different opinions. By our customs, you are totally
allowed to add your name in an author block if you want to.
Thanks for adding this function,
Nathann
--
Ticket URL: <http://trac.sagemath.org/ticket/19586#comment:3>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.