10
08/27/22 Recurrenc e Relations

Recurrence

Embed Size (px)

DESCRIPTION

Recurrence. Relations. Roxanne Scott Iveta Ovsepyan Deborah Ellis. A Definition. A recurrence relation is a way of defining a sequence of numbers by defining the first term(s) and then prescribing an algorithm that shows us how to compute a n in terms of a i for i < n. Fibonacci - PowerPoint PPT Presentation

Citation preview

Page 1: Recurrence

04/19/23

RecurrenceRecurrence

Relations

Page 2: Recurrence

04/19/23

Roxanne Scott

Iveta Ovsepyan

Deborah Ellis

Roxanne Scott

Iveta Ovsepyan

Deborah Ellis

Page 3: Recurrence

04/19/23

A DefinitionA DefinitionA DefinitionA Definition

A recurrence relation is a way of defining a sequence of numbers by defining the first term(s) and then prescribing an algorithm that shows us how to compute an in terms of ai for i < n.

A recurrence relation is a way of defining a sequence of numbers by defining the first term(s) and then prescribing an algorithm that shows us how to compute an in terms of ai for i < n.

FibonacciLet f1 = 1, f2 = 1, and for all

n > 2

Let fn = f n-2 + fn-1

Page 4: Recurrence

04/19/23

LucasLucas

Let L1 = 1, L2 = 3

And for all

n > 2

Let Ln = L n-2 + L n-1

Let L1 = 1, L2 = 3

And for all

n > 2

Let Ln = L n-2 + L n-1

Let P0 = 0, P1=1

and let

Pn = 2Pn-1 + Pn-2

Let P0 = 0, P1=1

and let

Pn = 2Pn-1 + Pn-2

Pell

Page 5: Recurrence

04/19/23

= # { U \in {1,2,3,….,n} : |U| = k

Consider:

= # { U \in {1,2,3,….,n} : |U| = k

Consider:

nk “ n choose k ”

32 =

Page 6: Recurrence

04/19/23

n

0 XX XX XX XX XX XX

1 XX XX XX XX XX

2 XX XX XX XX

3 XX XX XX

4 XX XX

5 XX

6

k 0 1 2 3 4 5 6

Page 7: Recurrence

04/19/23

Page 8: Recurrence

04/19/23

Page 9: Recurrence

04/19/23

Page 10: Recurrence

04/19/23

Recurrence Relations

Recurrence Relations

Recurrence Relations

cuRelations

Re r encer