This problem is solved using the Pythagorean Theorem and knowledge of "soh-cah-toa".
Recall that "soh-cah-toa" reminds us that sin(x) = "opposite"/"hypotenuse"sin(x)=oppositehypotenuse, cos(x) = "adjacent"/"hypotenuse"cos(x)=adjacenthypotenuse and tan(x) = "opposite"/"adjacent"tan(x)=oppositeadjacent, where 'opposite', 'adjacent' and 'hypotenuse' refer to sides of a right triangle.
Our equality tan(x) = 5tan(x)=5 refers to a right triangle where the side opposite from angle xx is 5 times larger than the side adjacent to xx. The following is one such triangle (not drawn to scale).
Using the Pythagorean Theorem, we can find the length of the hypotenuse.
a^2 + b^2 = c^2a2+b2=c2,
1^2 + 5^2 = c^212+52=c2,
26 = c^226=c2,
c = sqrt(26)c=√26.
Then cos(x)cos(x) refers to our same triangle. See that cos(x) = "adjacent"/"hypotenuse" = 1 / sqrt(26)cos(x)=adjacenthypotenuse=1√26.
Note: This triangle extends up and to the right, into the first quadrant.