Skip to content

Refactor breakpoint graph functions - #62

Merged
charles-plessy merged 2 commits into
mainfrom
bpgraph_fix
Aug 31, 2026
Merged

Refactor breakpoint graph functions#62
charles-plessy merged 2 commits into
mainfrom
bpgraph_fix

Conversation

@pribiller

Copy link
Copy Markdown
Contributor

This pull request renames the cycle_count function to cycle_nontrivial_count and adds a new cycle_count function that counts both trivial and nontrivial cycles.
Before this change, inversionEstimate_BD incorrectly computed the expected number of inversions because it assumed that cycle_count counted all cycles in the breakpoint graph rather than only a specific type.
With this change, the estimate correctly computes the expected number of inversions.
The documentation has also been updated to clarify this distinction.

Renames the function "cycle_count" to "cycle_nontrivial_count".
Adds a new "cycle_count" function that takes both trivial and non-trivial cycles into account.
Updates documentation related to breakpoint graph functions.
Adds documentation related to the new function "cycle_nontrivial_count".
The documentation has also been updated to clarify the distinction between trivial and non-trivial cycles and to specify which functions account for one or both types.
@charles-plessy
charles-plessy merged commit 044612e into main Aug 31, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants