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

Algorithm to partition a polygon (convex decomposition) using the Hertel-Mehlhorn algorithm #1171

Open
urschrei opened this issue Apr 15, 2024 · 2 comments

Comments

@urschrei
Copy link
Member

Parry has an implementation here that should be straightforward to port.

Explanation: https://bjpcjp.github.io/pdfs/math/polygon-partitions-ADM.pdf

it’s worth noting that this algorithm, though widely used, has painful time complexity (at least O(n^4)), though the linked explanation notes that monotone polygon decomposition may be an alternative, faster approach. Geo has some monotone polygon functionality already, but it’s under-documented so I’m not sure whether it’s useful here (cc @rmanoka)

@rmanoka
Copy link
Contributor

rmanoka commented Apr 16, 2024

Yes, we currently have a monotone decomposition algorithm; if that could be used black-box, we can build on top of it.

@Hrsh-Venket
Copy link

Hrsh-Venket commented Sep 20, 2024

I would like to tackle this issue.

As I understand it, the implementation of the monotone decomposition algorithm that you are referring to is called monotone_subdivision

The alternative approach, just as implemented parry, invlolves monotone decomposition then removing all diagonals that do not create concave polygons.

I could also work on documenting not only this new function but also the pre-existing monotone decomposition function.

@urschrei and @rmanoka I am eager to get your remarks on the same.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants