Can we devise a formula for a series like this,
S=n+7(n-1+7(n-2+7(n-3+.........)))
when n=1 S=1 first three terms are 1,9,66 someone says it has a formula but i cant find any help!!!
№ | Пользователь | Рейтинг |
---|---|---|
1 | tourist | 3993 |
2 | jiangly | 3743 |
3 | orzdevinwang | 3707 |
4 | Radewoosh | 3627 |
5 | jqdai0815 | 3620 |
6 | Benq | 3564 |
7 | Kevin114514 | 3443 |
8 | ksun48 | 3434 |
9 | Rewinding | 3397 |
10 | Um_nik | 3396 |
Страны | Города | Организации | Всё → |
№ | Пользователь | Вклад |
---|---|---|
1 | cry | 167 |
2 | Um_nik | 163 |
3 | maomao90 | 162 |
3 | atcoder_official | 162 |
5 | adamant | 159 |
6 | -is-this-fft- | 158 |
7 | awoo | 155 |
8 | TheScrasse | 154 |
9 | Dominater069 | 153 |
10 | djm03178 | 152 |
Название |
---|
https://www.wolframalpha.com/input/?i=sum(7%5Ei+*+(n+-+i)+for+i+%3D+0...n)
S(n + 1) = n + 1 + 7·S(n)
Now this can be solved by standart methods.
I can offer to read about generating function (Link). In short:
S(0) = 0
S(n) = n + 7*S(n — 1)
Multiply first line by x^0, ans second by x^n and sum all lines. Assume S(0)*x^0 + S(1)*x^1+.... = G(x):
G(x) = 7xG(x) + (1 * x^1 + 2 * x^2 + 3 * x^3 + ....)
Expression in brackets can be simplify to x/(1-x)^2. So we can find formula:
G(x) = x/((1-x)^2*(1-7x)) = (7/(1 — 7x) — 1/(1 — x) — 6/(1-x)^2)/36. And we can expand all fractions:
1/(1 — ax) = (ax)^0 + (ax)^1 + ...;
1/(1 — x)^2 = (1 * x^0 + 2 * x^1 + 3 * x^2 + ...);
Calculate all coeffs in left part and all coeffs in right part. And we get finally formula:
S(n) = (7^(n + 1) — 7 — 6n)/36. Check formula for first n:
S(0) = 0;
S(1) = 1;
S(2) = 9;
S(3) = 66;
Thank you very much that helped a lot.........