Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

removeVertex does not update graph size #5

Open
thaumavorio opened this issue Mar 14, 2022 · 0 comments · May be fixed by #6
Open

removeVertex does not update graph size #5

thaumavorio opened this issue Mar 14, 2022 · 0 comments · May be fixed by #6

Comments

@thaumavorio
Copy link

thaumavorio commented Mar 14, 2022

The current implementations of removeVertex use the stored size without any updates. One would expect the number of edges to decrease by the degree of the vertex (at least for simple graphs).

For example (a bit verbose for demonstration purposes):
size . removeVertex 1 . insertEdgePair (1,1) $ insertVertex 1 (empty :: UGraph Int ()) is 1 even though the edge list is empty.

@thaumavorio thaumavorio linked a pull request Mar 15, 2022 that will close this issue
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 a pull request may close this issue.

1 participant