Solving and checking a two-term recurrence
A rule that builds each term from the two before it gives every term in the end, but only by computing all the earlier ones first. Is there a formula that goes straight to the hundredth term?
Where you are 6 in Recurrence relations
When you reach for it
A rule of the form
with fixed numbers c_1 and c_2 \ne 0 and two starting values a_0, a_1, fixes every term, but only one at a time. Reach for this move when you want a_n straight from n: a far term, the rate of growth, or a fact about every term at once. Closed form versus recursive form turned one-term rules into formulas by spotting a pattern; a rule that looks back two places shows no pattern, yet its answer is still built from powers. The same method gives the closed formula for the Fibonacci numbers of The Fibonacci sequence, with the golden ratio in it. A second move belongs here too: checking a closed formula against the rule by Strong induction and well-ordering proves it for every n, however the formula was found.
Such a rule is a linear homogeneous recurrence of order two with constant coefficients: earlier terms are only multiplied by constants and added, nothing else is added, and it looks back two places. A solution is any sequence that obeys the rule for every n \ge 2, whatever its starting values.
The procedure
Day 1: trying a power
A geometric sequence obeys a one-term rule, so try one in the two-term rule. For r \ne 0, the sequence r^n is a solution exactly when
Dividing by r^{n-2}, which is not zero, turns every one of these equations into the same quadratic,
and multiplying by r^{n-2} reverses the step. This quadratic is the characteristic equation of the rule, and its roots are the characteristic roots. So r^n is a solution exactly when r is a characteristic root. The product of the roots is -c_2 \ne 0, so neither root is 0. The roots come from factoring or from the The quadratic formula.
Solutions also combine. If (s_n) and (t_n) are solutions and A, B are constants, then for n \ge 2, by the distributive property and regrouping,
so (As_n + Bt_n) is a solution too. Two roots therefore give a family Ar_1^n + Br_2^n, and the theorem says the family holds every solution.
Theorem (distinct roots). Suppose the characteristic equation of a_n = c_1 a_{n-1} + c_2 a_{n-2} has two different roots r_1 and r_2. Then for every solution (a_n) there is exactly one pair of constants A, B with
Proof. Let (a_n) be a solution. Any pair A, B that works must fit n = 0 and n = 1:
Subtracting r_1 times the first equation from the second leaves B(r_2 - r_1) = a_1 - r_1 a_0. Since r_2 - r_1 \ne 0,
So at most one pair works. Let b_n = A r_1^n + B r_2^n with this pair. By the two facts above (b_n) is a solution, and b_0 = a_0, b_1 = a_1 by the choice of A and B. We prove a_n = b_n for every n \ge 0 by strong induction. The cases n = 0 and n = 1 hold. Let n \ge 2 and assume a_k = b_k for every k < n. Both sequences obey the rule, so
Hence a_n = b_n for every n \ge 0. \square
So for a given rule: find the roots, write Ar_1^n + Br_2^n, and fix A and B from the two starting values.
Day 1: checking a closed form by induction
The induction at the end of that proof works for any formula f(n) proposed for the sequence with rule a_n = c_1 a_{n-1} + c_2 a_{n-2} and starting values a_0, a_1. Two things settle it:
- the base cases f(0) = a_0 and f(1) = a_1;
- the identity f(n) = c_1 f(n-1) + c_2 f(n-2) for every n \ge 2, which is algebra.
Then if a_k = f(k) for all k < n, we get a_n = c_1 f(n-1) + c_2 f(n-2) = f(n), and strong induction gives a_n = f(n) for every n \ge 0. Both base cases are needed, because a formula can obey the rule and still be a different solution (Example 2). This is the two-base-case induction of How induction works: base case, hypothesis and step and Strong induction and well-ordering.
Day 1: rules that look back one place
A rule a_n = c\,a_{n-1} + d with c \ne 1 adds a constant at each step, so it is not geometric. Shift it. A constant sequence p obeys the rule when p = cp + d, that is, \displaystyle p = \frac{d}{1 - c}. Subtracting p = cp + d from a_n = c\,a_{n-1} + d gives
so a_n - p is geometric with ratio c (Geometric sequences and the explicit formula), and
When c = 1 the rule is arithmetic and a_n = a_0 + nd.
Day 2: the Fibonacci numbers and the golden ratio
With F_0 = 0, F_1 = 1 and F_n = F_{n-1} + F_{n-2}, the characteristic equation is r^2 = r + 1. The quadratic formula gives two different roots,
The number \varphi is the golden ratio. Three facts do most of the work: \varphi + \psi = 1, \varphi\psi = -1 and \displaystyle \varphi - \psi = \sqrt{5}. Example 4 finds Binet’s formula,
Because |\psi| < 1, the term \psi^n shrinks toward 0. So F_n is the integer nearest to \displaystyle \varphi^n/\sqrt{5}, and the ratios F_{n+1}/F_n approach \varphi (Example 5).
Day 2: negative and irrational roots
The theorem asks only that the roots be different, not positive or rational. A negative root r makes r^n change sign at every step; when it is the root of larger size, the terms eventually alternate in sign (Example 6). Irrational roots such as \displaystyle 1 \pm \sqrt{3} come as a pair \displaystyle u \pm \sqrt{w} when c_1 and c_2 are rational, and with rational starting values the square roots cancel in every term (Example 7). If |r_1| > |r_2| and A \ne 0, the term Ar_1^n takes over and a_{n+1}/a_n approaches r_1 (Exercise 20).
Worked examples
Day 1: two whole-number roots
Solve a_n = 5a_{n-1} - 6a_{n-2} with a_0 = 1 and a_1 = 4, and find a_{10}.
SolutionThe characteristic equation is r^2 - 5r + 6 = 0, which factors as (r - 2)(r - 3) = 0. The roots 3 and 2 are different, so by the theorem a_n = A \cdot 3^n + B \cdot 2^n for one pair A, B. The starting values give
Subtracting twice the first equation from the second gives A = 2, and then B = -1. So
Check. The rule gives a_2 = 5 \cdot 4 - 6 \cdot 1 = 14 and a_3 = 5 \cdot 14 - 6 \cdot 4 = 46; the formula gives 2 \cdot 9 - 4 = 14 and 2 \cdot 27 - 8 = 46. Then a_{10} = 2 \cdot 59{,}049 - 1024 = 117{,}074. Since a_n is a little under 2 \cdot 3^n, each term is close to three times the one before.
Day 1: a proof without a derivation
A sequence has s_0 = 2, s_1 = 5 and s_n = 5s_{n-1} - 4s_{n-2} for n \ge 2. Prove that s_n = 4^n + 1 for every n \ge 0. Then show that 4^n + 2 also obeys the rule, and explain why that does not contradict the claim.
SolutionProof. Let f(n) = 4^n + 1. Base cases: f(0) = 1 + 1 = 2 = s_0 and f(1) = 4 + 1 = 5 = s_1. The identity: for n \ge 2, using 4 \cdot 4^{n-2} = 4^{n-1},
Now let n \ge 2 and assume s_k = f(k) for every k < n. Then s_n = 5s_{n-1} - 4s_{n-2}, which is 5f(n-1) - 4f(n-2) = f(n). By strong induction, s_n = 4^n + 1 for every n \ge 0. \square
The same algebra with 2 in place of 1 gives 5(4^{n-1} + 2) - 4(4^{n-2} + 2) = 4^n + 10 - 8 = 4^n + 2, so 4^n + 2 obeys the rule as well (any constant does, since 1 is a root of r^2 - 5r + 4). It starts 3, 6, not 2, 5: a different solution. Checking the rule without the base cases would “prove” both formulas.
Day 1: Mirza’s humidifier
Mirza’s humidifier has 3 liters of water in its tank at the start. Each day it sends one third of the water in the tank into the air, and each evening Mirza pours in 2 liters. Let w_n be the water in the tank after n evenings. Find a formula for w_n, and find the first evening after which the tank holds more than 5.9 liters.
SolutionAfter a day, \displaystyle \frac{2}{3} of the water is left, and then 2 liters go in, so w_0 = 3 and \displaystyle w_n = \frac{2}{3} w_{n-1} + 2. A level that would stay put satisfies \displaystyle p = \frac{2}{3}p + 2, so \displaystyle \frac{1}{3}p = 2 and p = 6. Subtracting \displaystyle 6 = \frac{2}{3} \cdot 6 + 2 from the rule gives \displaystyle w_n - 6 = \frac{2}{3}(w_{n-1} - 6). So w_n - 6 is geometric with first term w_0 - 6 = -3 and ratio \displaystyle \frac{2}{3}:
Check: the rule gives w_1 = 2 + 2 = 4 and the formula gives 6 - 2 = 4. The level rises toward 6 liters and never reaches it. It is above 5.9 liters when \displaystyle 3\left(\frac{2}{3}\right)^n < 0.1, that is, when \displaystyle \left(\frac{3}{2}\right)^n > 30. Since \displaystyle \left(\frac{3}{2}\right)^8 \approx 25.6 and \displaystyle \left(\frac{3}{2}\right)^9 \approx 38.4, the first such evening is the ninth, with w_9 \approx 5.92 liters.
Day 2: the Fibonacci formula
Derive Binet’s formula from F_0 = 0, F_1 = 1 and F_n = F_{n-1} + F_{n-2}, and check it at n = 3.
SolutionThe roots \varphi and \psi of r^2 - r - 1 = 0 differ by \displaystyle \sqrt{5}, so by the theorem F_n = A\varphi^n + B\psi^n. From F_0 = 0, A + B = 0, so B = -A. From F_1 = 1, A\varphi - A\psi = 1, that is, \displaystyle A\sqrt{5} = 1, so \displaystyle A = \frac{1}{\sqrt{5}} and \displaystyle B = -\frac{1}{\sqrt{5}}. Hence
Check at n = 3: by the binomial theorem, \displaystyle (1 \pm \sqrt{5})^3 = 1 \pm 3\sqrt{5} + 15 \pm 5\sqrt{5} = 16 \pm 8\sqrt{5}, so \displaystyle \varphi^3 - \psi^3 = \frac{16\sqrt{5}}{8} = 2\sqrt{5}, and the formula gives 2 = F_3. The theorem guarantees whole numbers, despite the halves and the \displaystyle \sqrt{5}.
Day 2: rounding and ratios
Prove that F_n is the integer nearest to \displaystyle \varphi^n/\sqrt{5} for every n \ge 0, and use it to find F_{20} from \varphi^{20} \approx 15{,}126.99993. Then prove that F_{n+1}/F_n approaches \varphi.
SolutionProof. By Binet’s formula, \displaystyle \frac{\varphi^n}{\sqrt{5}} - F_n = \frac{\psi^n}{\sqrt{5}}. Since \displaystyle |\psi| = \frac{\sqrt{5} - 1}{2} < 1, we have |\psi^n| \le 1 for n \ge 0, so \displaystyle \frac{\varphi^n}{\sqrt{5}} lies within \displaystyle \frac{1}{\sqrt{5}} < \frac{1}{2} of the integer F_n, which is therefore the nearest integer to it. \square
For n = 20: \displaystyle 15{,}126.99993/\sqrt{5} \approx 6765.00003, so F_{20} = 6765, as in the table of The Fibonacci sequence.
For the ratios, Binet’s formula gives \displaystyle \sqrt{5}\,(F_{n+1} - \varphi F_n) = -\psi^{n+1} + \varphi\psi^n, since the \varphi^{n+1} terms cancel. So
Dividing by F_n \ge 1 for n \ge 1,
which is at most |\psi|^n in size and so tends to 0. Hence F_{n+1}/F_n \to \varphi. \square Since \psi^n is positive for even n and negative for odd n, the ratios fall alternately above and below \varphi, each closer than the last: \displaystyle \frac{13}{8} = 1.625, \displaystyle \frac{21}{13} \approx 1.6154, \displaystyle \frac{34}{21} \approx 1.6190.
Day 2: terms that alternate in sign
Solve a_n = -3a_{n-1} + 4a_{n-2} with a_0 = 2 and a_1 = -3, and describe the signs of the terms.
SolutionThe characteristic equation r^2 + 3r - 4 = 0 factors as (r + 4)(r - 1) = 0, with roots -4 and 1. So a_n = A(-4)^n + B \cdot 1^n = A(-4)^n + B, with
Subtracting the second equation from the first, 5A = 5, so A = 1 and B = 1:
The terms are 2, -3, 17, -63, 257, and the rule agrees: a_2 = -3(-3) + 4 \cdot 2 = 17. For n \ge 1, |(-4)^n| = 4^n \ge 4 > 1, so a_n has the sign of (-4)^n: positive for even n, negative for odd n. The root of larger size is negative, and it alone sets the signs.
Day 2: strings with no two a’s in a row
In Setting up a recurrence from a counting problem, the number g_n of strings of length n over \{a, b, c\} with no two a’s in a row was found to satisfy g_n = 2g_{n-1} + 2g_{n-2} for n \ge 2, with g_0 = 1 and g_1 = 3. Find a closed formula, and use it to find g_{10}.
SolutionThe characteristic equation r^2 - 2r - 2 = 0 has roots \displaystyle r = \frac{2 \pm \sqrt{12}}{2} = 1 \pm \sqrt{3}, different and irrational. So \displaystyle g_n = A(1 + \sqrt{3})^n + B(1 - \sqrt{3})^n, with
Hence \displaystyle A - B = \frac{2}{\sqrt{3}} = \frac{2\sqrt{3}}{3}, which with A + B = 1 gives \displaystyle A = \frac{3 + 2\sqrt{3}}{6} and \displaystyle B = \frac{3 - 2\sqrt{3}}{6}:
Check at n = 2: \displaystyle (3 \pm 2\sqrt{3})(4 \pm 2\sqrt{3}) = 24 \pm 14\sqrt{3}, so \displaystyle g_2 = \frac{48}{6} = 8, as counted there. Here B \approx -0.077 and \displaystyle |1 - \sqrt{3}| \approx 0.732 < 1, so the second term is below 0.08 in size for every n, and g_n is the integer nearest to \displaystyle \frac{3 + 2\sqrt{3}}{6}(1 + \sqrt{3})^n. For n = 10 that number is about 24{,}960.003, so g_{10} = 24{,}960 of the 3^{10} = 59{,}049 strings.
Boundaries
- Constant coefficients. Rules such as a_n = n\,a_{n-1} or a_n = a_{n-1}^2 are not of this kind, and powers do not solve them. A rule looking back k places works the same way with a characteristic equation of degree k, stated here without proof.
- c_2 \ne 0. Otherwise 0 is a root and the rule looks back only one place.
- Different roots. For a double root r, the family Ar^n + Br^n = (A + B)r^n has one free constant and cannot match every pair of starting values; see Two-term recurrences with a repeated root.
- Real roots here. When c_1^2 + 4c_2 < 0 the roots are complex. The theorem still holds with complex A and B, but that is not pursued here (Exercise 21).
- Homogeneous rules. An added constant needs the shift of Day 1, which needs c \ne 1. For a_n = c_1 a_{n-1} + c_2 a_{n-2} + d the shift \displaystyle p = \frac{d}{1 - c_1 - c_2} works when 1 is not a characteristic root (Exercise 12).
- Rounding needs a small second term, \displaystyle |Br_2^n| < \frac{1}{2}, as for F_n and g_n.
- The ratio limit needs A \ne 0. The rule of Example 1 with a_0 = 2, a_1 = 4 gives a_n = 2^{n+1}, whose ratios are 2, not the larger root 3.
Where this goes next
Two-term recurrences with a repeated root finishes the two-term case: a double root r brings in nr^n beside r^n. Setting up a recurrence from a counting problem supplies rules to solve. The ratio limits of Example 5 and Exercise 20 rest on Convergence of sequences. The idea of trying an exponential and getting a polynomial returns in differential equations with constant coefficients, and in linear algebra, where the step from (a_{n-1}, a_n) to (a_n, a_{n+1}) is a matrix whose eigenvalues are the characteristic roots.
Exercises
Day 1: two different roots
- Solve a_n = 7a_{n-1} - 12a_{n-2} with a_0 = 3 and a_1 = 10.
- Solve a_n = 6a_{n-1} - 5a_{n-2} with a_0 = 0 and a_1 = 8.
- Solve a_n = 9a_{n-1} - 20a_{n-2} with a_0 = 1 and a_1 = 3, and find the first negative term.
- Solve 9a_n = 9a_{n-1} - 2a_{n-2} with a_0 = 2 and a_1 = 1.
- A sequence has a_1 = 1, a_2 = 11 and a_n = 8a_{n-1} - 15a_{n-2} for n \ge 3. Find a closed formula valid for n \ge 1.
Day 1: checking formulas and shifting
- A sequence has a_0 = 0, a_1 = 4 and a_n = 8a_{n-1} - 12a_{n-2} for n \ge 2. Prove by induction, without solving, that a_n = 6^n - 2^n for every n \ge 0.
- A sequence has a_0 = 1, a_1 = 2 and a_n = 4a_{n-1} - 3a_{n-2} for n \ge 2. Its first three terms fit n^2 + 1. Show that the fit fails at n = 3, then find the correct closed formula and prove it by induction.
- Solve a_n = 5a_{n-1} - 8 with a_0 = 1.
- Solve \displaystyle a_n = \frac{1}{3}a_{n-1} + 8 with a_0 = 30, and say what the terms approach.
- Mirza’s savings account starts with \$1000. At the end of each month it earns 2\% interest, and then he withdraws \$50. Write a rule for the balance b_n after n months, find a closed formula, and find the first month in which the full withdrawal cannot be made.
Day 1: reasoning
- Show that the sequence 2^n + n (for n \ge 0) obeys no rule a_n = c_1 a_{n-1} + c_2 a_{n-2} with constants c_1 and c_2.
- Let a_n = c_1 a_{n-1} + c_2 a_{n-2} + d with c_1 + c_2 \ne 1, and \displaystyle p = \frac{d}{1 - c_1 - c_2}. Prove that b_n = a_n - p obeys b_n = c_1 b_{n-1} + c_2 b_{n-2}, then solve a_n = 2a_{n-1} + 3a_{n-2} - 8 with a_0 = a_1 = 4.
Day 2: the golden ratio
- Use \varphi^{15} \approx 1364.00073 to find F_{15}, and say how far \displaystyle \varphi^{15}/\sqrt{5} is from it.
- A sequence has u_0 = 4, u_1 = 1 and the Fibonacci rule u_n = u_{n-1} + u_{n-2}. Find its closed formula in terms of \varphi and \psi, and the limit of u_{n+1}/u_n.
- Prove that \varphi^n = F_n\varphi + F_{n-1} for every n \ge 1, and use it to write \varphi^6 in the form \displaystyle u + v\sqrt{5} with integers u and v.
Day 2: negative and irrational roots
- Solve a_n = 2a_{n-1} + 15a_{n-2} with a_0 = 0 and a_1 = 8, and show that every term after a_0 is positive.
- Solve a_n = -2a_{n-1} + 8a_{n-2} with a_0 = 1 and a_1 = -10, and prove that the terms alternate in sign.
- Solve a_n = 4a_{n-1} - a_{n-2} with a_0 = 2 and a_1 = 4. Use the answer to find the integer nearest to \displaystyle (2 + \sqrt{3})^6 without a calculator.
- In Setting up a recurrence from a counting problem, the tilings of a 2 by n board satisfy w_n = w_{n-1} + 2w_{n-2} with w_0 = w_1 = 1, and the formula \displaystyle w_n = \frac{2^{n+1} + (-1)^n}{3} was guessed and then proved. Derive it from the characteristic roots instead.
Day 2: reasoning
- Let a_n = Ar_1^n + Br_2^n with real r_1, r_2, |r_1| > |r_2| and A \ne 0. Prove that a_{n+1}/a_n approaches r_1. What does this say about the strings of Example 7?
- The rule a_n = a_{n-1} - a_{n-2} has characteristic equation r^2 - r + 1 = 0, which has no real roots. Prove that every solution repeats with period 6: a_{n+6} = a_n for every n \ge 0.
Answers
- a_n = 4^n + 2 \cdot 3^n. The roots are 3 and 4; with a_n = A \cdot 4^n + B \cdot 3^n, A + B = 3 and 4A + 3B = 10 give A = 1, B = 2.
- a_n = 2 \cdot 5^n - 2. The roots are 5 and 1, so a_n = A \cdot 5^n + B with A + B = 0 and 5A + B = 8: A = 2, B = -2.
- a_n = 2 \cdot 4^n - 5^n, and the first negative term is a_4 = -113. The roots are 4 and 5; A + B = 1 and 4A + 5B = 3 give A = 2, B = -1. The terms are 1, 3, 7, 3, -113: a_n < 0 exactly when \displaystyle \left(\frac{5}{4}\right)^n > 2, first at n = 4.
- \displaystyle a_n = \left(\frac{2}{3}\right)^n + \left(\frac{1}{3}\right)^n. The characteristic equation is 9r^2 - 9r + 2 = (3r - 1)(3r - 2) = 0, and A + B = 2, \displaystyle \frac{2}{3}A + \frac{1}{3}B = 1 give A = B = 1.
- a_n = 4 \cdot 5^{n-1} - 3^n. The roots are 3 and 5. With a_n = A \cdot 3^n + B \cdot 5^n, n = 1, 2 give 3A + 5B = 1 and 9A + 25B = 11, so \displaystyle B = \frac{4}{5} and A = -1.
- Proof. Let f(n) = 6^n - 2^n. Then f(0) = 0 and f(1) = 4, and for n \ge 2, 8f(n-1) - 12f(n-2) is 36 \cdot 6^{n-2} - 4 \cdot 2^{n-2}, which is f(n). Strong induction as in Example 2 finishes it. \square
- The rule gives a_2 = 5 and a_3 = 4 \cdot 5 - 3 \cdot 2 = 14, but 3^2 + 1 = 10. The roots are 1 and 3, and A + B = 1, 3A + B = 2 give \displaystyle A = B = \frac{1}{2}: \displaystyle a_n = \frac{3^n + 1}{2}. Proof. f(0) = 1, f(1) = 2, and 4f(n-1) - 3f(n-2) is \displaystyle \frac{4 \cdot 3^{n-1} + 4 - 3^{n-1} - 3}{2}, which is \displaystyle \frac{3^n + 1}{2}; strong induction finishes it. \square
- a_n = 2 - 5^n. The fixed level solves p = 5p - 8, so p = 2, and a_0 - p = -1.
- \displaystyle a_n = 12 + 18\left(\frac{1}{3}\right)^n, which decreases toward 12: \displaystyle p = \frac{1}{3}p + 8 gives p = 12, and a_0 - p = 18.
- b_0 = 1000 and b_n = 1.02\,b_{n-1} - 50; p = 1.02p - 50 gives p = 2500, so b_n = 2500 - 1500(1.02)^n. It stays positive while \displaystyle (1.02)^n < \frac{5}{3}, and (1.02)^{25} \approx 1.641, (1.02)^{26} \approx 1.673. After 25 months about \$39.09 is left, about \$39.87 with interest, so the full withdrawal first fails in month 26.
- The terms are 1, 3, 6, 11, 20. A rule would need 6 = 3c_1 + c_2 and 11 = 6c_1 + 3c_2, so \displaystyle c_1 = \frac{7}{3}, c_2 = -1. Then \displaystyle \frac{7}{3} \cdot 11 - 6 = \frac{59}{3} \ne 20.
- Proof. The choice of p gives p(1 - c_1 - c_2) = d, that is, p = c_1 p + c_2 p + d. Subtracting this from the rule gives a_n - p = c_1(a_{n-1} - p) + c_2(a_{n-2} - p). \square Here \displaystyle p = \frac{-8}{1 - 5} = 2, the roots are 3 and -1, and b_0 = b_1 = 2 give b_n = 3^n + (-1)^n, so a_n = 3^n + (-1)^n + 2.
- F_{15} = 610. Here \displaystyle \varphi^{15}/\sqrt{5} \approx 609.99967, which rounds to 610; the gap is \displaystyle |\psi^{15}|/\sqrt{5} \approx 0.00033.
- \displaystyle u_n = \left(2 - \frac{\sqrt{5}}{5}\right)\varphi^n + \left(2 + \frac{\sqrt{5}}{5}\right)\psi^n, and u_{n+1}/u_n \to \varphi. From A + B = 4 and A\varphi + B\psi = 1, \displaystyle A\sqrt{5} = 1 - 4\psi = 2\sqrt{5} - 1, so \displaystyle A = 2 - \frac{1}{\sqrt{5}} \ne 0 and B = 4 - A; Exercise 20 gives the limit.
- Proof. For n = 1: F_1\varphi + F_0 = \varphi. If \varphi^n = F_n\varphi + F_{n-1}, then by \varphi^2 = \varphi + 1, \varphi^{n+1} = F_n(\varphi + 1) + F_{n-1}\varphi = F_{n+1}\varphi + F_n. \square So \displaystyle \varphi^6 = 8\varphi + 5 = 9 + 4\sqrt{5}.
- a_n = 5^n - (-3)^n. The roots are 5 and -3; A + B = 0 and 5A - 3B = 8 give A = 1, B = -1. For n \ge 1, 3^n < 5^n, so a_n > 0.
- a_n = 2(-4)^n - 2^n. The roots are -4 and 2; A + B = 1 and -4A + 2B = -10 give A = 2, B = -1. Proof of the signs. For n \ge 1, 2 \cdot 4^n > 2^n, so a_n has the sign of (-4)^n; and a_0 = 1 > 0. \square
- \displaystyle a_n = (2 + \sqrt{3})^n + (2 - \sqrt{3})^n, and the nearest integer to \displaystyle (2 + \sqrt{3})^6 is 2702. The roots are \displaystyle 2 \pm \sqrt{3}, and A + B = 2, \displaystyle 2(A + B) + \sqrt{3}(A - B) = 4 give A = B = 1. The rule gives 2, 4, 14, 52, 194, 724, 2702, and \displaystyle 0 < (2 - \sqrt{3})^6 < \frac{1}{2}.
- The roots of r^2 - r - 2 = (r - 2)(r + 1) are 2 and -1. With w_n = A \cdot 2^n + B(-1)^n, A + B = 1 and 2A - B = 1 give \displaystyle A = \frac{2}{3}, \displaystyle B = \frac{1}{3}, which is the formula.
- Proof. Here r_1 \ne 0; put q = r_2/r_1, so q^n \to 0. Dividing top and bottom by r_1^n, \displaystyle \frac{a_{n+1}}{a_n} = \frac{Ar_1 + Br_2q^n}{A + Bq^n}. The denominator tends to A \ne 0, so by the limit laws the quotient tends to r_1. \square For the strings, \displaystyle g_{n+1}/g_n \to 1 + \sqrt{3}; for example g_{10}/g_9 = 24{,}960/9136 \approx 2.7320.
- Proof. For every n \ge 0, a_{n+3} = a_{n+2} - a_{n+1}, and a_{n+2} = a_{n+1} - a_n, so a_{n+3} = -a_n. Applying this twice, a_{n+6} = -a_{n+3} = a_n. \square For example, a_0 = a_1 = 1 gives 1, 1, 0, -1, -1, 0, 1. The complex roots \displaystyle \frac{1 \pm i\sqrt{3}}{2} have sixth power 1.