Skip to content

Conversation

@kappybar
Copy link
Contributor

I changed the default algorithm to the faster one (and fixed the results of several tests) in

  • all_simple_cycles in cycle_enumeration.py (default algorithm is changed to 'B')
  • shortest_simple_paths in path_enumeration.pyx (default algorithm is changed to 'PNC')
  • nc_k_shortest_simple_paths in path_enumeration.pyx (default parameter postponed is changed to True)

I found two unimplemented features in all_cycles_iterator in cycle_enumeration.py when algorithm='B'. The features are the followings:

  • The algorithm 'B' is unavailable when starting_vertices is not None.
  • The algorithm 'B' is unavailable when rooted=True.

I rase errors when these happen.

📝 Checklist

  • The title is concise and informative.
  • The description explains in detail what this PR is about.
  • I have linked a relevant issue or discussion.
  • I have created tests covering the changes.
  • I have updated the documentation and checked the documentation preview.

⌛ Dependencies

@github-actions
Copy link

github-actions bot commented Oct 19, 2025

Documentation preview for this PR (built with commit daeb424; changes) is ready! 🎉
This preview will update shortly after each push to this PR.

@dcoudert
Copy link
Contributor

Some doctests are failing due to these changes.
See for instance
https://github.com/sagemath/sage/actions/runs/18623771139/job/53098552404?pr=41076#step:11:1057

Copy link
Contributor

@dcoudert dcoudert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants