• No results found

We have only scratched the surface of the beautiful number patterns satisfied by the Fibonacci numbers. You may be tempted to guess that these numbers must be counting something other than pairs of rabbits.

Indeed, Fibonacci numbers arise as the solution to many counting prob-lems. In 1150 (before Leonardo of Pisa wrote about rabbits), the Indian poet Hemachandra asked how many cadences of length n were possible if a cadence could contain short syllables of length one or long syllables of length two. We state the question in simpler mathematical terms.

Question: How many ways can we write the number n as a sum of 1s and 2s?

Answer: Let’s call the answer fn and examine fn for some small values of n.

n 12 Sequences That Add ton fn

1 1 1

2 11, 2 2

3 111, 12, 21 3

4 1111, 112, 121, 211, 22 5

5 11111, 1112, 1121, 1211, 122, 2111, 212, 221 8

... ... ...

There is one sum that adds to 1, two sums that add to 2 (1+1 and 2), and 3 sums that add to 3 (1+1+1, 1+2, 2+1). Note that we are only allowed to use the numbers 1 and 2 in our sums. Also, the order of the numbers being added matters. So, for example, 1+2 is different from 2+1. There are 5 sums that add to 4 (1+1+1+1, 1+1+2, 1+2+1, 2+1+1, 2+2). The numbers in our table seem to suggest that the numbers will be Fibonacci numbers, and indeed that is the case.

Let’s see why there are f5 =8 sums that add to the number 5. Such a sum must begin with a 1 or 2. How many of them begin with 1? Well, after the 1, we must have a sequence of 1s and 2s that sum to 4, and we know there are f4 = 5 of them. Likewise, how many of the sums that add to 5 begin with the number 2? After the initial 2, the remaining terms must add to 3, and there are f3 = 3 of those. Hence the total number of sequences that add to 5 must be 5+3=8. By the same logic, the number of sequences that add to 6 is 13, since f5 = 8 begin with 1 and f4 = 5 begin with 2. In general, there are fnsequences that add to n. Of these, fn1begin with 1 and fn2begin with 2. Consequently,

fn=fn−1+fn−2

Thus, the numbers fn begin like the Fibonacci numbers and will con-tinue to grow like the Fibonacci numbers. Therefore they are the Fi-bonacci numbers, but with a twist, or perhaps I should say a shift. No-tice that f1 = 1 = F2, f2 = 2 = F3, f3 = 3 = F4, and so on. (For convenience, we define f0 = F1 = 1 and f1 = F0 = 0.) In general, we have, for n 1,

fn=Fn+1

Once we know what the Fibonacci numbers count, we can exploit that knowledge to prove many of their beautiful number patterns. Re-call the pattern that we saw at the end of Chapter 4 when we summed the diagonals of Pascal’s triangle.

1

For example, summing the eighth diagonal gave us 1+7+15+10+1=34=F9

In terms of the “choose numbers,” this says

8

Let’s try to understand this pattern by answering a counting question in two ways.

Question: How many sequences of 1s and 2s add to 8?

Answer 1: By definition, there are f8 =F9such sequences.

Answer 2: Let’s break this answer into 5 cases, depending on the number of 2s that are used. How many use no 2s? There’s just one way to do this, namely11111111—and not coincidentally,(80) =1.

How many use exactly one 2? This can be done 7 ways: 2111111, 1211111, 1121111, 1112111, 1111211, 1111121, 1111112. Such sequences have 7 numbers, and there are (71) = 7 ways to choose the location of the 2.

How many use exactly two 2s? A typical example would be221111. Instead of listing all 15 of them, note that any such sequence would have two 2s and four 1s, and therefore six digits altogether. There are

(62) =15 ways to choose the locations of the two 2s. By the same logic, a sequence with exactly three 2s would have to have two 1s and therefore have five digits altogether; such sequences could be created in(53) =10 ways. And finally, a sequence with four 2s can only be created(44) =1 way, namely2222.

Comparing answers 1 and 2 gives us the desired explanation. In general, the same argument can be applied to prove that whenever we sum the nth diagonal of Pascal’s triangle, we get a Fibonacci number.

Specifically, for all n 0, when we sum the nth diagonal (until we fall off the triangle after about n/2 terms), we get

n 0

 +

n−1 1

 +

n−2 2

 +

n−3 3



+· · ·=fn=Fn+1

An equivalent and more visual way to think about the Fibonacci numbers is through tilings. For example, f4 = 5 counts the five ways to tile a strip of length 4 using squares (of length 1) and dominos (of length 2). For example, the sum 1+1+2 is represented by the tiling square-square-domino.

1 + 1 + 1 + 1

1 + 1 + 2

1 + 2 + 1

2 + 1 + 1

2 + 2

There are 5 tilings of length 4, using squares and dominos, illustratingf4=5

We can use tilings to understand another remarkable Fibonacci num-ber pattern. Let’s look at what happens when we square the Fibonacci numbers.

n 0 1 2 3 4 5 6 7 8 9 10

fn 1 1 2 3 5 8 13 21 34 55 89

fn2 1 1 4 9 25 64 169 441 1156 3025 7921

The squares of Fibonacci numbers, fromf0tof10

Now, it’s no surprise that when you add consecutive Fibonacci num-bers, you get the next Fibonacci number. (That’s how they’re created, after all.) But you wouldn’t expect anything interesting to happen with the squares. However, check out what happens when we add consecu-tive squares together:

f02+f12 = 12+12 = 1+1 = 2 = f2

f12+f22 = 12+22 = 1+4 = 5 = f4

f22+f32 = 22+32 = 4+9 = 13 = f6

f32+f42 = 32+52 = 9+25 = 34 = f8

f42+f52 = 52+82 = 25+64 = 89 = f10

...

Let’s try to explain this pattern in terms of counting. The last equa-tion says that

f42+f52 =f10

Why should that be? We can explain this by asking a simple counting question.

Question: How many ways can you tile a strip of length 10 using squares and dominos?

Answer 1: By definition, there are f10such tilings. Here is a typical tiling, which represents the sum 2+1+1+2+1+2+1.

1 2 3 4 5 6 7 8 9 10

We say that this tiling is breakable at cells 2, 3, 4, 6, 7, 9, and 10. (Equiv-alently, the tiling is breakable everywhere except the middle of a domino.

In this example, it is unbreakable at cells 1, 5, and 8.)

Answer 2: Let’s break the answer into two cases: those tilings that are breakable at cell 5, and those tilings that are not. How many ways

can we create a length-10 tiling that is breakable at cell 5? Such a tiling can be split into two halves, where the left half can be tiled in f5 = 8 ways and the right half can also be tiled in f5 = 8 ways. Hence by the rule of product in Chapter 4, we can create such a sum in f52 =82ways, as illustrated below.

1 2 3 4 5 6 7 8 9 10

f5waysways f5waysways f52waysways

There aref52tilings of length 10 that are breakable at cell 5

How many length-10 tilings are not breakable at cell 5? Such tilings must necessarily have a domino covering cells 5 and 6, as illustrated below. Now the left half and right half can each be tiled f4 = 5 ways and so there are f42 = 52 unbreakable tilings. Putting these two cases together, it follows that f10 = f52+ f42, as desired.

1 2 3 4 5 6 7 8 9 10

f4waysways f4waysways f42waysways

There aref42tilings of length 10 that are not breakable at cell 5

In general, by considering whether a tiling of length 2n is breakable in the middle or not, we arrive at the beautiful pattern

f2n =fn2+fn−12 Aside

After seeing the previous identity, we might try to extend it to similar cases. For example, consider the number of tilings of length m+n. How many of these tilings are breakable at cell m? The left side can be tiled fm ways and the right side can be tiled fnways, so there are fmfn such tilings. How many are not breakable at m? Such a tiling must have a domino covering cells m and m+1, and the rest of the tiling can be tiled fm−1fn−1 ways. Altogether, we get the following useful identity. For m, n0,

fm+n=fmfn+fm−1fn−1

Time for a new pattern. Let’s see what happens when we add all of the squares of Fibonacci numbers together.

12+12 = 2 = 1×2 12+12+22 = 6 = 2×3 12+12+22+32 = 15 = 3×5 12+12+22+32+52 = 40 = 5×8 12+12+22+32+52+82 = 104 = 8×13

...

Wow, this is so cool! The sum of the squares of Fibonacci numbers is the product of the last two! But why should the sum of the squares of 1, 1, 2, 3, 5, and 8 add to 8×13? One way to “see” this with geometric figures is to take six squares with side lengths 1, 1, 2, 3, 5, and 8 and assemble them as in the figure below.

1 1

2

3

5

8

Start with a 1-by-1 square, then put the other 1-by-1 square next to it, creating a 1-by-2 rectangle. Beneath that rectangle, put the 2-by-2 square, which creates a 3-by-2-by-2 rectangle. Next to the long edge of that rectangle, place the 3-by-3 square (creating a 3-by-5 rectangle), then place the 5-by-5 square underneath that (creating an 8-by-5 rectangle).

Finally, place the 8-by-8 square next to that, creating one giant 8-by-13 rectangle. Now let’s ask a simple question.

Question: What is the area of the giant rectangle?

Answer 1: On the one hand, the area of the rectangle is the sum of the areas of the squares that compose it. In other words, the area of this rectangle must be 12+12+22+32+52+82.

Answer 2: On the other hand, we have a big rectangle with height 8 and a base length of 5+8=13, hence the area of this rectangle must be 8×13.

Since both answers are correct, they must give the same area, which explains the last identity. In fact, if you read again how the rectangle was constructed, you see that it explains all of the relationships listed about this pattern (like 12+12+22+32+52 = 5×8). And if you continue this logic, you will create rectangles of size 13×21, 21×34, and so on, so the pattern will continue forever. The general formula says that

12+12+22+32+52+82+· · · +Fn2 =FnFn+1

Now let’s see what happens when we multiply Fibonacci neighbors together. For example, the neighbors of 5 are 3 and 8, and their product is 3×8 = 24, which is one less than 52. The neighbors of 8 are 5 and 13, and their product is 5×13 = 65, which is just one more than 82. Examining the table below, it’s hard to resist the conclusion that the product of the neighbors is always one away from the square of the original Fibonacci number. In other words,

Fn2− Fn−1Fn+1=±1

n 1 2 3 4 5 6 7 8 9 10 11

Fn 1 1 2 3 5 8 13 21 34 55 89

Fn2 1 1 4 9 25 64 169 441 1156 3025 7921

Fn−1Fn+1 0 2 3 10 24 65 168 442 1155 3026 7920 Fn2− Fn−1Fn+1 1 1 1 1 1 1 1 1 1 1 1

The product of the neighbors of a Fibonacci number is one away from its square

Using a proof technique (called induction) that we will learn in the next chapter, it can be proved that for n≥1,

Fn2− Fn−1Fn+1 = (1)n+1

Let’s push this pattern even further by looking at distant neighbors.

Look at the Fibonacci number F5 = 5. We saw that when we multiply its immediate neighbors, we get 3×8=24, which is one away from 52. But the same thing happens when we multiply the Fibonacci numbers that are two away from it: 2×13 = 26, which is also one away from 52. How about the neighbors that are 3 away, 4 away, or 5 away? Their products are 1×21=21, 1×34=34, and 0×55=0. How far away are

these numbers from 25? They are 4 away, 9 away, and 25 away, which are all perfect squares. But they’re not just any perfect squares; they are squares of Fibonacci numbers! See the table below for more evidence of this pattern. The general pattern is:

Fn2− Fn−rFn+r =±Fr2

n 1 2 3 4 5 6 7 8 9 10

Fn 1 1 2 3 5 8 13 21 34 55

Fn2 1 1 4 9 25 64 169 441 1156 3025 Fn2− Fn−rFn+r

Fn−1Fn+1 0 2 3 10 24 65 168 442 1155 3026 ±1 Fn−2Fn+2 0 5 8 26 63 170 440 1157 3024 ±1 Fn−3Fn+3 0 13 21 68 165 445 1152 3029 ±4 Fn−4Fn+4 0 34 55 178 432 1165 3016 ±9 Fn−5Fn+5 0 89 144 466 1131 3050 ±25

... ... ...

The product of distant neighbors of a Fibonacci number is always close to its square.

Their distance apart is always the square of a Fibonacci number.