Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sagemathgh-36584: implemented power of graph function under basic met…
…hods ### Description This PR introduces a new function, `power_of_graph`, to compute the kth power of an undirected, unweighted graph efficiently using the shortest distances method. The proposed function leverages Breadth-First Search (BFS) to calculate the power graph, providing a practical and scalable solution. ### Why is this change required? The change is required to address the need for efficiently calculating the kth power of a graph, a fundamental operation in graph theory. The PR aims to incorporate this feature into the SageMath library. Fixes sagemath#36582 ### Checklist - [x] The title is concise, informative, and self-explanatory. - [x] The description explains in detail what this PR is about. - [x] I have linked a relevant issue or discussion (if applicable). - [x] I have created tests covering the changes. - [x] I have updated the documentation accordingly. ### ⌛ Dependencies sagemath#36582 : To implement power of graph URL: sagemath#36584 Reported by: saatvikraoIITGN Reviewer(s): David Coudert, saatvikraoIITGN
- Loading branch information