Is a Point Inside or Outside a Regular Polygon?

This Demonstration determines whether a point is inside or outside a polygon by summing the angles between adjacent vertices and the point in question. If the sum is (approximately) , the point is inside; otherwise, it is outside.

THINGS TO TRY

SNAPSHOTS

  • [Snapshot]
  • [Snapshot]
  • [Snapshot]

DETAILS

For more information, see the Wikipedia entry for Point in polygon.
    • Share:

Embed Interactive Demonstration New!

Just copy and paste this snippet of JavaScript code into your website or blog to put the live Demonstration on your site. More details »

Files require Wolfram CDF Player or Mathematica.