Decomposition to Convex Polygons

后端 未结 4 1901
陌清茗
陌清茗 2020-12-31 08:46

This question is a little involved. I wrote an algorithm for breaking up a simple polygon into convex subpolygons, but now I\'m having trouble proving that it\'s not

4条回答
  •  死守一世寂寞
    2020-12-31 09:23

    I believe the regular five pointed star (e.g. with alternating points having collinear segments) is the counterexample you seek.

    Edit in response to comments

    In light of my revised understanding, a revised answer: try an acute five pointed star (e.g. one with arms sufficiently narrow that only the three points comprising the arm opposite the reflex point you are working on are within the range considered "good reflex points"). At least working through it on paper it appears to give more than the optimal. However, a final reading of your code has me wondering: what do you mean by "closest" (i.e. closest to what)?

    Note

    Even though my answer was accepted, it isn't the counter example we initially thought. As @Mark points out in the comments, it goes from four to five at exactly the same time as the optimal does.

    Flip-flop, flip flop

    On further reflection, I think I was right after all. The optimal bound of four can be retained in a acute star by simply assuring that one pair of arms have collinear edges. But the algorithm finds five, even with the patch up.

    I get this:

    removing dead ImageShack link

    When the optimal is this:

    removing dead ImageShack link

提交回复
热议问题