1. ## triangle area

How do I make a function out of this problem?
Express the area A of a 30-60-90 triangle as a function of the length h of the hypotenuse.

2. One side of the triangle is h cos(60°) = h/2
Another side is h sin(60°) = h√3/2

Area is 1/2 h/2 h√3/2 = h²√3/8

3. Label the opposite side a and the adjacent b.

$a=hsin(30), \;\ b=hcos(30)$

The formula for the area of the triangle is $\frac{ab}{2}=\frac{hsin(30)\cdot hcos(30)}{2}$

4. Sin and Cos of angles get you the sides?

5. Hello, RaphaelB30!

Express the area $A$ of a 30-60-90 triangle
as a function of the length $h$ of the hypotenuse.

The answer is: $\frac{h^2\sqrt{3}}{8}$
You're expected to know the ratio of the sides of a 30-60-90 right triangle.
Code:
              *
/|
/ |
/  |
/30°|
2a /    |  _
/     | √3a
/      |
/       |
/ 60°    |
* - - - - *
a

We have: . $2a = h\quad\Rightarrow\quad a \:=\:\tfrac{h}{2}$

Then the base is: . $a \,=\,\tfrac{h}{2}$
. . . . and the height is: . $\sqrt{3}\,a \,=\,\tfrac{\sqrt{3}}{2}h$

Therefore, the area is: . $A \;=\;\tfrac{1}{2}\text{(base)(height)} \;=\;\frac{1}{2}\left(\frac{h}{2}\right)\left(\fra c{\sqrt{3}}{2}h\right) \;=\;\frac{h^2\sqrt{3}}{8}$