I would like to fourier transform two spheres with radius $r_1$ and $r_2$ and distance d where d is larger than $r_1$ + $r_2$.
The fourier transformation of one sphere is well known as: $$\int_{-1}^1\int_{-\sqrt{1-z^2}}^{\sqrt{1-z^2}}\int_{-\sqrt{1-z^2-y^2}}^{\sqrt{1-z^2-y^2}}e^{iq\cdot r}dxdydz $$
How can I add the second spheres to this integral.
Many thanks for your help.
Although the speed at which a Fourier series converges is improved by the differentiability of a function, even certain distributions such as the Dirac delta distribution will admit Fourier transforms without being functions (let alone continuous functions). A similar principal applies to Fourier transforms.
In short, to take the Fourier transform of a function on two disjoint balls, multiply your function the characteristic function of their set in three dimensional space. Then simply take the Fourier transform over all of three dimensional space.
$$ \int_{-\infty}^{\infty} \int_{-\infty}^{\infty} \int_{-\infty}^{\infty} f(x) \chi_{B} e^{-ikr} dx dy dz $$
where $r$ is a three dimensional vector and $\chi_B$ is the characteristic function that is only nonzero on the two disjoint balls.
For further reading, I would recommend researching partitions of unity.
Note that the final integral can be done in whatever coordinates you wish. You could integrate over each sphere and sum them together to get the Fourier transform for a function over both of them. In a sense, the each sphere is mutually unaware of the function defined on the other. You only need to superpose them by addition and linearity of the integral.
Sorry if there are any typos, I wrote this on my phone.
Edit: I just realized you posted a similar question to StackOverflow stating that you wished you knew the characteristic function between two spheres. You can define it simply as
$$ \chi_B = \begin{cases} 1 & \text{ if } ||\vec{x} - \vec{c}_1|| \leq r_1 \text{ or } ||\vec{x} - \vec{c}_2|| \leq r_2 \\ 0 & \text{ otherwise } \end{cases} $$ where $\vec{c}_1$ and $\vec{c}_2$ are the centers of the first and second spheres and $r_1$ and $r_2$ are their radii. In fact, this characteristic function will generalize to any arbitrary metric space be replacing $||\vec{x}-\vec{y}||$ with $d(x, y)$.