login
A040968
Continued fraction for sqrt(1000).
3
31, 1, 1, 1, 1, 1, 6, 2, 2, 15, 2, 2, 6, 1, 1, 1, 1, 1, 62, 1, 1, 1, 1, 1, 6, 2, 2, 15, 2, 2, 6, 1, 1, 1, 1, 1, 62, 1, 1, 1, 1, 1, 6, 2, 2, 15, 2, 2, 6, 1, 1, 1, 1, 1, 62, 1, 1, 1, 1, 1, 6, 2, 2, 15, 2, 2, 6, 1, 1, 1, 1, 1, 62, 1, 1, 1, 1, 1, 6, 2, 2, 15, 2, 2, 6, 1, 1, 1, 1
OFFSET
0,1
COMMENTS
After the initial term, periodic with period (1, 1, 1, 1, 1, 6, 2, 2, 15, 2, 2, 6, 1, 1, 1, 1, 1, 62) of length 18. - M. F. Hasler, Nov 02 2019
MAPLE
with(numtheory): Digits := 300: convert(evalf(sqrt(1000)), confrac);
MATHEMATICA
ContinuedFraction[Sqrt[1000], 120] (* or *) PadRight[{31}, 120, {62, 1, 1, 1, 1, 1, 6, 2, 2, 15, 2, 2, 6, 1, 1, 1, 1, 1}] (* Harvey P. Dale, Aug 22 2018 *)
PROG
(PARI) A40968=contfrac(sqrt(1000)) \\ For illustration. Better:
A040968(n)={1+if(n%3, abs(n\/18*18-n)>6, n%9, !(n%6)*5, n%18, 14, n, 61, 30)} \\ M. F. Hasler, Nov 02 2019
CROSSREFS
Cf. A042936, A042937 (numerators & denominators of convergents).
Sequence in context: A221432 A085012 A086019 * A040967 A040965 A040966
KEYWORD
nonn,cofr,easy
AUTHOR
STATUS
approved