Finding out the area of a triangle if the coordinates of the three vertices are given

Solution 1:

What you are looking for is called the shoelace formula:

\begin{align*} \text{Area} &= \frac12 \big| (x_A - x_C) (y_B - y_A) - (x_A - x_B) (y_C - y_A) \big|\\ &= \frac12 \big| x_A y_B + x_B y_C + x_C y_A - x_A y_C - x_C y_B - x_B y_A \big|\\ &= \frac12 \Big|\det \begin{bmatrix} x_A & x_B & x_C \\ y_A & y_B & y_C \\ 1 & 1 & 1 \end{bmatrix}\Big| \end{align*}

The last version tells you how to generalize the formula to higher dimensions.

PS. Another generalization of the formula is obtained by noting that it follows from a discrete version of the Green's theorem:

$$ \text{Area} = \iint_{\text{domain}}dx\,dy = \frac12\oint_{\text{boundary}}x\,dy - y\,dx $$

Thus the signed (oriented) area of a polygon with $n$ vertexes $(x_i,y_i)$ is

$$ \frac12\sum_{i=0}^{n-1} x_i y_{i+1} - x_{i+1} y_i $$

where indexes are added modulo $n$.

Solution 2:

You know that AB × AC is a vector perpendicular to the plane ABC such that |AB × AC|= Area of the parallelogram ABA’C. Thus this area is equal to ½ |AB × AC|.

enter image description here

From AB= $(x_2 -x_1, y_2-y_1)$; AC= $(x_3-x_1, y_3-y_1)$, we deduce then

Area of $\Delta ABC$ = $\frac12$$[(x_2-x_1)(y_3-y_1)- (x_3-x_1)(y_2-y_1)]$

Solution 3:

Heron's formula is inefficient; there is in fact a direct formula. If the triangle has one vertex at the origin, and the other two vertices are $(a,b)$ and $(c,d)$, the formula for its area is $$ A = \frac{\left| ad - bc \right|}{2} $$

To get a formula where the vertices can be anywhere, just subtract the coordinates of the third vertex from the coordinates of the other two (translating the triangle) and then use the above formula.

Solution 4:

The simplest way to remember how to calculate is by taking $\frac{1}{2}$ the value of the determinant of the matrix $$ \begin{bmatrix} 1 & 1 & 1 \\ x_1 & x_2 & x_3 \\ y_1 & y_2 & y_3 \end{bmatrix} $$