|
|
A122461
|
|
Repetitions of even numbers four times.
|
|
3
|
|
|
0, 0, 0, 0, 2, 2, 2, 2, 4, 4, 4, 4, 6, 6, 6, 6, 8, 8, 8, 8, 10, 10, 10, 10, 12, 12, 12, 12, 14, 14, 14, 14, 16, 16, 16, 16, 18, 18, 18, 18, 20, 20, 20, 20, 22, 22, 22, 22, 24, 24, 24, 24, 26, 26, 26, 26, 28, 28, 28, 28, 30, 30, 30, 30, 32, 32, 32, 32, 34, 34, 34, 34, 36, 36, 36, 36
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,5
|
|
COMMENTS
|
Number of roots of P(x) = 1 + x + x^2 + … + x^n in the right half-plane. - Michel Lagneau, Oct 30 2012
|
|
LINKS
|
|
|
FORMULA
|
a(n) = (Sum_{k=0..n} (k+1)*cos((n-k)*Pi/2))+1/4*(2*cos(n*Pi/2)+1+(-1)^n)-2. - Paolo P. Lava, May 15 2007
a(n) = (-3+(-1)^n+2*i^((n-1)*n)+2*n)/4, where i=sqrt(-1). [Bruno Berselli, Oct 31 2012]
a(n) = (2*n-3+2*cos(n*Pi/2)+cos(n*Pi)+2*sin(n*Pi/2))/4. - Wesley Ivan Hurt, Oct 02 2017
|
|
MAPLE
|
with(numtheory): for n from 1 to 70 do:it:=0:y:=[fsolve(sum('x^i ', 'i'=0..n-1), x, complex)] : for m from 1 to nops(y) do : if Re(y[m]) > 0 then it:=it+1:else fi:od: printf(`%d, `, it):od: # Michel Lagneau, Oct 31 2012
|
|
MATHEMATICA
|
Table[PadRight[{}, 4, 2n], {n, 0, 20}]//Flatten (* or *) LinearRecurrence[ {1, 0, 0, 1, -1}, {0, 0, 0, 0, 2}, 80] (* Harvey P. Dale, Mar 15 2020 *)
|
|
PROG
|
(Python)
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|