cp's OEIS Frontend

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.

A338627 a(n) is the smallest positive number k such that n consecutive integers starting at k have the same smallest number of squares needed to represent (A002828).

This page as a plain text file.
%I A338627 #4 Nov 04 2020 17:09:14
%S A338627 1,11,42,75,138,713,1672
%N A338627 a(n) is the smallest positive number k such that n consecutive integers starting at k have the same smallest number of squares needed to represent (A002828).
%H A338627 <a href="/index/Su#ssq">Index entries for sequences related to sums of squares</a>
%e A338627 75 = 1^2 + 5^2 + 7^2 = 5^2 + 5^2 + 5^2,
%e A338627 76 = 2^2 + 6^2 + 6^2,
%e A338627 77 = 2^2 + 3^2 + 8^2 = 4^2 + 5^2 + 6^2,
%e A338627 78 = 2^2 + 5^2 + 7^2.
%e A338627 These the first 4 consecutive numbers with the same smallest number of squares needed to represent, so a(4) = 75.
%t A338627 A002828[n_] := Module[{s = SquaresR[Range[4], n]}, If[First[s] > 0, 1, Length[First[Split[s]]] + 1]]; Do[find = 0; k = 0; While[find == 0, k++; If[Length[Union[Table[A002828[j], {j, k, k + n - 1}]]] == 1, find = 1; Print[k]]], {n, 1, 7}]
%Y A338627 Cf. A002828.
%K A338627 nonn,more
%O A338627 1,2
%A A338627 _Ilya Gutkovskiy_, Nov 04 2020