Sub topic 15
Polygons in the Coordinate Plane
This chapter assumes you can use the Pythagorean theorem, find slopes from two points, and apply the area formulas for triangles, rectangles, parallelograms, and trapezoids. Here you apply those tools when a figure is given as coordinates instead of a drawing. The skills are finding side lengths, finding areas, and identifying the shape from the numbers.
Reading a polygon from its vertices
A polygon in the coordinate plane is described by its vertices, listed in order around the figure. Everything else comes from three basic calculations on pairs of points.
| Quantity | Formula for points (x1, y1) and (x2, y2) |
|---|---|
| Slope | (y2 - y1) / (x2 - x1) |
| Distance | square root of (x2 - x1)^2 + (y2 - y1)^2 |
| Midpoint | ((x1 + x2) / 2, (y1 + y2) / 2) |
The distance formula is the Pythagorean theorem. The horizontal change and the vertical change are the legs of a right triangle, and the segment is its hypotenuse. If you forget the formula, draw the legs and use the theorem.
Axis-aligned sides are easy
When a side is horizontal (same y-values) or vertical (same x-values), its length is just the difference of the changing coordinate. For example, the points (1, 1) and (5, 1) are 4 apart.
Take the triangle with vertices (1, 1), (5, 1), and (5, 4). The legs are 4 and 3, so the hypotenuse is 5. The perimeter is 4 + 3 + 5 = 12 and the area is (4 × 3) / 2 = 6. When two sides lie along the axes or parallel to them, the base and height can be read directly with no formula.
Identifying the shape with slopes and lengths
Classifying a quadrilateral from coordinates uses the same family tree as before, with each property checked numerically.
- Parallel sides have equal slopes.
- Perpendicular sides have slopes whose product is -1 (a horizontal side is perpendicular to a vertical side, where slope is undefined for one of them).
- Equal sides have equal distances.
- A parallelogram has diagonals with the same midpoint.
- A rhombus is a parallelogram with equal sides, and its diagonals are perpendicular.
Example: A(0, 0), B(5, 1), C(7, 4), D(2, 3).
- AB goes right 5 and up 1. DC also goes right 5 and up 1, so AB and DC are parallel and equal.
- BC goes right 2 and up 3. AD also goes right 2 and up 3.
- The midpoint of AC is (3.5, 2) and the midpoint of BD is also (3.5, 2).
Both pairs of opposite sides are parallel, so ABCD is a parallelogram. The sides are not all equal and no angle is a right angle, so it is not a rhombus or rectangle.
A rhombus example is (0, 0), (3, 4), (8, 4), (5, 0). Each side has length 5. The diagonals have slopes 1/2 and -2, whose product is -1, so they are perpendicular. Its area is base × height = 5 × 4 = 20. The diagonal formula gives the same value. The diagonals are √80 and √20, so (√80 × √20) / 2 = 40 / 2 = 20.
Three ways to find area
Method 1: Bounding box minus corner triangles
Draw the smallest axis-aligned rectangle around the polygon. Subtract the right triangles (and any rectangles) left over in the corners. This works well by hand on a triangle or quadrilateral.
Take the triangle (0, 0), (6, 2), (2, 5). The bounding box is 6 by 5, so its area is 30. Three right triangles fill the corners.
- Bottom right: (0, 0), (6, 0), (6, 2) has area (6 × 2) / 2 = 6.
- Top right: (6, 2), (6, 5), (2, 5) has area (3 × 4) / 2 = 6.
- Top left: (0, 0), (0, 5), (2, 5) has area (2 × 5) / 2 = 5.
The triangle's area is 30 - 6 - 6 - 5 = 13.
Method 2: The shoelace formula
For vertices (x1, y1) through (xn, yn) in order, compute the sum of xi × y(i+1) - x(i+1) × yi around the polygon, wrapping the last vertex back to the first. The area is half the absolute value of that sum.
def polygon_area(vertices):
total = 0
n = len(vertices)
for i in range(n):
x1, y1 = vertices[i]
x2, y2 = vertices[(i + 1) % n]
total += x1 * y2 - x2 * y1
return abs(total) / 2
print(polygon_area([(0, 0), (4, 0), (4, 3), (0, 3)])) # 12.0
print(polygon_area([(0, 0), (6, 2), (2, 5)])) # 13.0
print(polygon_area([(1, 1), (7, 1), (5, 4), (2, 4)])) # 13.5The third polygon is a trapezoid with parallel bases 6 and 3 and height 3. The trapezoid formula gives (6 + 3) / 2 × 3 = 13.5, which matches.
On the GRE you have no code, so the formula is mainly useful for odd shapes. Write the vertices in a column, repeat the first one at the bottom, and compute the cross products one row at a time.
Method 3: Known formulas with derived measurements
For a parallelogram, use base × height. For a trapezoid, use the average of the bases times the height. Use the coordinates to get the base and the perpendicular height. When no side is axis-aligned, the height is harder to read, which is when the other two methods are better.
Perimeter from coordinates
Perimeter requires the length of every side, so non-axis-aligned sides each need a distance calculation. For the trapezoid (1, 1), (7, 1), (5, 4), (2, 4):
- Bottom: 6.
- Right slanted side from (7, 1) to (5, 4): the legs are 2 and 3, so the length is √13.
- Top: 3.
- Left slanted side from (2, 4) to (1, 1): the legs are 1 and 3, so the length is √10.
The perimeter is 9 + √13 + √10, which is about 15.77.
import math
def perimeter(vertices):
total = 0
n = len(vertices)
for i in range(n):
x1, y1 = vertices[i]
x2, y2 = vertices[(i + 1) % n]
total += math.hypot(x2 - x1, y2 - y1)
return total
print(round(perimeter([(1, 1), (7, 1), (5, 4), (2, 4)]), 2)) # 15.77GRE answer choices often leave radicals unsimplified, so give an exact answer unless the question asks for an approximation.
Common errors
- Subtracting coordinates in inconsistent order inside a slope. Use the same point first in both numerator and denominator.
- Treating a quadrilateral as a rectangle because it looks like one. Verify perpendicular sides with slopes, or check that diagonals are equal in length as well as sharing a midpoint.
- Using a slanted side as the height of a parallelogram or trapezoid. The height is the perpendicular distance between the parallel sides.
- Forgetting that a negative shoelace sum only means the vertices run clockwise. Take the absolute value.
- Dropping the division by 2 in the shoelace formula or the triangle area.
Strategy summary
- Sketch the vertices, even roughly. A sketch shows which sides are axis-aligned and prevents misordered vertices.
- Use the cheapest method that fits. Axis-aligned sides come first, then known formulas, then bounding box or shoelace.
- Cross-check with a second method when time allows. Two methods that agree remove most arithmetic mistakes.
Exercise
A quadrilateral has vertices P(0, 0), Q(6, 0), R(8, 3), and S(2, 3). Show that it is a parallelogram, then find its area and perimeter.
Show answer
PQ goes right 6, and SR goes from (2, 3) to (8, 3), also right 6, so both are horizontal and equal. QR goes right 2 and up 3, and PS goes right 2 and up 3, so opposite sides are parallel and equal. PQRS is a parallelogram. The base is 6 and the perpendicular height is 3 (the vertical distance between y = 0 and y = 3), so the area is 6 × 3 = 18. The slanted sides have length √(2² + 3²) = √13, so the perimeter is 6 + 6 + 2√13 = 12 + 2√13, which is about 19.21.
Exercise
Use the bounding-box method to find the area of the triangle with vertices (1, 1), (7, 3), and (3, 6). Check your answer with the shoelace formula.
Show answer
The bounding box runs from x = 1 to 7 and y = 1 to 6, so it is 6 by 5 with area 30. The corner triangles are: (1, 1), (7, 1), (7, 3) with area (6 × 2) / 2 = 6; (7, 3), (7, 6), (3, 6) with area (4 × 3) / 2 = 6; and (1, 1), (1, 6), (3, 6) with area (5 × 2) / 2 = 5. The triangle's area is 30 - 6 - 6 - 5 = 13. Shoelace: (1×3 - 7×1) + (7×6 - 3×3) + (3×1 - 1×6) = -4 + 33 - 3 = 26, and 26 / 2 = 13.
Exercise
The points A(0, 0), B(3, 4), C(8, 4), D(5, 0) form a quadrilateral. Is it a rhombus? Is it a square?
Show answer
Each side has length 5: AB is √(9 + 16) = 5, BC is 5, CD is √(9 + 16) = 5, and DA is 5. A quadrilateral with four equal sides is a rhombus. It is not a square because AB has slope 4/3 and AD is horizontal, so the angle at A is not a right angle.