A244658 a(n) = x/(x1-floor(x1)) where x = sqrt(n) - floor(sqrt(n)), x1 = 1/x, a(n) = -1 if division by zero, a(n) = 0 for nonintegers.
-1, 1, 2, -1, 1, 2, 0, 4, -1, 1, 2, 3, 0, 0, 6, -1, 1, 2, 0, 4, 0, 0, 0, 8, -1, 1, 2, 0, 0, 5, 0, 0, 0, 0, 10, -1, 1, 2, 3, 4, 0, 6, 0, 0, 0, 0, 0, 12, -1, 1, 2, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 14, -1, 1, 2, 0, 4, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 16, -1, 1, 2, 3, 0, 0, 6, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 18, -1, 1, 2, 0, 4, 5
Offset: 1
Keywords
Examples
For n = 3, x = sqrt(3) - floor(sqrt(3)) = 0.732050807..., x1 = 1/x = 1/0.732050807... = 1.366025403..., x1 - floor(x1) = 0.366025403..., a(3) = 0.732050807.../0.366025402... = 2.
Links
- Kival Ngaokrajang, Illustration for n = 1..20 and iteration k = 1..10
- a(n) arrange as table for n = 1..168
- answers.yahoo, What are the words to the math poem in "Harold and Kumar"?
- Eric Weisstein's World of Mathematics, Periodic Continued Fraction
Crossrefs
Cf. A062731.
Comments