A031775 Numbers k such that the least term in the periodic part of the continued fraction for sqrt(k) is 97.
9411, 37640, 84687, 150552, 235235, 338736, 461055, 602192, 762147, 940920, 1138511, 1354920, 1590147, 1844192, 2117055, 2408736, 2719235, 3048552, 3396687, 3763640, 4149411, 4554000, 4977407, 5419632, 5880675, 6360536, 6859215, 7376712
Offset: 1
Keywords
Links
- Chai Wah Wu, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
cf97Q[n_]:=Module[{s=Sqrt[n]},If[IntegerQ[s],1,Min[ContinuedFraction[s][[2]]]]==97]; Select[Range[738*10^4],cf97Q] (* Harvey P. Dale, Nov 20 2018 *)
-
Python
from sympy import continued_fraction_periodic A031775_list = [n for n, d in ((n, continued_fraction_periodic(0,1,n)[-1]) for n in range(1,10**5)) if isinstance(d, list) and min(d) == 97] # Chai Wah Wu, Jun 10 2017
Comments