I’m trying to solve a math problem which I’d really appreciate some help with. I’ve tried to visualise it below to help explain it:

I’ve given two examples here. In both examples, this is the information that is known:
All four of the above variables can change, I’ve simply shown two examples in the image. My question is, how can I calculate the position(s) of the dashed circle(s)? There are some conditions for these circles:
Please could someone advise how to achieve this?

I’ve given two examples here. In both examples, this is the information that is known:
- The length of the horizontal line
- The position of both circles at the ends of the line
- The radius of both circles at the ends of the line
- The minimum gap between any circles to be plotted between the end circles
All four of the above variables can change, I’ve simply shown two examples in the image. My question is, how can I calculate the position(s) of the dashed circle(s)? There are some conditions for these circles:
- They must be equally spaced between the end (solid) circles
- They must have the same radius as the end (solid) circles
- They must be separated by at least the specified gap (to avoid overlap)
- If the two end (solid) circles are too close to permit a dashed circle between them with the minimum gap on either side, we must not plot a dashed circle.
Please could someone advise how to achieve this?