-
-
Notifications
You must be signed in to change notification settings - Fork 473
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
harmonise the interfaces of orientation() and acyclic_orientation() #38758
Comments
@dcoudert - do you think it's a good idea? |
Then there also should be an easy way to apply an orientation function to the graph and obtain the corresponding directed graph. Something like |
Please also include |
The current proposal is to make What should be done in Do we really need a method like |
I do not know if anything needs to be done. My point is that a harmonization/uniformization of the interfaces should be applied to all functions that produce graph orientations. The
Yes, assuming that |
As suggested by @maxale in sagemath#38758 (comment), we add a method to apply an orientation function to a graph and obtain the corresponding directed graph. ### 📝 Checklist <!-- Put an `x` in all the boxes that apply. --> - [x] The title is concise and informative. - [x] The description explains in detail what this PR is about. - [x] I have linked a relevant issue or discussion. - [x] I have created tests covering the changes. - [x] I have updated the documentation and checked the documentation preview. ### ⌛ Dependencies <!-- List all open PRs that this PR logically depends on. For example, --> <!-- - sagemath#12345: short description why this is a dependency --> <!-- - sagemath#34567: ... --> URL: sagemath#38778 Reported by: David Coudert Reviewer(s): Travis Scrimshaw
In #38809, we move all remaining orientation methods to file |
Please include yet another orientation method - |
Steps To Reproduce
for a graph
g
, outputs ofg.orientation()
andg.acyclic_orientation()
are rather different, type-wise.As reported by Gordon Royle on sage-devel
My suggestion is to redefine orientations of a graph$\Gamma=(V,E)$ to be a function $E\to V\times V$ ,
and return these, eventually making this the default.
Expected Behavior
should be consistent
Actual Behavior
is not
Additional Information
see also https://ask.sagemath.org/question/79427/the-acyclic-orientations-function-behaves-unexpectedly/
Environment
Checklist
The text was updated successfully, but these errors were encountered: