Put an angle into a rectangular coordinate system so that the starting edge of the angle coincides with the non-negative semi-axis of the X axis.
On the terminal edge of the angle, find a point where A(x, y) passes through A as the vertical line of the X axis, and then R = (x 2+y 2) (1/2) cos = x/r.