Recursive formular and closed-form questions

70 Views Asked by At

Follow the question the $f(n)=4n-1$ and $F(n)=\sum_{k=0}^nf(k)$. And it ask you to write the recursive of $F(n)$. But I only know the recursive of $f(n)$ is

$$f(n)=\begin{cases} -1,&\text{if }n=0\\ -1+4(n-1)\text{ (maybe?)},&\text{if }n>0 \end{cases}$$

And find a closed-form for $F(n)$. And I know it's equal to $2n^2+n-1$, but I don't know how to explain how I find it...QWQ

Please help me thx you!!

2

There are 2 best solutions below

2
On BEST ANSWER

You can decompose your sum as the difference of sums as I suggested in my first answer. The first sum is the sum of all integers from 0 to n (arithmetic progression) and it is equal to n(n+1)/2. The second sum is prety trivial since you add 1 n times and the result is (n+1). As a final result, your summation is 4 times n(n+1)/2 minus (n+1). After simplification, this leads to (2 n^2 + n - 1). Is this better explained ?

1
On

HINT Sum[4 k - 1,{k,0,n}] = 4 Sum[k,{k,0,n}] - Sum[1,{k,0,n}]. Are you able to continue with this ?