%I #43 Dec 27 2023 00:12:23
%S 2,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,
%T 4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,4,2,
%U 4,2,4,2,4,2,4,2,4,2,4,2,4
%N Continued fraction for sqrt(6).
%H Harry J. Smith, <a href="/A040003/b040003.txt">Table of n, a(n) for n = 0..20000</a>
%H G. Xiao, <a href="http://wims.unice.fr/~wims/en_tool~number~contfrac.en.html">Contfrac</a>
%H <a href="/index/Con#confC">Index entries for continued fractions for constants</a>
%H <a href="/index/Rec#order_02">Index entries for linear recurrences with constant coefficients</a>, signature (0, 1).
%F a(n-1) = gcd(2^n, 3^n+1) (empirical). - _Michel Marcus_, Sep 03 2020
%e 2.449489742783178098197284074... = 2 + 1/(2 + 1/(4 + 1/(2 + 1/(4 + ...)))). - _Harry J. Smith_, Jun 01 2009
%p Digits := 100: convert(evalf(sqrt(N)),confrac,90,'cvgts'):
%t ContinuedFraction[Sqrt[6], 300] (* _Vladimir Joseph Stephan Orlovsky_, Mar 04 2011 *)
%o (PARI) { allocatemem(932245000); default(realprecision, 21000); x=contfrac(sqrt(6)); for (n=0, 20000, write("b040003.txt", n, " ", x[n+1])); } \\ _Harry J. Smith_, Jun 01 2009
%Y Cf. A010464 (decimal expansion).
%Y Equals twice A040001.
%K nonn,cofr,easy
%O 0,1
%A _N. J. A. Sloane_