What is a convex polygon and a nonconvex polygon?

http://en.wikipedia.org/wiki/Convex_polygon

http://www.google.com/search?q=convex+polygon&rls=com.microsoft:en-us:IE-SearchBox&ie=UTF-8&oe=UTF-8&sourceid=ie7&rlz=1I7SUNA

A convex polygon is a polygon in which all interior angles are less than 180 degrees. In other words, if you draw a straight line connecting any two points within the polygon, that line will only intersect the boundary of the polygon at those two points. All sides of a convex polygon will face outwards, away from the interior of the shape.

On the other hand, a nonconvex polygon is a polygon that has at least one interior angle greater than 180 degrees. This means that if you draw a straight line connecting two points within the polygon, that line may intersect the boundary at points other than just the two endpoints. Nonconvex polygons have at least one "dent" or "concave" section where the interior angles bend inward.

To determine if a given polygon is convex or nonconvex, you can follow these steps:

1. Identify all the vertices (corners) of the polygon.
2. Select any three consecutive vertices of the polygon.
3. Calculate the angle formed by the two sides of the polygon that share the middle vertex.
4. Repeat steps 2 and 3 for all sets of three consecutive vertices.
5. If any interior angle is greater than 180 degrees, then the polygon is nonconvex. Otherwise, if all interior angles are less than 180 degrees, the polygon is convex.

By following these steps, you can analyze the angles of a polygon and determine if it is convex or nonconvex.