OFFSET
1,3
COMMENTS
This continued fraction shows exp(sqrt(2)) is irrational (see A274540).
REFERENCES
J. Borwein and D. Bailey, Mathematics by experiment, plausible reasoning in the 21st Century, A. K. Peters, p. 77.
LINKS
G. C. Greubel, Table of n, a(n) for n = 1..1500
Index entries for linear recurrences with constant coefficients, signature (0,2,0,-1).
FORMULA
a(2*n) = 4*n-3, a(2*n+1) = 8*n-2.
From Colin Barker, Apr 15 2012: (Start)
a(n) = 2*a(n-2) - a(n-4) for n>5.
G.f.: x^2*(1+6*x+3*x^2+2*x^3)/((1-x)^2*(1+x)^2). (End)
a(n) = (2*n-3)*(3-(-1)^n)/2 for n>1, with a(1) = 0. - Wesley Ivan Hurt, Apr 01 2022
MATHEMATICA
$MinPrecision = 5 $MachinePrecision; ContinuedFraction[Sqrt[2]* (Exp[Sqrt[2]] - 1)/(Exp[Sqrt[2]] + 1), 100] (* G. C. Greubel, Aug 17 2018 *) (* or *)
LinearRecurrence[{0, 2, 0, -1}, {0, 1, 6, 5, 14}, 100] (* Georg Fischer, Aug 26 2022 *)
PROG
(PARI) default(realprecision, 1000); contfrac(sqrt(2)*(exp(sqrt(2))-1)/ (exp(sqrt(2))+1)) \\ Michel Marcus, Oct 11 2016
CROSSREFS
KEYWORD
nonn,cofr,easy
AUTHOR
Benoit Cloitre, Oct 02 2006
STATUS
approved