# Interesting 3D triangle question...

- Author:
- Michael Andrejkovics

This is an interesting question posed by my friend James Tanton on Twitter the other day
(link to tweet: https://twitter.com/jamestanton/status/815900001838600192)
Plot a triangle in the x-y plane, then plot the locus of points Z, where Z = (x,y,D), D being the sum of the distances from any point (x,y) in the triangle to each of the three sides of the triangle.
What is the area of the triangle formed by the locus of points?

In the above applet, you can drag points A, B and C around to create different starting triangles in the x-y plane. Point D is restricted to the triangle and its interior. Point Z is the black dot plotted in the 3D section on the right side of the screen. You can drag point D around the triangle, and it will leave a trace behind in 3D of where point Z has been. In this way you can get a picture of the triangle in question.
You can also drag the 3D view around to change the perspective, and zoom in/out. To reset the trace and try a new triangle, just hit the undo button in the top right, or reload the page. Enjoy!