This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A031420 #24 Aug 18 2021 00:33:16 %S A031420 349,778,1105,1237,1306,1565,1721,2473,3361,3706,3889,4133,4985,5261, %T A031420 5545,6217,6841,6929,7165,7253,7418,7754,8021,8273,8369,8629,9089, %U A031420 9274,9461,10034,10229,10333,10729,11245,11657,12077,12842,12941,13385,13730,14314 %N A031420 Numbers k such that the continued fraction for sqrt(k) has odd period and if the last term of the periodic part is deleted then there are a pair of central terms both equal to 7. %H A031420 T. D. Noe, <a href="/A031420/b031420.txt">Table of n, a(n) for n = 1..1000</a> %t A031420 n = 1; t = {}; While[Length[t] < 50, n++; If[! IntegerQ[Sqrt[n]], c = ContinuedFraction[Sqrt[n]]; len = Length[c[[2]]]; If[OddQ[len] && c[[2, (len + 1)/2]] == 7, AppendTo[t, n]]]]; t (* _T. D. Noe_, Apr 04 2014 *) %t A031420 cf7Q[n_]:=Module[{s=Sqrt[n],cf,len},cf=If[IntegerQ[s],{0}, ContinuedFraction[ s] [[2]]];len=Length[cf];OddQ[len]&&Count[Take[cf,{(len+1)/2-1,(len+1)/2+1}],7]>1]; Select[Range[15000],cf7Q]//Quiet (* _Harvey P. Dale_, Sep 14 2016 *) %Y A031420 Cf. A031404-A031423. %Y A031420 Subsequence of A003814. %K A031420 nonn %O A031420 1,1 %A A031420 _David W. Wilson_ %E A031420 Initial erroneous term 50 removed by _T. D. Noe_, Apr 04 2014