maximum area of three circles

Hi I am new here and have a calculus question that came up at work.

Suppose you have a $4' \times 8'$ piece of plywood. You need 3 circular pieces all equal diameter. What is the maximum size of circles you can cut from this piece of material? I would have expected I could write a function for the area of the 3 circles in terms of $x$ and $y$, then differentiate it, find a point of maxima/minima and go from there.

My coworker did cut three $33''$ circles and that solved the real-world problem. But my passion would be to find the mathematical answer to this. I hope that my new stackexchange.com friends have the same passion, and can help me find the answer to this in general terms.

What I mean by that is someone says I have a piece of material Q units by 2Q units, what are the three circles of maximum size?... I hope you understand what I am asking. I am looking to be a friend and contributor BD


Solution 1:

I believe the optimal configuration is as shown below, with the circles tangent to the sides of the rectangle and to one another.

diagram

Let the rectangle have sides of length $Q$ and $2Q$, as you specified, and let the radius of all three circles be $r$. Consider the right triangle with the segment joining the centers of the left and middle circles as its hypotenuse and with legs parallel to the sides of the rectangle.

diagram with triangle

The hypotenuse has length $2r$, and the legs have lengths $Q-r$ and $Q-2r$, so by the Pythagorean theorem, $(2r)^2=(Q-r)^2+(Q-2r)^2$. Solving for $r$ in terms of $Q$ gives $r=(3\pm\sqrt{7})Q$, but since $r<Q$, $r=(3-\sqrt{7})Q\approx 0.354249Q$. For your 4-by-8 board, that gives an optimal radius of approximately $0.354249\cdot 48\approx 17.0039$ inches, so a diameter of just over 34 inches.

Solution 2:

Isaac had the right intuition.

alt text

I used Matlab to globally optimize the radius under the constrait that all three circles have the same radius, are in the rectangle and don't intersect each other. What I got is shown above,

R = 1.41699,

Pos1 = (6.58301,2.58301)

Pos2 = (1.41699,2.58301)

Pos3 = (4.0,1.41699)

Note that 1.41699"=17.00388 inches so Isaac found the analytic solution.

Due to request here the Matlab source (yes Matlab is indeed more powerful than u think):

circleradius.m:

%% x = [pos1X,pos1Y,pos2X,pos2Y,pos3X,pos3Y,r]
function f = circleradius(x)
f = -x(7); %% minimize the maximum :D

constraints.m

%% x = [pos1X,pos1Y,pos2X,pos2Y,pos3X,pos3Y,r]
function [c, ceq] = contraints(x)
c = [4*x(7)^2 - ((x(1) - x(3))^2 + (x(2) - x(4))^2); %% d(Circle1,Circle2)<=(2r)^2
4*x(7)^2 - ((x(1) - x(5))^2 + (x(2) - x(6))^2);
4*x(7)^2 - ((x(3) - x(5))^2 + (x(4) - x(6))^2); 
x(7) - x(1);  %% Circles are in the rectangle
x(7) - x(3); 
x(7) - x(5); 
x(7) - x(2);
x(7) - x(4);
x(7) - x(6);
x(7) + x(1) - 8; %% Width is 8
x(7) + x(3) - 8;
x(7) + x(5) - 8;
x(7) + x(2) - 4; %% Height is 4
x(7) + x(4) - 4;
x(7) + x(6) - 4;
-x(1); -x(2); -x(3); -x(4); -x(5); -x(6); -x(7)]; %% No negative values
ceq = [ ];

Later in main window:

[x,fval,exitflag] = patternsearch(@circleradius,[0.5000 1 1.5000 1 2.5000 1 0.5000],[],[],[],[],[],[],@contraints)
output of x >> 4.0000    2.5830    1.4170    1.4171    6.5830    1.4171    1.4170

Note that the values are truncated and the above is a solution which is symmetric to what I posted before. You can make it use a mesh of size 10e-10, so you are almost sure to get the global maximum, as the function is continuous. Also the result is faster and more reliable than NMinimize of Mathematica.

Solution 3:

Let $Q:=[-2,2]\times[-1,1]$ be the given rectangle and let $r_0$ be the radius computed by Isaac for this rectangle. I shall prove that 3 circles of radius $r>r_0$ cannot be placed into $Q$ without overlap. The midpoints of these circles would have to lie in the smaller rectangle $Q':=[-2+r, 2-r]\times[-1+r,1-r]$. The left half $Q'_-$ of $Q'$ has a diameter $<2r_0<2r$ (by definition of $r_0$). It follows that $Q'_-$ can contain at most one center of non-overlapping circles of radius $r$, and the same is true for the right half $Q'_+$.