Recurrence Relation
Context: FIT1058_MOC, FIT2004_MOC · defines a sequence from earlier terms · base case(s) + general case · turned into a closed form by Mathematical Induction FIT2004 use: a recursive algorithm’s running time obeys a recurrence (, ) — solved for a Big-O class by telescoping in Solving Recurrences (Telescoping).
Quick Revision
- 🎯 Objective: each term as an expression in previous terms ➔ base case(s) + general case.
- 📦 Core Components: base case + general rule ➔ must determine every term uniquely.
- ⚡ Key Constraint: a -step rule needs base cases; closed form via explore–formulate–prove.
📝 Core
1. The Definition
- Recurrence ➔ each term from previous terms; base case ➔ finitely many initial terms given explicitly; general case ➔ a rule for a generic term.
2. Base Case Is Essential
- Rule alone defines nothing ➔ gives odds from , evens from — same rule, different sequence.
- Depth = base count ➔ a -step rule needs base cases; with only fixes just the odd positions.
3. Recurrence → Closed Form
- Explore ➔ formulate ➔ prove ➔ compute first terms, guess the pattern, prove by Mathematical Induction.
📊 Exam Execution Trace
Manual Execution Trace
:
| Step / State | |||
|---|---|---|---|
| 0 (Init) | 1 | — | 1 |
| 1 | 2 | 1 | 3 |
| 2 | 3 | 3 | 7 |
| 3 | 4 | 7 | 15 |
🧠 Active Recall
Describe explore–formulate–prove and apply it to .
- Hint: Guess then induct.
Answer
- Short answer: explore ; formulate ; prove by induction (basis + step).
- Why: Closed form ➔ converts a backward-looking rule into a formula valid for all , which is what exposes the growth class.
Why does need two base cases?
- Hint: Depth = base count.
Answer
- Short answer: the rule reaches two terms back, so alone determines only odd-indexed terms; is needed for the even ones.
- Why: -step ⟹ bases ➔ fewer leaves whole residue classes of the index undefined.