login
A188187
a(n) = [nr]-[kr]-[nr-kr], where r=sqrt(5), k=1, [ ]=floor.
5
0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1
OFFSET
1
COMMENTS
See A188014.
FORMULA
a(n) = [nr]-[r]-[nr-r], where r=sqrt(5).
MATHEMATICA
r=5^(1/2)); k=1;
t=Table[Floor[n*r]-Floor[(n-k)*r]-Floor[k*r], {n, 1, 220}] (*A188187*)
Flatten[Position[t, 0]] (*A188188*)
Flatten[Position[t, 1]] (*A004958*)
PROG
(Python)
from sympy import integer_nthroot
def A188187(n): return integer_nthroot(5*n**2, 2)[0]-integer_nthroot(5*(n-1)**2, 2)[0]-2 # Chai Wah Wu, Mar 16 2021
CROSSREFS
KEYWORD
nonn
AUTHOR
Clark Kimberling, Mar 23 2011
STATUS
approved