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 A383268 #17 Jun 10 2025 08:41:27 %S A383268 6,13,15,17,28,33,39,42,50,51,53,54,55,57,59,61,65,66,69,71,77,78,82, %T A383268 89,90,93,95,99,101,107,111,115,118,120,121,123,125,129,131,139,141, %U A383268 149,153,161,165,167,171,177,179,182,183,190,195,196,197,201,204,213,215 %N A383268 Numbers k for which sigma(k - x) + sigma(k + x) = 4*k has at least one nonnegative solution. %C A383268 Supersequence of A000396 because sigma(A000396(n) - x) + sigma(A000396(n) + x) = 4*A000396(n) has the solution x = 0. %H A383268 Michel Marcus, <a href="/A383268/b383268.txt">Table of n, a(n) for n = 1..10000</a> (terms up to n=1000 by Felix Huber). %H A383268 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/PerfectNumber.html">Perfect Number</a> %e A383268 15 is in the sequence because sigma(15 - x) + sigma(15 + x) = 4*15 has the solution x = 5: sigma(15 - 5) + sigma(15 + 5) = sigma(10) + sigma(20) = 18 + 42 = 60 = 4*15. %p A383268 with(NumberTheory): %p A383268 A383268:=proc(N) # To get the first N terms. %p A383268 local k,x,K; %p A383268 K:=[]; %p A383268 for k while nops(K)<N do %p A383268 for x from 0 to k-1 do %p A383268 if sigma(k-x)+sigma(k+x)=4*k then %p A383268 K:=[op(K),k]; %p A383268 break %p A383268 fi %p A383268 od %p A383268 od; %p A383268 return op(K) %p A383268 end proc; %p A383268 A383268(59); %o A383268 (PARI) isok(k) = for (x=0, k-1, if (sigma(k - x) + sigma(k + x) == 4*k, return(1))); \\ _Michel Marcus_, Apr 26 2025 %Y A383268 Cf. A000203, A000396, A186103, A383269. %K A383268 nonn,easy %O A383268 1,1 %A A383268 _Felix Huber_, Apr 24 2025