The Cosine Function and Right Triangles