%I #14 Mar 16 2021 20:30:59
%S 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,
%T 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,
%U 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
%N [nr+kr]-[nr]-[kr], where r=sqrt(5), k=1, [ ]=floor.
%C Differs from A188187 in number of initial zeros. This sequence yields right-shift sums (introduced at A187950), and A188187 yields left-shift sums (A188014).
%C (a(n)) is the Sturmian sequence with slope sqrt(5)-2. This number has continued fraction expansion [0; 4,4,4, ...]. It is therefore fixed point of a morphism sigma, which can be found with the Crisp et al link: sigma is given by 0 -> 0001, 1 -> 00010. - _Michel Dekking_, Aug 02 2017
%H D. Crisp, W. Moran, A. Pollington, P. Shiue, <a href="http://www.numdam.org/item?id=JTNB_1993__5_1_123_0">Substitution invariant cutting sequences</a>, Journal de théorie des nombres de Bordeaux 5, (1993), p. 123-137.
%F a(n) = [nr+r]-[nr]-[r], where r=sqrt(5).
%t r=5^(1/2); k=1;
%t seqA=Table[Floor[n*r+k*r]-Floor[n*r]-Floor[k*r], {n,1,220}] (* A188221 *)
%t Flatten[Position[seqA,0] ] (* A188222 *)
%t Flatten[Position[seqA,1] ] (* A004976 *)
%o (Python)
%o from sympy import integer_nthroot
%o def A188221(n): return integer_nthroot(5*(n+1)**2,2)[0]-integer_nthroot(5*n**2,2)[0]-2 # _Chai Wah Wu_, Mar 16 2021
%Y Cf. A187950, A188222, A004976, A188014, A188187, A188188, A004958.
%K nonn
%O 1
%A _Clark Kimberling_, Mar 24 2011