Q. If f(1)=1,f(2)=3 and f(n)=3f(n−1)−2f(n−2) then find the value of f(5).Answer:
Calculate f(3): To find f(5), we need to use the recursive formula f(n)=3f(n−1)−2f(n−2) to find the values of f(3), f(4), and then f(5). We already know f(1) and f(2), so we can start by finding f(3).Calculation: f(3)=3f(2)−2f(1)=3×3−2×1=9−2=7.
Calculate f(4): Now that we have f(3), we can find f(4) using the same recursive formula.Calculation: f(4)=3f(3)−2f(2)=3×7−2×3=21−6=15.
Calculate f(5): Finally, we can find f(5) using the values of f(4) and f(3).Calculation: f(5)=3f(4)−2f(3)=3×15−2×7=45−14=31.
More problems from Find the roots of factored polynomials