Skip to content

Conversation

wilfwilson
Copy link
Collaborator

@wilfwilson wilfwilson commented Sep 10, 2025

As reported by @TomGoertzen in #545, our attribute HamiltonianPath only looks for and returns Hamiltonian cycles, even though the more general notion of a Hamiltonian path that is not necessarily a cycle does exist (see e.g. beloved Wikipedia https://en.wikipedia.org/wiki/Hamiltonian_path).

Accordingly I've renamed HamiltonianPath to HamiltonianCycle in this PR. I will also separately create an issue to implement a new HamiltonianPath that returns a Hamiltonian path, and would work for e.g. a chain digraph. Update: that issue is #825.

Resolves #545 (pending release of Digraphs 2.0).

@wilfwilson wilfwilson added not-backwards-compatible A label for PRs that break backwards compatibility bugfix A label for PRs that fix a bug labels Sep 10, 2025
@wilfwilson wilfwilson force-pushed the HamiltonianPath-to-HamiltonianCycle branch from 4922203 to f454d8d Compare September 10, 2025 18:12
@wilfwilson wilfwilson changed the base branch from dev-2.0 to main September 10, 2025 18:16
@wilfwilson wilfwilson changed the base branch from main to dev-2.0 September 10, 2025 18:16
@wilfwilson wilfwilson merged commit 7a218ab into digraphs:dev-2.0 Sep 11, 2025
29 checks passed
@wilfwilson wilfwilson deleted the HamiltonianPath-to-HamiltonianCycle branch September 11, 2025 12:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix A label for PRs that fix a bug not-backwards-compatible A label for PRs that break backwards compatibility
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant