Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
sagemathgh-38955: Overwrote methods concerning loops for a matching covered graph
    
<!-- ^ Please provide a concise and informative title. -->
The objective of this issue is to overwrite the methods pertaining to
loops for a matching covered graph.

<!-- ^ Don't put issue numbers in the title, do this in the PR
description below. -->
<!-- ^ For example, instead of "Fixes sagemath#12345" use "Introduce new method
to calculate 1 + 2". -->
<!-- v Describe your changes below in detail. -->
More specifically, this PR aims to implement/ update the following
methods:
- [x] `allow_loops()`: Change whether loops are allowed in (matching
covered) graphs.
- [x] `allows_loops()`: Return whether loops are permitted in (matching
covered) graphs.
- [x] `has_loops()`: Check whether thare are loops in the (matching
covered) graph.
- [x] `loop_edges()`: Return a list of all loops in the (matching
covered) graph.
- [x] `loop_vertices()`: Return a list of vertices with loops.
- [x] `loops()`: Return a list of all loops in the (matching covered)
graph.
- [x] `number_of_loops()`: Return the number of edges that are loops.
- [x] `remove_loops()`: Remove loops on vertices in ``vertices``.

<!-- v Why is this change required? What problem does it solve? -->
This PR shall address the methods related to loops for matching covered
graphs.

<!-- v If this PR resolves an open issue, please link to it here. For
example, "Fixes sagemath#12345". -->
Fixes sagemath#38216. Note that this issue fixes a small part of the mentioned
issue.

### 📝 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
This PR depends on the PR sagemath#38742.

<!-- List all open PRs that this PR logically depends on. For example,
-->
<!-- - sagemath#12345: short description why this is a dependency -->
<!-- - sagemath#34567: ... -->

cc: @dcoudert.
    
URL: sagemath#38955
Reported by: Janmenjaya Panda
Reviewer(s): David Coudert
  • Loading branch information
Release Manager committed Dec 5, 2024
2 parents 43c413f + 91c97b4 commit bafd84e
Showing 1 changed file with 408 additions and 5 deletions.
Loading

0 comments on commit bafd84e

Please sign in to comment.