The Math Forum

Ask Dr. Math - Questions and Answers from our Archives
Associated Topics || Dr. Math Home || Search Dr. Math

Point within a Triangle

Date: 05/29/2003 at 13:27:06
From: Venu
Subject: Equilateral Triangles

I have the coordinates of the three corners of a equilateral triangle 
ABC. How can I decide whether an arbitrary point (X,Y) lies in the 
plane of the triangle?

Date: 05/29/2003 at 15:29:53
From: Doctor George
Subject: Re: Equilateral Triangles

Hi Venu,

Thanks for writing to Doctor Math.

Let's call your vertices A, B and C. Now assign a direction to the 
sides of the triangle by referring to vectors AB, BC, and CA. Note 
that the vectors form a loop around the triangle.

Now let's call your point P, define vectors AP, BP, and CP, and 
compute the following vector cross products.

                AP x AB
                BP x BC
                CP x CA

If all three of these vectors are in the same direction then P is in 
triangle ABC. If P crosses over any side of the triangle then the 
cross product using that side will switch direction.

Does that make sense? Write again if you need more help.

- Doctor George, The Math Forum 
Associated Topics:
College Linear Algebra
College Triangles and Other Polygons
High School Linear Algebra
High School Triangles and Other Polygons

Search the Dr. Math Library:

Find items containing (put spaces between keywords):
Click only once for faster results:

[ Choose "whole words" when searching for a word like age.]

all keywords, in any order at least one, that exact phrase
parts of words whole words

Submit your own question to Dr. Math

[Privacy Policy] [Terms of Use]

Math Forum Home || Math Library || Quick Reference || Math Forum Search

Ask Dr. MathTM
© 1994- The Math Forum at NCTM. All rights reserved.