an odd math problem that just popped into my head

Imagine a red circle.

Around the red circle, imagine a set of identical yellow circles; each yellow circle is tangent to the red circle and to each of its neighbors, like balls in a ring bearing.

Around the yellow circles, imagine a surrounding circle tangent to each of the yellow circles (so this circle and the red circle are concentric). Any area inside the outer circle that's not already red or yellow, color it blue.

1/2

an odd math problem that just popped into my head

Let the radius of each yellow circle be r, and the radius of the red circle be R.

What ratio of r to R maximizes the blue area? The number of yellow circles can vary as needed, as long as the other qualities are met (no gaps between yellow circles, no partial circles).

(I don't know the answer and I'm not sure how I'd begin solving it; it just popped into my head.)

2/2

an odd math problem that just popped into my head

@noelle i think you can write a messy polar coordinate expression for the areas of the circles, then subtract that from the unit circle area around them (since this is about relatives), then see if you get an easily differentiable function from that you can manipulate to get a ratio variable as your independent, then differentiate.

an odd math problem that just popped into my head

@amphetamine @noelle if i'm imagining this right, the biggest circle's radius is R+r, yeah? The only thing I'm having trouble with is how many yellow circles there are/how that's restricted by the other variables.

an odd math problem that just popped into my head

@Jewbacchus @noelle all the circles have a fixed diameter based on the ring spacing, and you can either lower bound their number by pretending their centers form a polygonal shape instead of a circle, or by writing an arclength function to divide into the circle's circumference.

an odd math problem that just popped into my head

@Jewbacchus @amphetamine @noelle apparently the number of yellow circles is restricted to multiples of 6, due to the way circles pack around each other. A typical example of this is the number of wire strands on a cable, which, by standard, go from 7 to 19 to 37:
7-1=6
19-7=12
37-19=18

an odd math problem that just popped into my head

@Jewbacchus @amphetamine @noelle wait, no. The number of yellow circles can also be a multiple of 8, given that the central red circle doesn't need to have the same radius than them (or a multiple of it), as it is with the cables. So, the number of yellow circles could be 6, 8, 12, 16, 18, 24...

an odd math problem that just popped into my head

@noelle minimize the size of the central “sun” circle

as the size of the planetary circles approaches 0, the area of the system occupied by the sun approaches 1, minimizing the void

with a nearly-zero size sun circle, you only get two planetary circles, leaving most of the space as void

re: an odd math problem that just popped into my head

@bonzoesc ah but the red circle would have to be _exactly_ zero radius, otherwise 2 yellow circles wouldn’t be touching

re: an odd math problem that just popped into my head

@bonzoesc ... which disqualifies this case, because r/R is NaN

re: an odd math problem that just popped into my head

@mxsparks yeah but I think if you got some geometer ( @msp ) to properly do the math you’d establish that smaller sun & bigger planets leads to more void space

an odd math problem that just popped into my head

Unfortunately it is many years since I did much math, but this seems like you would want r to approach 1/2 the diameter of the outer most circle with R approaching 0 because larger objects sort less efficiently and you are trying to maximize void.

If I thought on this for a while I could probably think of an equation to describe it, then it would need a derivative I think...

an odd math problem that just popped into my head

Er oops r 1/2 outer circle radius not diameter

an odd math problem that just popped into my head

My suspicion is 3 yellow circles...

an odd math problem that just popped into my head

@noelle I'm gonna reframe your problem slightly. We have n yellow circles of radius y, arranged as you described. Inscribing those circles is a red circle of radius r. Circumscribing them is a blue circle of radius b. Restating your question in these terms: If we expose only the blue area that isn't covered by red or yellow, what quotient Q = y/r gives the highest exposed blue area?

an odd math problem that just popped into my head

@noelle Each yellow circle has area Y = pi * y^2. The red circle has area R = pi * r^2. The blue circle has area B = pi * b^2. The exposed area X is the blue area minus the red area and the total of all the yellow areas, or X = B - R - n * Y.

an odd math problem that just popped into my head

@noelle If we connect the centers of the yellow circles, they construct a regular n-gon with side length s=2y. The circumradius of a regular polygon--the distance from the center to each vertex--has a standard formula. Plugging in our values that circumradius is c = y/sin(pi/n). And since the vertices of our polygon are at the centers of the yellow circles, c is the distance from the center of the red circle to the center of each yellow one.

an odd math problem that just popped into my head

@noelle Now, we need a couple quick digressions. First, I'm gonna invent a value q here as q = 1/sin(pi/n). It'll make our next calculations a little easier to check. Subbing that into our c equation above, we have c = yq. Second, since the red circle inscribes the yellow ones, we know r = c - y. Similarly, since the blue circle circumscribes the yellow ones, we know b = c + y.

an odd math problem that just popped into my head

@noelle With those, let's re-examine our original question. We want the Q that maximizes X. Q = y/r, so let's start solving for Q. We can substitute r = c - y to get Q = y/(c-y), then sub c = yq to get Q = y/(yq-y), which simplifies to Q = 1/(q-1). Our q we defined as somewhat complex, but if we substitute and simplify we get Q = sin(pi/n) / (1 - sin(pi/n)).

an odd math problem that just popped into my head

@noelle I just graphed that. It's pretty messy for |n| < 3, but we really only care about integer n >= 3, and in that range it pretty clearly decreases monotonically, asymptotically approaching Q=0 as n approaches infinity. In other words, for n >=3, it's largest at n = 3.

an odd math problem that just popped into my head

@noelle Though I suppose if you want something more concrete than visual inspection you could note that as n -> infinity, sin(pi/n) -> sin(0) == 1, and so sin(pi/n)/(1 - sin(pi/n)) -> 0/1 = 0.

an odd math problem that just popped into my head

@noelle No wait, shit, I just maximized Q. Which isn't the original question. I gotta do some work today, so I can figure out maximizing X later.

an odd math problem that just popped into my head

@noelle I took a stab at it: pastebin.com/VUMRJLpp

I don't think there's a single solution. Writing out the blue area (line 58) and taking the derivative with respect to r (necessary to find min/max) gives no real results, according to WolframAlpha. I suspect the answer is "as many circles as possible" (also stated "tiniest r possible").

I'm also pretty rusty with my calculus, so I could've missed something obvious here.

an odd math problem that just popped into my head

@noelle That said, thank you for the nerd snipe! 😄

It's been a while since I've seen an interesting math problem that still seemed feasible for me to work on. That was definitely an interesting few hours sorting that out.

an odd math problem that just popped into my head

@bluejeans @noelle you have a small problem in your reasoning, in that you're maximizing the blue area _when the red circle is constant_.

And in that case, adding more yellow circles increases the size of the circumscribed (blue) circle more than the sum of the areas of the yellow circles shrink.

But if you hold the radius of the blue circle (the circumscribed circle) constant, and only look at the ratio of r to R... [cont]

an odd math problem that just popped into my head

@bluejeans @noelle ...then we're actually interested in the ratio of the blue area to the area of the circumscribed circle, and that is biggest when there are 2 yellow circles around a red "circle" with radius 0 and area 0.

Then the yellow circle each will be pi*0.25*0.25, which gives us a total yellow plus red area of
pi*0.25*0.25*2
= pi*0.125

Compared to the constant total area of pi.

an odd math problem that just popped into my head

@bluejeans @noelle interestingly, the total area of yellow circles is largest at n=4 (four yellow circles).

But from that point the red circle grows faster than the total area of yellow circles shrink. The red circle is growing towards the limit of the circumscribed circle.

an odd math problem that just popped into my head

@zatnosk @noelle I listed a couple of assumptions in that paste. Notably, I assumed both r and R > 0. Because the question was only interested in the _ratio_ of r to R, the particular values don't matter, so I fixed R = 1 to make r the ratio.

I think you're right in that there is an error here, but I don't think it's that specifically given the assumptions I made.

I'll work on it some more today and get back to y'all.

an odd math problem that just popped into my head

@zatnosk @noelle Ok, so this took longer than I expected, but I wrote up a Jupyter notebook because I wanted some visuals in my math: nbviewer.jupyter.org/gist/nick

The mistake I found was in my definition of blue_area, where the radius of the blue circle was wrong (was 1 + r, should have been 1 + 2r). I've fixed this and analyzed the cases where non-zero radii make sense.

The answer is 5 circles, with the yellow/red ratio of approx. 2.65688. The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!