login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A266394 Square array a(n,k) is the number of terms in the "continued fraction" of the form -k1 + 1/(k2 - 1/(k3 -1/( ... for the fraction -k/n. 0

%I #5 Dec 30 2015 02:41:26

%S 1,4,2,7,1,3,10,5,5,4,13,4,1,2,5,16,8,6,8,6,6,19,7,8,1,6,3,7,22,11,4,

%T 7,11,2,7,8,25,10,9,5,1,5,9,4,9,28,14,11,11,8,14,7,7,8,10,31,13,7,4,9,

%U 1,9,2,3,5,11,34,17,12,10,9,9,17,9,12,10,9,12

%N Square array a(n,k) is the number of terms in the "continued fraction" of the form -k1 + 1/(k2 - 1/(k3 -1/( ... for the fraction -k/n.

%C a(n,k) is the number of steps to reach 0 for the fraction -k/n in the following process: if the fraction f is positive, it is replaced by 1/f; and if it is negative, it is replaced by f+1.

%H Maxime Bourrigan, Marie Lhuissier, <a href="http://images.math.cnrs.fr/Enchevetrements-rationnels-et-autres-sorcelleries-mathematiques.html">Enchevêtrements rationnels et autres sorcelleries mathématiques</a>, Images des Mathématiques, CNRS, 2015 (in French).

%e a(1, 3) is the number of steps for -3/1: -3 -> -2 -> -1 -> 0 = 3 steps.

%e a(3, 1) is the number of steps for -1/3: -1/3 -> 2/3 -> -3/2 -> -1/2 -> 1/2 -> -2 -> -1 -> 0 = 7 steps.

%e The array begins:

%e 1, 2, 3, 4, 5, ...

%e 4, 1, 5, 2, 6, ...

%e 7, 5, 1, 8, 6, ...

%e 10, 4, 6, 1, 11, ...

%e 13, 8, 8, 7, 1, ...

%e ...

%o (PARI) trans(f) = if (f > 0, -1/f, if (f < 0, f+1, f));

%o count(f) = nb = 0; while(f!=0, f = trans(f); nb++); nb;

%o tabl(nn) = {for (n=1, nn, for (k=1, nn, print1(count(-k/n), ", ");); print(););}

%Y Cf. A000012 (diagonal), A016777 (1st column), A168230 (2nd line).

%K nonn,tabl

%O 1,2

%A _Michel Marcus_, Dec 29 2015

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 17 23:23 EDT 2024. Contains 371767 sequences. (Running on oeis4.)