[go: up one dir, main page]

login
A188009
a(n) = [nr] - [nr-kr] - [kr], where r=(1+sqrt(5))/2, k=2, [ ]=floor.
10
0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 1
OFFSET
1
COMMENTS
See A188014.
FORMULA
a(n) = [nr] - [nr-2r] - [2r], where r=(1+sqrt(5))/2.
a(n) = A123740(n-2), n >= 3. - Wolfdieter Lang, Jun 27 2011
MATHEMATICA
r=(1+5^(1/2))/2; k=2;
t=Table[Floor[n*r]-Floor[(n-k)*r]-Floor[k*r], {n, 1, 220}] (* A188009 *)
Flatten[Position[t, 0]] (* A188010 *)
Flatten[Position[t, 1]] (* First column of array A101866 *)
PROG
(Python)
from math import isqrt
def A188009(n): return (n+isqrt(m:=5*n**2)>>1)-(n-2+isqrt(m-20*(n-1))>>1)-3 if n > 1 else 0 # Chai Wah Wu, Aug 29 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
Clark Kimberling, Mar 19 2011
STATUS
approved