Showing posts with label Uva - Recurrence Relation. Show all posts
Showing posts with label Uva - Recurrence Relation. Show all posts

Uva 10254.the priest mathematician

Nov 18, 2009

Problem: 10254.the priest mathematician

Description:

1. If number of disk is 0, then move 0.
2. If number of disk is 1, then move 1.
3. If number of disk is 2, then move 3.
4. If number of disk is 3, then move 5.
5. If number of disk is 4, then move 9.
6. If number of disk is 5, then move 13.
7. If number of disk is 6, then move 17.
8. If number of disk is 7, then move 25.
9. If number of disk is 8, then move 33.

Uva 10213.How many pieces of land

Problem: 10213.How many pieces of land

Description:
F(N) = ( N * (N-1) * (N*N-5*N+18) / 24 ) + 1
proof:
oh......that is quite difficult to tell you the proof by text......hope you will understand what I say:Let P(n) be the number of lands when n points are drawn on circle…. Now assume knowing P(n-1), want to know P(n) by adding the n-th point

Uva 10183 How many Fibs?

Nov 1, 2009

Problem: 10183: How many Fibs?

Recall the definition of the Fibonacci numbers:

f1 := 1
f2 := 2
fn := fn-1 + fn-2 (n>=3)

Given two numbers a and b, calculate how many Fibonacci numbers are in the range [a,b].