This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A144611 #71 May 30 2025 15:38:02 %S A144611 0,1,0,1,0,1,1,0,1,0,1,1,0,1,0,1,0,1,1,0,1,0,1,1,0,1,0,1,0,1,1,0,1,0, %T A144611 1,1,0,1,0,1,1,0,1,0,1,0,1,1,0,1,0,1,1,0,1,0,1,0,1,1,0,1,0,1,1,0,1,0, %U A144611 1,1,0,1,0,1,0,1,1,0,1,0,1,1,0,1,0,1,0,1,1,0,1,0,1,1,0,1,0,1,0,1,1,0,1,0,1 %N A144611 Sturmian word of slope 2-sqrt(2). %C A144611 Old name was: Sturmian word of slope 2. %C A144611 Conjecture: a(n) = floor((n+1)*log(3)/log(2)) - floor(n*log(3)/log(2)) - 1. %C A144611 This is not true: Let b(n) = floor((n+1)*log(3)/log(2)) - floor(n*log(3)/log(2)) - 1. Then b(40) = 0, whereas a(40) = 1. This is the first term at which a(n) and b(n) disagree. - _Danny Rorabaugh_, Mar 14 2015 %C A144611 From _Benoit Cloitre_, Oct 16 2016: (Start) %C A144611 Let u(n) = n + floor(sqrt(2)*n) (A003151) and v(n) = n + floor(n/sqrt(2)) (A003152) then u,v form a partition of the positive integers and we have, for n >= 1, a(u(n))=0 and a(v(n))=1. %C A144611 Another way to construct the sequence: merge the sequences x(n) = 2n^2+1 and y(n) = 4n^2 (n >= 1) into an increasing sequence z(n) which then begins: 3,4,9,16,19,33,36,51,64,73 (not in the OEIS). Then for n >= 1, a(n) = z(n) mod 2. (End) %C A144611 From _Michel Dekking_, Feb 16 2020: (Start) %C A144611 This sequence is a Sturmian sequence s(alpha,rho) with slope alpha = 2-sqrt(2), and intercept rho = 0. %C A144611 In general, one passes from slope alpha to slope 1-alpha by exchanging 0 and 1. It therefore follows from the Comments of A006337 that (a(n+1)) is the unique fixed point of the morphism 0 -> 101, 1 -> 10. (End) %H A144611 Danny Rorabaugh, <a href="/A144611/b144611.txt">Table of n, a(n) for n = 0..10000</a> %H A144611 M. Lothaire, <a href="http://tomlr.free.fr/Math%E9matiques/Fichiers%20Claude/Auteurs/aaaDivers/Lothaire%20-%20Algebraic%20Combinatorics%20On%20Words.pdf">Algebraic combinatorics on words</a>, Cambridge University Press. Online publication date: April 2013; Print publication year: 2002. %H A144611 Mike Winkler, <a href="https://arxiv.org/abs/1412.0519">On the structure and the behaviour of Collatz 3n+ 1 sequences</a>, arXiv:1412.0519 [math.GM], 2014. %F A144611 a(n) = floor((n+1)*alpha) - floor(n*alpha), where alpha = 2-sqrt(2). - _Michel Dekking_, Feb 16 2020 %t A144611 christoffel[s_, M_] := Module[{n, x = 1, y = 0, ans = {0}}, Do[If[y + 1 <= s*x, AppendTo[ans, 1]; y++, AppendTo[ans, 0]; x++], {n, 1, M}]; ans] (* or Sturmian word, Jean-François Alcover, Sep 19 2016, A274170 *); christoffel[Sqrt[2], 105] (* _Robert G. Wilson v_, Feb 02 2017 *) %o A144611 (Sage) #Generate the first n terms (plus a few) of the Sturmian word of slope a %o A144611 def Sturmian(a,n): %o A144611 y = 0 %o A144611 A = [] %o A144611 while len(A)<=n: %o A144611 y += a %o A144611 A.extend([0]+[1]*(floor(y)-floor(y-a))) %o A144611 return A %o A144611 Sturmian(sqrt(2),104) %o A144611 # _Danny Rorabaugh_, Mar 14 2015 %o A144611 (PARI) \\ to get N terms %o A144611 a(n)=if(n<1,0,vecsort(concat(vector(floor(sqrt(2)*N),i,2*i^2+1),vector(N,j,4*j^2)))[n]%2) \\ _Benoit Cloitre_, Oct 16 2016 %Y A144611 See A144595 for further details. Cf. A006337, A074840. %K A144611 nonn %O A144611 0,1 %A A144611 _N. J. A. Sloane_, Jan 13 2009 %E A144611 Name corrected by _Michel Dekking_, Feb 16 2020