Area of a triangle with vertices $p_{1}(x_{1},y_{1}), p_{2}(x_{2},y_{2}), p_{3}(x_{3},y_{3})$

93 Views Asked by At

The formula to find the area of such a triangle is

$\frac{1}{2} \begin{vmatrix} x_{1} & y_{1} & 1 \\ x_{2} & y_{2} & 1 \\ x_{3} & y_{3} & 1 \\ \end{vmatrix}$

when the triangle is traversed counterclockwise from $p_{1}$ to $p_{2}$ to $p_{3}$. And my textbook says the area would be negative if the direction is clockwise.

Why does the direction have to be counterclockwise in order to get a positive answer?

3

There are 3 best solutions below

5
On BEST ANSWER

If you carefully draw a picture and do some algebra you will find that $$\eqalign{ x_3-x_1&=r((x_2-x_1)\cos\theta-(y_2-y_1)\sin\theta)\cr y_3-y_1&=r((x_2-x_1)\sin\theta+(y_2-y_1)\cos\theta)\cr}$$ for some positive factor $r$ and some angle $\theta$ with $-\pi<\theta<\pi$. You will also observe that the triangle goes couterclockwise if $\theta$ is positive, clockwise if $\theta$ is negative.

If you now carefully work out your determinant, starting with $$\frac12\left|\matrix{x_1&x_2&1\cr x_2&y_2&1\cr x_3&y_3&1\cr}\right| =\frac12\left|\matrix{x_1&y_1&1\cr x_2-x_1&y_2-y_1&0\cr x_3-x_1&y_3-y_1&0\cr}\right|$$ and substituting the above formulae, you will get the result $$\tfrac12r\bigl((x_2-x_1)^2+(y_2-y_1)^2\bigr)\sin\theta\ .$$ In this formula everything is positive except for the $\sin\theta$, which is positive if $\theta$ is positive and negative if $\theta$ is negative. So the determinant is positive if the triangle is counterclockwise, negative if it is clockwise.

0
On

This is a matter of definition. For some applications you need signed areas and for some you need unsigned areas. When you need unsigned areas, you take the absolute value of this expression. When you need signed areas, you can arbitrarily assign a positive sign to one orientation and a negative sign to the other.

0
On

You get length of a vector by disregarding sign. If it is also considered, you have the sense of a vector. Similarly area as cross vector product has got a sign. It is just matter of convention.

Take

$\frac{1}{2} \begin{vmatrix} x_{1} & y_{1} & 1 \\ x_{3} & y_{3} & 1 \\ x_{2} & y_{2} & 1 \\ \end{vmatrix}$

to make its area negative.