### 12.7.4Â Â Equilateral triangles in space: equilateral_triangle

See section 11.8.4 for equilateral triangles in the plane.

The equilateral_triangle command takes as arguments three
points, A, B and P.

equilateral_triangle returns and draws the equilateral triangle
ABC, where C is in the same half plane as
P.

Input:

A := point(0,0,0); B := point(3,3,3);

P := point(0,0,3)

then:

equilateral_triangle(A,B,P)

Output:

triangle_rectangle can take an optional fourth argument,
which is a variable which will be assigned to the third vertex of the
triangle.

Input:

triangle_rectangle(A,B,P,C)

then:

simplify(coordinates(C))

Output:

[(-3*sqrt(6)+6)/4,(-3*sqrt(6)+6)/4,(3*sqrt(6)+3)/2]