in reply to Re: Better maps with Math::Geometry::Voronoi, and a Challenge for Math Monks
in thread Better maps with Math::Geometry::Voronoi, and a Challenge for Math Monks

Thanks, this is very useful. Have you looked at whether the extra poly is present in the lines() and edges()? That's the data that comes straight from the C implementation. If not, no problem, that's the first thing I'll look at.

-sam

  • Comment on Re^2: Better maps with Math::Geometry::Voronoi, and a Challenge for Math Monks

Replies are listed 'Best First'.
Re^3: Better maps with Math::Geometry::Voronoi, and a Challenge for Math Monks
by BrowserUk (Patriarch) on Jul 07, 2008 at 19:05 UTC

    No. Lines() and Edges() return 36 elements each. These are the 30 edges that make up the 9 polygons, plus six lines off the edge of the coordinate space, which are not part of any complete polygon.

    So the polygons() method must be manufacturing the extra poly.


    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.
      Cool, no suprise there. The polygon() method is all my work, so much more likely to be flawed than Steve Fortune's C code! I'll see if I can fix the problem.

      -sam