# As distance between overlapping circles decreases, find radius so that total area is constant and proportion of overlapping area increases constantly

Take 2 circles of radius $$r$$ distant (center to center) by $$d$$. They start by barely touching each other, $$d = 2r$$.

Then, as the distance decreases, I have 2 requirements: I want

1. the total area to stay constant, and
2. the rate at which the proportion of the overlapping area (relative to the total area) increases, necessary to satisfy 1., to stay constant as well.

I know that:

• the area of the circles is $$A_C(r)=2 \pi r^2$$
• the overlapping area is given by $$A_O(r,d) = 2 r^2 \text{cos}^{-1}\left(\frac{d}{2r}\right) - \frac{1}{2}d\sqrt{4r^2 - d^2}$$
• therefore the total area is $$A_T(r,d) = A_C(r) - A_O(r,d) = 2 \pi r^2 - 2 r^2 \text{cos}^{-1}\left(\frac{d}{2r}\right) + \frac{1}{2}d\sqrt{4r^2 - d^2}$$

Requirement 1 tells me that, for all $$r$$ and $$d$$, and calling $$r_0$$ the initial radius, it must be that $$A_T(r,d) = A_C(r_0)$$.

Requirement 2 tells me that the change in the proportion of overlap, $$\frac{A_O(r,d)}{A_T(r,d)}$$, should be constant.

And, well... here I'm stuck.

I've done some testing in JavaScript and I have the feeling that Requirements 1 and 2 cannot be satisfied at the same time, but I'm not quite sure.

• You seem to be saying that you want $d$ to go from $2r_0$ to $0$, during which time $r$ goes from $r_0$ to $\sqrt{2}r_0$ and the overlapping area goes from $0$ to $2\pi r_0^2$. Given how complicated your expressions are, it seems unreasonable to expect the overlapping are to be a linear function of $d$. What might be possible would be to have the overlapping area to be a linear function of time $t$ while $d$ and $r$ would be a non-linear functions of $t$. But you should not expect a closed form for this: you could instead have numerical approximations. – Henry Jun 30 '20 at 15:08
• That's exactly what I'm saying, yes. Sorry if that wasn't that clear. My hunch was also that there isn't a closed form solution. I don't have time as a variable in my setup, only $r$ and $d$ so I'm not sure if there's an easy way out of this. – darpich Jun 30 '20 at 15:37
• You start with overlap zero - does not this imply that the overlap remains zero along the process? – Moti Jun 30 '20 at 16:53
• Since the circles are barely touching at the beginning, as the distance decreases the overlap will increase. – darpich Jul 2 '20 at 12:11

Tl;dr: Both conditions are possible, but condition 2 cannot be satisfied in terms of elementary functions.

Here are the equations that satisfy condition 1: \begin{align} r&=\sqrt{\frac{A}{2\arccos\left(-s\right)+2s\sqrt{1-s^{2}}}}\\ d&=2rs \end{align} Where $$A$$ is the constant area and $$s$$ is a parameter that you slide from $$s=0$$ to $$s=1$$. At $$0$$, the two circles are completely merged, and at $$1$$ they are completely seperate.

Messy Desmos graph: https://www.desmos.com/calculator/aeahpotvof $$\!$$ Here's how I found these:

I started with your equation for total area (written in a slightly different way) $$A=2\pi r^{2}-2r^{2}\arccos\left(\frac{d}{2r}\right)+\frac{d}{2}\sqrt{4r^{2}-d^{2}}$$ Now, as both $$d$$ and $$r$$ appear both inside and outside inverse cosine, we will not be able to separate them. However, I substituted in a new variable, called $$s$$ \begin{align} s&=\frac d{2r}\\ A&=2\pi r^{2}-2r^{2}\arccos\left(s\right)+\frac{d}{2}\sqrt{4r^{2}-d^{2}}\\ &=2\pi r^{2}-2r^{2}\arccos\left(s\right)+2r^{2}s\sqrt{1-s^{2}}\\ &=2r^2\left(\pi -\arccos\left(s\right)+s\sqrt{1-s^{2}}\right)\\ &=2r^2\left(\arccos(-s)+s\sqrt{1-s^{2}}\right)\\ r&=\sqrt{\frac A{2r^2\left(\arccos(-s)+s\sqrt{1-s^{2}}\right)}} \end{align} Now that we have $$r$$ in terms of $$s$$, we can easily rearrange our definition of $$s$$ to get $$d$$ in terms of $$s$$ and $$r$$, and condition 1 will be fulfilled. $$\!$$ Here's why it's impossible to fulfill condition 2 in terms of elementary functions:

I will skip the working out, as it is tedius plug-and-chug, but substituting the solutions for $$r$$ and $$s$$ into the equation for overlapping area, we get the following: $$A_O(s)=A\frac{\arccos\left(s\right)-s\sqrt{1-s^{2}}}{\arccos\left(-s\right)+s\sqrt{1-s^{2}}}$$ In order to make the overlap's growth rate constant, we must find its inverse, and then plug its inverse into itself, as $$f\left(f^{-1}(x)\right)=x$$ is a line. However, my attempts to find an inverse led me to a function that is known to have no inverse in terms of elementary functions.

Step 1 was to use the substitution $$s=\cos(x)$$. This can be undone later, and it transforms the function into a more manageable form. $$A_O(x)=\frac{x-\sin\left(x\right)\cos\left(x\right)}{\pi-x+\sin\left(x\right)\cos\left(x\right)}$$ \begin{align} \frac{1}{A_O}&=\frac{\pi-x+\sin\left(x\right)\cos\left(x\right)}{x-\sin\left(x\right)\cos\left(x\right)}\\ \frac{1}{A_O}&=\frac\pi{x-\sin\left(x\right)\cos\left(x\right)}-1\\ \frac{1}{A_O}+1&=\frac\pi{x-\sin\left(x\right)\cos\left(x\right)}\\ \frac\pi{\frac{1}{A_O}+1}&=x-\sin\left(x\right)\cos\left(x\right)\\ \frac{2\pi}{\frac{1}{A_O}+1}&=2x-\sin(2x)\\ \end{align} However, $$2x-\sin(2x)$$ is just a stretched version of $$x-\sin(x)$$, which is known to have no inverse. Since we cannot invert it, we cannot get $$x$$ in terms of $$A_O$$, and therefore we cannot get $$s$$ in terms of $$A_O$$. This means that we cannot find a transformation to put into $$s$$ that will make the overlapping area linear.

• I see. So it seems there is really no closed-form solution. Just one thing: I would like the proportion of overlapping area, $A_O(r,d)/A_T(r,d)$, to be constant, not just the overlapping area $A_O$. But I guess this doesn't change much the conclusion? – darpich Jul 2 '20 at 12:20
• Oh, I misunderstood the second condition. However, if $A_T$ and $A_O$ are both to be constant, the proportion between them will be constant as well. It is much less difficult to show that the two conditions cannot occur at the same time. If distance decreases, total area obviously decreases, as the circles overlap more. To compensate for that, the radius must grow. But if the distance decreases, the overlapping area clearly increases, so the radius must shrink. But it cannot shrink and grow at the same time. – Polygon Jul 2 '20 at 13:46
• Wait - just to make sure, you want the rate that the ratio of overlapping area increases to be constant? Or you want the ratio of overlapping area to be constant? – Polygon Jul 2 '20 at 13:49
• Sorry, I also got confused... I want the rate that the ratio of overlapping area increases to be constant. In other words, I want the change in $A_O/A_T$ to be constant (Indeed, as you point out, if I wanted the ratio of overlapping area to be constant, it'd be easy to show that this is not compatible with requirement 1.) – darpich Jul 3 '20 at 8:53