Since this is an inviscid flow, the boundary conditions for this flow are quite simple. As r-> ∞, the velocity must match the free stream flow. The other boundary condition is that no flow can go through the surface of the sphere. Our flow is left to right and the angle θ is measured starting at 3 o'clock and increases counter clockwise on the circle. We can figure out the correct sign for the far away flow by considering that at 9 O'Clock, the flow is purely radial and is coming inward which is negative. At 3 o'clock the flow is going straight out, which is positive. Similarly, at 12 o'clock, the flow is purely tangential, in the direction of decreasing θ value. Thus we use a Cos in front of the radial velocity and a -Sin in front of the tangential velocity. (I could have drawn a picture, but this is a useful visualization exercise.)
Thus
For r->∞,
= U Cos(θ)
= - U Sin(θ)
For r = R,
= 0