# Show that $(2,0,4) , (4,1,-1) , (6,7,7)$ form a right triangle

What I tried:

Let $A(2,0,4)$, $B(4,1,-1)$, $C(6,7,7)$ then

$$\vec{AB}=(2,1,-5), \vec{AC}=(4,7,3), \vec{BC}=(2,6,8)$$

Then I calculated the angle between vectors:

\begin{aligned} \alpha_1 &= \cos^{-1}\left(\frac{(2,1,-5)(4,7,3)}{\sqrt{2^2+1^2+(-5)^2}\sqrt{4^2+7^2+3^2}}\right) \\ &= \cos^{-1}(0)=90° \\ \alpha_2 &= \cos^{-1}\left(\frac{(4,7,3)(2,6,8)}{\sqrt{4^2+7^2+3^2}\sqrt{2^2+6^2+8^2}}\right) \\ &= \cos^{-1}\left(\frac{74}{\sqrt{74}\sqrt{104}}\right)=32.49\\ \alpha_3 &= \cos^{-1}\left(\frac{(2,6,8)(2,1,-5)}{\sqrt{2^2+6^2+8^2}\sqrt{2^2+1^2+(-5)^2}}\right) \\ &= \cos^{-1}\left(\frac{-30}{\sqrt{104}\sqrt{30}}\right)=122.5° \end {aligned}

As you can see, these angles don't even form a triangle, what am I doing wrong, any thoughts?

• The angle between the vectors $\vec{AB}$ and $\vec{BC}$ is actually $180$ degrees minus the angle between the line segments $\bar{AB}$ and $\bar{BC}$. Draw a diagram and pay attention to which way the arrows are facing—it gives you the exterior angle, not the interior one. Jun 23, 2017 at 17:52

It's enough to show the following: $$(2,1,-5)\cdot(4,7,3)=0$$ and we are done!

• That is enough to prove that the angle between $\ \vec{AB}$ and $\ \vec{AC}$ is a right angle, but is it enough to prove that all all the above vectors form a triangle? Jun 16, 2017 at 3:54
• @DavidTomahak if the angle between two sides is right, it also proves that all of the points are not on the same line and thus form a valid triangle. Jun 16, 2017 at 9:01
• @DavidTomahak Any three points non-collinear points in space lie in a plane, and form a triangle. A B and C are clearly non-collinear, otherwise the vectors AB and AC would not be perpendicular. Jun 16, 2017 at 11:37
• Technically it is not always true that if $u\cdot v=0$ then $u,v$ are perpendicular. There is also the possibility that $u=0$ (or $v=0$), but that's easy to exclude by inspection in this case. Jun 17, 2017 at 15:32

The distances satisfy the Pythagorean theorem.

$d(A, B) = \sqrt{2^2 + 1^2 + 5^2} = \sqrt{30}$

$d(A, C) = \sqrt{4^2 + 7^2 + 3^2} = \sqrt{74}$

$d(B, C) = \sqrt{2^2 + 6^2 + 8^2} = \sqrt{104}$

And indeed:

$\sqrt{30}^2 + \sqrt{74}^2 = \sqrt{104}^2$

Therefore it is a right triangle (link).

• Yes, but no need to take the square root. Jun 18, 2017 at 11:59
• @WeatherVane: Not sure exactly what you mean, but Euclidean distance is defined with the square-root operator. Jun 19, 2017 at 5:43
• I meant that you don't actually need the distance, only its square - that's all. Jun 19, 2017 at 6:32
• @WeatherVane: While programmatically true, that would seem to make for a poor explanation, because the square and square roots are what people are familiar with in those definitions and theorems. Jun 19, 2017 at 13:14
• @DanielR.Collins, Sorry. I have seen those now. Your answer is correct.:-) Thanks. Jun 24, 2021 at 21:57

To find $\alpha_3=\angle ABC$, you should consider $\overrightarrow{BA}\cdot \overrightarrow{BC}$ instead of $\overrightarrow{AB}\cdot \overrightarrow{BC}$. That's why you have a negative cosine and obtained the supplementary angle of the correct answer.

• @IntegrateThis But I think the accepted answer points out something which will be more useful in the future. That cumbersome math is sometimes useless.
– AHB
Jun 16, 2017 at 13:05
• @AHB This is also a better answer. OP asks "...what am I doing wrong, any thoughts?" Actually both answers together would be even better, but if it was me asking, I wouldn't be able to let go of "what am I doing wrong" before being shown the better way. Old tools sometimes turn out to be useful some other day, even after adding the shiny new tools to the sack.
– uhoh
Jun 18, 2017 at 9:59
• @uhoh One should merge them...
– AHB
Jun 18, 2017 at 10:57

$180°-122.5°=57.5°$, and the angles sum to be $180°$, nothing wrong here.

The angles you find has nothing to do with whether there is such a triangle with the three points as vertices. The triangle is already formed by the three points before you measure the angles.

• You still had to check if the three points are not on a straight line. Jun 16, 2017 at 5:20
• @DaanvdWoude isn't that done implicity by the angles not being 180°. 0° and 0° ? Jun 16, 2017 at 8:19
• Yes, but the answer states that you don't need to compute the angles, since three points always span a triangle. I just stated that this is not always the case, and that one should be careful when making this assumption. Jun 16, 2017 at 9:10
• @DaanvdWoude We don't really need to check that the three points are non-collinear. When one of the angles is already 90 degree, the three points must not be collinear.
– edm
Jun 16, 2017 at 16:21
• I think you are misreading my point. You don't know that one angle is 90 degrees, according to yourself the angles do not have to measured. So then you also don't know whether or not they form a straight line. Jun 17, 2017 at 14:16