The question states:
Notice that the angle for which its measure is arctan(a/b), is the angle that has "a" as the oposite side, and "b" as the adjacent side , so it is the angle on the bottom right of the triangle.
Then the cosine of that angle, is defined as:
cos(angle) = adjacent/hypotenuse = b / squareroot( a^2+b^2)
which agrees with answer D in the list of possible answers given.