Consider the following figure:
On the left, we have small circles perfectly aligned within a bigger one. The same distance from the center of the big circle and the same radius.
On the right, we make the blue circles closer to the center and the red circles far from the center. They still have the same radius but a little bigger than the previous one to remain adjacent. The movement of the small circles is controlled using an angle $\theta$ like illustrated below:
When $\theta = 0$ we have the initial configuration where the blue line illustrates the distance between the center of two adjacent circles. The red line illustrates the same distance when $\theta$ is different from 0.
The goal is to express the radius of the circles using $\theta$. In other words, I need to find the length of the red line (that I will divide by 2 to get the radius). The number of small circles is known so $\alpha$ is known. Same for the size of the big circle so the $R$ is known.
I also want to know the distance moved by each circle (illustrated by the arrow)
For the context, It's for a HTML/CSS demo I wrote about it here: https://frontendmasters.com/blog/creating-wavy-circles-with-fancy-animations/. I was able to find formulas that seemed to work. I am reviewing them again and I think I made a few mistakes because I am getting overlap between the circles for some values.
An extra question (not mandatory) is to calculate the distance illustrated in green:
The distance between the center of the big circle and the center of the red line (where the small circles touch)