%I #30 Aug 20 2020 21:16:47
%S 0,1,2,2,3,4,4,4,3,3,3,4,4,4,3,2,2,1,0,0,0,1,1,1,0,0,0,1,2,2,3,4,4,5,
%T 6,6,6,5,5,5,6,7,7,8,9,9,10,11,11,11,10,10,10,11,12,12,13,14,14,15,16,
%U 16,16,15,15,15,16,16,16,15,14,14,13,12,12,12,13
%N a(n) is the X-coordinate of the n-th point of the Fibonacci word fractal. Sequence A332299 gives Y-coordinates.
%C To build the curve:
%C - start from the origin looking to the right,
%C - for k=0, 1, ...:
%C - move forward to the next lattice point,
%C - if A003849(k) = 1 then:
%C - if k is even then turn 90 degrees to the right
%C - otherwise turn 90 degrees to the left.
%H Rémy Sigrist, <a href="/A332298/b332298.txt">Table of n, a(n) for n = 0..10946</a>
%H Robert Ferréol (MathCurve), <a href="https://www.mathcurve.com/fractals/fibonacci/fibonacci.shtml">Courbe du mot de Fibonacci</a> [in French]
%H Alexis Monnerot-Dumaine, <a href="https://hal.archives-ouvertes.fr/hal-00367972/">The Fibonacci Word Fractal</a>, HAL-00367972, February 2009.
%H Rémy Sigrist, <a href="/A332298/a332298.png">Representation of the first 1+F(24) points of the Fibonacci word fractal</a>
%H Rémy Sigrist, <a href="/A332298/a332298_1.png">Colored representation of the first 1+F(24) points of the Fibonacci word fractal</a> (where the color is function of the greatest Fibonacci number <= n)
%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Fibonacci_word_fractal">Fibonacci word fractal</a>
%H <a href="/index/Con#coordinates_2D_curves">Index entries for sequences related to coordinates of 2D curves</a>
%o (PARI) A003849(n)=my(k=2); while(fibonacci(k)<=n, k++); while(n>1, while(fibonacci(k--)>n, ); n-=fibonacci(k)); n==1
%o { z=0; d=I; for (n=0, 76, print1 (real(z) ", "); if (A003849(n)==0, if (n%2==0, d/=I, d*=I);); z+=d) }
%Y Cf. A003849, A265318, A332299 (Y-coordinates).
%K nonn,look
%O 0,3
%A _Rémy Sigrist_, Feb 09 2020