A Relaxing Geometry Problem
A Relaxing Geometry Problem
Question: Figure shows an equilateral triangle with side length equal to . Three squares of side length , and
placed side by side just fit inside the triangle as shown.Find the exact value of.
1
a
2a
3a
placed side by side just fit inside the triangle as shown.Find the exact value of
a
Dr Penn the interesting geometry problem on his channel today. You may watch the video to get idea about of the steps of derivation or go to this to read them. I am going to show how to use Wolfram language to create a nice visualization about the general case in which you can have more squares with arithmetic progression side length sitting in a equilateral triangle just like stated in the problem.
discussed
SElink
(Local) In[]:=
Clear[n]
The idea is that the side of the large triangle is the sum of the side of squares plus two trailing segments. Both trailing segments are computed using simple trigonometry
(Local) In[]:=
(Local) Out[]=
1
3
For three squares the two trailing segments are and . And everything in between sums up to . If I extend 3 to n, I have the following solution for (recall that it is the side length of the smallest square that we are looking for) in terms of using the same deduction.
a
3
3a
3
a(1+2+3)=6a
a
n
(Local) In[]:=
Solve+a*Sum[k,{k,n}]1,a
a+n*a
3
(Local) Out[]=
a
6
(1+n)(2
3
+3n)Then I need to how much a square in the list are shifted to right from the left most vertex of the bounding equilateral triangle (set at origin = {0,0}).
◼
the first square with side length : its bottom-left corner is at and upper-right corner
a
ax1
3
,0ax1
3
,0+ax{1,1}◼
the second square with side length : its bottom-left corner is at and upper-right corner
2a
ax1+1
3
,0ax1+1
3
,0+ax{2,2}=ax1+2+13
,2◼
the third square with side length : its bottom-left is at and upper-right corner
3a
ax1+2+1
3
,0ax1+2+1
3
,0+ax{3,3}=ax1+2+3+13
,3...
◼
the nth square with side length : its left bottom-left is at and upper-right corner
nxa
ax1+2+...+n-1+1
3
,0ax1+2+...+n-1+1
3
,0+ax{n,n}=ax1+2+3+...+n+13
,nThe pattern tells us that we can use the following formula to compute the sum of arithmetic progression from 1 to n.
(Local) In[]:=
(Local) Out[]=
1
2
I use the exact formula to compute the coordinates of two diagonal corners for each square. Then I insert them into Rectangle to draw each piece. Hue is added to make the list of rectangle vibrant.
(Local) In[]:=
squareList[n_]:=Witha=,TableHue+(-1+i)i,0,a*+(1+i)i,i,{i,n}
6
(1+n)2
3
+3ni/n
,1,1,0.7,Rectanglea*1
3
1
2
1
3
1
2
Eventually I wrap up the function above into a Manipulate function and play around the number of squares sitting in the triangle.
(Local) In[]:=
ManipulateGraphicsTransparent,EdgeForm[{Blue,Thick}],Triangle{0,0},{1,0},12,,{k,1,20,1}
3
2,squareList[k],PlotRange{0,1},-0.05,6*k*2.4
(1+k)2
3
+3k(Local) Out[]=
The PlotRange is tuned so that it does not truncate the top vertex of triangle when the number K is set to three and the plot window zooms in when there are many squares are generated. Notice that the side of largest square approaches zero when n approaches infinity
nxa
(Local) In[]:=
Limitn*,nInfinity
6
(1+n)2
3
+3n(Local) Out[]=
0
The plot of the above expression shows the same trend as n increases.
(Local) In[]:=
DiscretePlotn*,{n,1,12}
6
(1+n)2
3
+3n(Local) Out[]=