Zorba the Hutt (zorbathut) wrote,
Zorba the Hutt
zorbathut

  • Mood:
Start with arbitrary triangle T_0. Define set "actives" (containing T_0), set "finished" (empty), and set "next" (empty).

While actives is nonempty, for each vertex V_Y in each triangle T_X in actives:
Choose an edge from T_X that contains V_Y. Traverse around V_Y, making links as you go and adding each triangle to next. Mark each triangle with V_Y. Stop when you reach either a discontinuity or a triangle in any set, unless the triangle is in the set "next" and the triangle is marked with a vertex that is contained in T_X.

Add "actives" to "finished", move "next" into "actives", and clear "next".

. . . I *think* this works.
Subscribe
  • Post a new comment

    Error

    default userpic

    Your IP address will be recorded 

    When you submit the form an invisible reCAPTCHA check will be performed.
    You must follow the Privacy Policy and Google Terms of use.
  • 0 comments