Solution (source code)

= Solution

Write the boundary <Fourier series> as $f=A_0+\sum_{n\geq1}(a_n\cos n\phi+b_n\sin n\phi)$. Since $R=2$, its coefficients obey $a_n=2^nA_n$ and $b_n=2^nB_n$. The mean is
$$
A_0=\frac1{2\pi}\left(\pi+\int_\pi^{2\pi}\cos^2\phi\,d\phi\right)=\frac34.
$$
For $n\geq1$, the integral of $\cos n\phi$ on the first semicircle is zero. On the second semicircle, use $\cos^2\phi=(1+\cos2\phi)/2$ and <cosine> <orthogonality>. This gives $a_2=1/4$ and every other $a_n=0$.

For the <sine> coefficients, every even $n$ gives zero on both semicircles. For odd $n$, <product-to-sum formulas> give
$$
\begin{aligned}
\pi b_n&=\int_0^\pi\sin n\phi\,d\phi+
\int_\pi^{2\pi}\frac{1+\cos2\phi}{2}\sin n\phi\,d\phi\\
&=\frac2n-\frac1n-\frac12\left(\frac1{n+2}+\frac1{n-2}\right)
=\frac{4}{n(4-n^2)}.
\end{aligned}
$$
Thus the requested radial-expansion coefficients are
$$
\boxed{A_0=\frac34,\qquad A_n=\begin{cases}1/16,&n=2,\\0,&n\ne2,\end{cases}\qquad
B_n=\begin{cases}\displaystyle\frac{4}{\pi\,2^n n(4-n^2)},&n\text{ odd},\\0,&n\text{ even}.\end{cases}}
$$