You are right, although it has not much to do with convexity.
As I noticed, if most or all points are close to the edge of the polygon
(ie. outside the inner and inside the outer circle), which in your (spiral)
case is hard to avoid, then the preprocessing of W2 is superfluous and will
(slightly) worsen the performance.


R.E. Boss


> Van: [email protected] [mailto:programming-
> [email protected]] Namens Bo Jacoby
> Onderwerp: Re: [Jprogramming] Polygon containment
> 
> Thank you.
> 
> I understanding that this optimization of the winding number algorithm
> performs well on almost regular polygons, while it doesn't perform
> substantially better on nonconvexe polygons like
> 
>    +/\(k...@-.,1,k=.(*0j1&^)@>:&i.)50
> 
> Am I right?
> 


----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to