-
Notifications
You must be signed in to change notification settings - Fork 27
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
Remove redundancy of triangulation #329
Conversation
Not sure why the tests are not running since I switched it to ready for review |
Can you rebase on top of the master branch ? |
@blegat I rebased this pr onto master and fixed a missing test dependency |
The tests don't work if you use the default library instead of CDDLib ? |
Yes I don't remember why I implemented like this. We could probably merge this PR with the new tests and fixed implementation using |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #329 +/- ##
=======================================
Coverage 88.95% 88.95%
=======================================
Files 37 37
Lines 3170 3170
=======================================
Hits 2820 2820
Misses 350 350 ☔ View full report in Codecov by Sentry. |
I updated the tests as you suggested and exchanged CDDLib for the default library in exact arithmetic. I agree it would be great to merge this "patch" fix and revisit the algorithm. When I read the implementation, it is very similar to Cohen-Hickey in that it is recursive, however it does not perform certain manipulations such as elimination that I would expect from Cohen-Hickey. I think this is interesting and may be more efficient, i.e. fewer computations, but it would be useful to pinpoint where the redundancy originates from. |
Yes, I don't remember exactly why I thought it would work but I could try to recollect my thoughts (good example of why comments are important ^^) |
Hi,
This pr is attempting to fix #285 and #249 by removing redundant simplices produced by
triangulation_indices
. So far I have added 7 polyhedra to the tests and have checked whether their volume is calculated correctly. Of these, 5 volumes were previously calculated incorrectly, including several examples from the issues and the isocahedron, and two were correct, namely the 5-simplex and the dodecahedron.The fix I have attempted so far is naively calling
unique
on the list of simplices, and with a bit more work I hope that I can correct the implementation itself. Since the implementation is somewhat different from the Cohen-Hickey algorithm I am still figuring this out.