Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am reading this paper

Given a complex polygon. Its edges may intersect. The algorithm finds out if given point is inside of polygon or not. It draws a line from the point and calculates number of intersections of line and edges of polygon. If the number of intersections is odd the point is inside polygon.

I don't understand how inside or outside of complex polygon are defined? I think there should be definition of it, that doesn't depend on any algorithm. So a polygon is given, what parts are inside of polygon and what part not?

enter image description here

share|cite|improve this question
I agree, without a precise definition of "inside" that paper is nonsense – AnalysisStudent0414 May 6 '14 at 19:33
up vote 5 down vote accepted

This paper (cited in your linked article) discusses two non-equivalent definitions of interior/exterior points of a convex polygon, one based on even-odd and the other on winding number, and so it appears the paper you have linked is using the even-odd rule as the definition and not as a result based on some other definition.

share|cite|improve this answer

The intuitive concept of "inside" and "outside" don't apply to convex polygons, however based on the algorithm a point is considered outside if the polygon "overlaps" itself an even amount of times.

share|cite|improve this answer
I thought the usual definition was based on 'winding number': any point inside will trace a circulation around the perimeter as 2*k*Pi, while any point outside has zero. – Wouter M. May 6 '14 at 19:36

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.