# Thread: Problem with understanding recursion

1. ## Problem with understanding recursion

Find f(1); f(2); f(3); f(4) and f(5) if f(n) is defined recursively by f(0) = 3 and for n = 0; 1; 2 for:

f(n+1)= f(n)^2 - 2f(n)-2

2. Originally Posted by orendacl
Find f(1); f(2); f(3); f(4) and f(5) if f(n) is defined recursively by f(0) = 3 and for n = 0; 1; 2 for:

f(n+1)= f(n)^2 - 2f(n)-2
In order to understand recursion, you must understand recursion.

Nevertheless, note that:

$f(0+1) = f(1) = f(0)^2 - 2f(0) - 2 = 3^2 - 2 (3) - 2 = 1$

$f(1+1) = f(2) = f(1)^2 - 2f(1) - 2 = 1^2 - 2 (1) - 2 = -3$

etc.