## Infinite Inscribed Squares

For the discussion of math. Duh.

Moderators: gmalivuk, Moderators General, Prelates

Squarian
Posts: 7
Joined: Mon Feb 15, 2016 8:23 pm UTC

### Infinite Inscribed Squares

Hello fellows! I just joined the forum to post a problem that looks easy enough, but has been defying me for the past few days, here it is (I made it up, so I don't have a solution nor a correct spelling, but I will try ):

Given a circumference O and an inscribed square ABCD whose side lenght is l. Inscribe now a square EFGH in AB in a way that EF lies on the square side AB and G and H lie on the circumference. Inscribe now a square in GH and so on to infinity.
Find the sum of the areas of the squares.

Thank you in advance, be sure to ask for clarifications.

EDIT: For the mods, you can delete my second topic, I thought I didn't hit "submit" or something. Instead it was just waiting to be approved
Last edited by Squarian on Tue Feb 16, 2016 4:51 pm UTC, edited 1 time in total.

Xanthir
My HERO!!!
Posts: 5426
Joined: Tue Feb 20, 2007 12:49 am UTC
Location: The Googleplex
Contact:

### Re: Infinite Inscribed Squares

Squarian wrote:Given a circumference O and an inscribed square ABCD whose side lenght is l.

Did you means "1"? Naming a variable lowercase L is terrible practice in any case, but also, since this is the only length given, naming it and just setting it equal to 1 are equivalent.

Inscribe now a square EFGH in AB

What do you mean by "in AB"? AB is one of the sides of the square, you can't put another square inside of it. The dimensions are wrong.

in a way that EF lies on the square side AB and G and H lie on the circumference. Inscribe now a square in GH and so on to infinity.

So EFGH is a "hat" on top of the first square, fitting snugly between ABCD's side and the circumscribing circle?
(defun fibs (n &optional (a 1) (b 1)) (take n (unfold '+ a b)))

PM 2Ring
Posts: 3715
Joined: Mon Jan 26, 2009 3:19 pm UTC
Location: Sydney, Australia

### Re: Infinite Inscribed Squares

Let the circle be centered at the origin, with radius 1.
We'll construct the sequence of squares along the positive X axis.
Let (x, y) be the coordinates of the top right corner of a square, so for each square x² + y² = 1 by Pythagoras' theorem. Let s be the side of a square.

The first square has x = y, so x0 = y0= sqrt(½), and s0 = sqrt(2), and its area is 2.

For the subsequent squares, the left edge of the square has the same X coordinate as the right edge of the previous square = xi-1, so the coordinates of its top right corner (xi, yi) = (xi-1 + si, si / 2).
To keep the algebra simple, let's write that as (x+s, s/2). We know x and we want to determine s.

Now (x+s)² + (s/2)² = 1
x² + 2sx + s² + s²/4 = 1
5s²/4 + 2xs + (x² - 1) = 0

We can solve that for s using the quadratic formula:
s = (-2x ± sqrt(4x² - 5(x² - 1))) / (5/2)
s > 0 so we can ignore the negative solution
s = (2/5) * (sqrt(5 - x²) - 2x)

With this equation we can now calculate the coordinates and area of each subsequent square, but I can't see a simple closed-form expression for them.

Substituting x0 = sqrt(½) we get
s = (2/5) * (sqrt(5 - ½) - sqrt(2))
= (2/5) * (sqrt(9/2) - sqrt(2))
= (2/5) * (3sqrt(2)/2 - sqrt(2))
s = sqrt(2) / 5

Unfortunately, after this, things start getting messy. But here's some Python 2 code that does the calculations.

Code: Select all

`# The x coordinate, side, and area of the initial central squarex = .5 ** .5s = 2 * xa = 2print 'i: x, s, a'for i in range(8):    print '%d: %.15f, %.15f, %.15f' % (i, x, s, a)    s = ((5 - x * x) ** 0.5 - 2 * x) * 0.4    a += s * s    x += s`

output

Code: Select all

`i: x, s, a0: 0.707106781186548, 1.414213562373095, 2.0000000000000001: 0.989949493661166, 0.282842712474619, 2.0800000000000002: 0.999987404962770, 0.010037911301604, 2.0801007596632993: 0.999999999980171, 0.000012595017400, 2.0801007598219334: 1.000000000000000, 0.000000000019829, 2.0801007598219335: 1.000000000000000, 0.000000000000000, 2.0801007598219336: 1.000000000000000, 0.000000000000000, 2.0801007598219337: 1.000000000000000, 0.000000000000000, 2.080100759821933`

As you can see, the total area converges rather quickly.
Here's a more accurate approximation for the total area, calculated using the mpmath library:
2.0801007598219333251352540471639420067242795178

The Inverse Symbolic Calculator couldn't find an expression for this number.

Squarian
Posts: 7
Joined: Mon Feb 15, 2016 8:23 pm UTC

### Re: Infinite Inscribed Squares

Xanthir wrote:
Squarian wrote:Given a circumference O and an inscribed square ABCD whose side lenght is l.

Did you means "1"? Naming a variable lowercase L is terrible practice in any case, but also, since this is the only length given, naming it and just setting it equal to 1 are equivalent.

No, I meant lowercase L. I'm italian, so L comes from the italian name for "side", muscle memory Inscribe now a square EFGH in AB

What do you mean by "in AB"? AB is one of the sides of the square, you can't put another square inside of it. The dimensions are wrong.

See next quote

in a way that EF lies on the square side AB and G and H lie on the circumference. Inscribe now a square in GH and so on to infinity.

So EFGH is a "hat" on top of the first square, fitting snugly between ABCD's side and the circumscribing circle?
Yep, exactly

@PM 2Ring
I like the analytical approach, at first I was trying to solve it with euclidean geometry, but I kept going in circles (pun non intended). I found a formula for sn but has "Sum of all the previous sides" (I don't know how to use LaTex ) in it and is kind of complicated.
Do you think there is any chance of a nice closed form expression or is it hopeless?

jestingrabbit
Factoids are just Datas that haven't grown up yet
Posts: 5967
Joined: Tue Nov 28, 2006 9:50 pm UTC
Location: Sydney

### Re: Infinite Inscribed Squares

PM 2Ring wrote:

Code: Select all

`i: x, s, a0: 0.707106781186548, 1.414213562373095, 2.0000000000000001: 0.989949493661166, 0.282842712474619, 2.0800000000000002: 0.999987404962770, 0.010037911301604, 2.0801007596632993: 0.999999999980171, 0.000012595017400, 2.0801007598219334: 1.000000000000000, 0.000000000019829, 2.0801007598219335: 1.000000000000000, 0.000000000000000, 2.0801007598219336: 1.000000000000000, 0.000000000000000, 2.0801007598219337: 1.000000000000000, 0.000000000000000, 2.080100759821933`

Is that from 32 or 64 bit calculations?
ameretrifle wrote:Magic space feudalism is therefore a viable idea.

ConMan
Shepherd's Pie?
Posts: 1691
Joined: Tue Jan 01, 2008 11:56 am UTC
Location: Beacon Alpha

### Re: Infinite Inscribed Squares

Taking a similar approach to PM 2Ring, but sticking with exact forms and doing it without coordinates:

Let the height of the nth square be hn, with h0 being the height of the biggest square.

It doesn't take much to show that h0 = sqrt(2), since the diagonal is a diameter of the circle.

For all the other squares, you can draw a line from the centre of the circle that bisects all of their bases. If you do that, you then have a sequence of right-angled triangles formed from that line, half of the bisected base, and the hypotenuse which is a radius of the circle. And the height of the triangle, which comes from that bisector, is equal to half the height of the largest square, plus the height of all the squares up to that point. In other words, the side lengths of the nth triangle are hn/2, sqrt(2)/2 + h1 + h2 + ... + hn, and hypotenuse 1. So we can apply Pythagoras' Theorem to create the recurrence relation:

(hn / 2)2 + (hn + hn-1 + ... + h1 + 1/2 h0)2 = 1

We can do a little tricksy manipulation to make that a little simpler - take the nth and (n-1)th relations and subtract them, then use difference of squares and some rearrangement to get:

5/4 hn2 + 2hn(hn-1 + hn-2 + ... + h1 + 1/2 h0) - 1/4 hn-12 = 0

We find that h1 = sqrt(2) / 5 from the original relation (i.e. the first triangle), and from then on we can theoretically find the heights of all the other squares. Unfortunately, it gets ugly pretty quickly - h2 = sqrt(2)/25 (sqrt(201) - 14) and h3 = (sqrt(2) (397/25-(28 sqrt(201))/25))/(14+4 sqrt(201)+sqrt(7 (771-4 sqrt(201)))), according to Wolfram Alpha. So it doesn't look like there's an nice little equation for the heights, nor their squares.

As PM 2Ring showed, the heights converge to zero incredibly fast, so you do get a perfectly good approximation of the area after only two or three terms are added.
pollywog wrote:
Wikihow wrote:* Smile a lot! Give a gay girl a knowing "Hey, I'm a lesbian too!" smile.
I want to learn this smile, perfect it, and then go around smiling at lesbians and freaking them out.

PM 2Ring
Posts: 3715
Joined: Mon Jan 26, 2009 3:19 pm UTC
Location: Sydney, Australia

### Re: Infinite Inscribed Squares

jestingrabbit wrote:Is that from 32 or 64 bit calculations?

I'm running Python 2.6.6 on a 32 bit machine. My Python's floats are IEEE-754 doubles, so they have 53 bits of precision. The more accurate value for the area was calculated with 50 decimal digits of precision; I chopped off the last couple of digits, so the digits you see should all be correct... assuming I didn't make a blunder with my algebra. jestingrabbit
Factoids are just Datas that haven't grown up yet
Posts: 5967
Joined: Tue Nov 28, 2006 9:50 pm UTC
Location: Sydney

### Re: Infinite Inscribed Squares

Cool. I was just a bit worried about the speed of the convergence, but I believe it now.
ameretrifle wrote:Magic space feudalism is therefore a viable idea.

Squarian
Posts: 7
Joined: Mon Feb 15, 2016 8:23 pm UTC

### Re: Infinite Inscribed Squares

ConMan wrote:Taking a similar approach to PM 2Ring, but sticking with exact forms and doing it without coordinates:

Let the height of the nth square be hn, with h0 being the height of the biggest square.

It doesn't take much to show that h0 = sqrt(2), since the diagonal is a diameter of the circle.

For all the other squares, you can draw a line from the centre of the circle that bisects all of their bases. If you do that, you then have a sequence of right-angled triangles formed from that line, half of the bisected base, and the hypotenuse which is a radius of the circle. And the height of the triangle, which comes from that bisector, is equal to half the height of the largest square, plus the height of all the squares up to that point. In other words, the side lengths of the nth triangle are hn/2, sqrt(2)/2 + h1 + h2 + ... + hn, and hypotenuse 1. So we can apply Pythagoras' Theorem to create the recurrence relation:

(hn / 2)2 + (hn + hn-1 + ... + h1 + 1/2 h0)2 = 1

We can do a little tricksy manipulation to make that a little simpler - take the nth and (n-1)th relations and subtract them, then use difference of squares and some rearrangement to get:

5/4 hn2 + 2hn(hn-1 + hn-2 + ... + h1 + 1/2 h0) - 1/4 hn-12 = 0

We find that h1 = sqrt(2) / 5 from the original relation (i.e. the first triangle), and from then on we can theoretically find the heights of all the other squares. Unfortunately, it gets ugly pretty quickly - h2 = sqrt(2)/25 (sqrt(201) - 14) and h3 = (sqrt(2) (397/25-(28 sqrt(201))/25))/(14+4 sqrt(201)+sqrt(7 (771-4 sqrt(201)))), according to Wolfram Alpha. So it doesn't look like there's an nice little equation for the heights, nor their squares.

As PM 2Ring showed, the heights converge to zero incredibly fast, so you do get a perfectly good approximation of the area after only two or three terms are added.

Are you positive that there isn't a "nice" expression? I'm not trying to say that there has to be one, in fact I can't find one myself, but it seems weird to me that such a seemingly simple problem becomes complicated so easily. (Again, I guess the sum of the reciprocals of the cubes dosen't give a simple expression either, so...yeah )

ConMan
Shepherd's Pie?
Posts: 1691
Joined: Tue Jan 01, 2008 11:56 am UTC
Location: Beacon Alpha

### Re: Infinite Inscribed Squares

Squarian wrote:Are you positive that there isn't a "nice" expression? I'm not trying to say that there has to be one, in fact I can't find one myself, but it seems weird to me that such a seemingly simple problem becomes complicated so easily. (Again, I guess the sum of the reciprocals of the cubes dosen't give a simple expression either, so...yeah )

Well, I'm mainly basing it on the fact that the third term in the sequence already requires a double square root and has a bunch of numbers that don't obviously look nice. So it's not guaranteed, but I would be extremely surprised if you could do anything neatly.
pollywog wrote:
Wikihow wrote:* Smile a lot! Give a gay girl a knowing "Hey, I'm a lesbian too!" smile.
I want to learn this smile, perfect it, and then go around smiling at lesbians and freaking them out.

ConMan
Shepherd's Pie?
Posts: 1691
Joined: Tue Jan 01, 2008 11:56 am UTC
Location: Beacon Alpha

### Re: Infinite Inscribed Squares

Although, you may be happy to learn, that I finally coaxed Wolfram Alpha into simplifying it a little bit, so h3 = sqrt(2)/125(-14-4sqrt(201)-sqrt(7(771-4sqrt(201)))).
pollywog wrote:
Wikihow wrote:* Smile a lot! Give a gay girl a knowing "Hey, I'm a lesbian too!" smile.
I want to learn this smile, perfect it, and then go around smiling at lesbians and freaking them out.

Return to “Mathematics”

### Who is online

Users browsing this forum: No registered users and 9 guests