Unformatted text preview: hose that end
with Plutonium.
C(n) = L(n) + P(n)
Now we look at the two terms, assuming that
we add one new piece to the end. 15 Given are all chains of length n1. There are
again C(n1) of those. To which of them can
we add a piece of lead? To ALL of them.
Therefore, 16 Given are all chains of length n1. There are
again C(n1) of those. To which of them can
we add a piece of Plutonium? Only to those
that END with a piece of LEAD!! There are
L(n1) of those. Therefore, L(n) = C(n1)
P(n) = L(n1)
17 18 C(n) = L(n) + P(n) = C(n1) + L(n1) =
C(n1) + C(n2) Back to our example: This is the Fibonacci formula. However, we
have slightly different base cases here. C(3) = C(2) + C(1) = 3 + 2 = 5.
That exactly what we had before.
s C(1) = 2
C(2) = 3 P or L
PL of LP or LL
19 20...
View
Full Document
 Spring '09
 Assembly Language, Recurrence relation, Fibonacci number, Writeback

Click to edit the document details