TITLE: How to determine if a triangle can be drawn with the given points.
QUESTION [7 upvotes]: Given $3$ points
$$(x_1, y_1), (x_2, y_2), (x_3, y_3),$$ how does one determine whether they are vertices of a triangle?
Thanks.

REPLY [3 votes]: The area of a triangle is given by the formula $$|\frac12 det(\vec{AB}, \vec{AC})|$$
Let $$\vec{A}=(x_1,y_1), \vec{B}=(x_2,y_2), \vec{C}=(x_3, y_3)$$
Then $$\vec{AB}=(x_2-x_1, y_2-y_1), \vec{AC}=(x_3-x_1,y_3-y_1)$$
Then it must hold that $$|  
(x_2-x_1)(y_3-y_1)-(y_2-y_1)(x_3-x_1)| \neq 0$$