A031666 Numbers k such that the continued fraction for sqrt(k) has odd period and if the last term of the periodic part is deleted the two central terms are both 78.
13933, 123985, 124690, 126106, 185021, 258233, 260269, 262313, 347146, 550925, 553897, 559865, 679417, 823178, 953201, 957109, 959066, 962986, 964949, 966914, 972821, 974794, 1120093, 1286797, 1295885, 1467482, 1474757, 1477186
Offset: 1
Keywords
Crossrefs
Subsequence of A003814.
Programs
-
Mathematica
cf78Q[n_]:=Module[{s=Sqrt[n],len,cf},cf=If[IntegerQ[s],{1,1},ContinuedFraction[s][[2]]];len= Length[ cf];OddQ[len]&&cf[[Floor[len/2]]]==cf[[Ceiling[len/2]]]==78]; Select[Range[ 1480000],cf78Q] (* Harvey P. Dale, Dec 16 2023 *)
Extensions
First term 6085 removed by Georg Fischer, Jun 16 2019