c_{n,m}=n/(n+m) c_{n-1,m+1} + m/(n+m) c_{n,m-1}
Boundary condition: c_{0,m} = m
After some experimenting I got the following closed form solution: c_{n,m}=H_n+m/(n+1) where H_n=sum_{i=1}^n 1/i (nth harmonic number). This can be shown by induction. We want to know what happens if we start from n whole pills and 0 half pills: c_{n,0} = H_n. Indeed, they are the harmonic numbers.