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 A109170 #4 Mar 30 2012 18:36:49 %S A109170 2,1,4,2,6,2,8,4,10,3,12,4,14,4,16,8,18,5,20,6,22,6,24,8,26,7,28,8,30, %T A109170 8,32,16,34,9,36,10,38,10,40,12,42,11,44,12,46,12,48,16,50,13,52,14, %U A109170 54,14,56,16,58,15,60,16,62,16,64,32,66,17,68,18,70,18,72,20,74,19,76,20,78 %N A109170 Continued fraction expansion of 2*x which equals the continued fraction of x (A109168) interleaved with positive even numbers. %F A109170 For n>=1: a(2*n-1) = 2*n, a(4*n-2) = n, a(4*n) = 2*a(2*n). %e A109170 2*x=2.8169885584578139714969485581613959832279979115641025629325276350497259... %e A109170 The continued fraction expansion of x = A109168: %e A109170 [1; 2, 2, 4, 3, 4, 4, 8, 5, 6, 6, 8, 7, 8, 8, 16, ...]; %e A109170 The continued fraction expansion of 2*x = A109170: %e A109170 [2;1, 4,2, 6,2, 8,4, 10,3, 12,4, 14,4, 16,8, 18,5, ...] %e A109170 which equals the continued fraction of x interleaved with even numbers. %o A109170 (PARI) a(n)=if(n%2==1,(n+1),if(n%4==2,(n+2)/4,2*a(n/2))) %Y A109170 Cf. A109168 (continued fraction of x), A109169 (digits of x), A109171 (digits of 2*x). %K A109170 cofr,nonn %O A109170 1,1 %A A109170 _Paul D. Hanna_, Jun 21 2005