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 A261023 #26 Aug 17 2015 00:27:55 %S A261023 4,9,6,10,121,22,289,34,529,841,58,1369,30,82,2209,42,3481,118,4489, %T A261023 5041,70,6241,6889,78,9409,10201,202,60,214,102,16129,17161,18769,84, %U A261023 138,298,24649,26569,27889,29929,32041,358,36481,238,186,394,44521,49729,51529 %N A261023 Least number k such that prime(n) = sigma(k) - k - 1. %C A261023 For any prime k <= p^2. In fact if k = p^2 we have that sigma(p) = sigma(p^2) - p^2, that is 1 + p = 1 + p + p^2 - p^2. %H A261023 Robert Israel and Paolo P. Lava, <a href="/A261023/b261023.txt">Table of n, a(n) for n = 1..1229</a> (first 100 from Paolo P. Lava) %F A261023 a(n) = A070015(A008864(n)). - _Robert Israel_, Aug 14 2015 %e A261023 sigma(2) = 3 and 4 is the least number such that sigma(4) - 4 = 7 - 4 = 3. %e A261023 sigma(13) = 14 and 22 is the least number such that sigma(22) - 22 = 36 - 22 = 14. %p A261023 with(numtheory): P:=proc(q) local a,k,n; for n from 1 to q do %p A261023 if isprime(n) then for k from 1 to q do %p A261023 if sigma(n)=sigma(k)-k then print(k); break; fi; od; %p A261023 fi; od; end: P(10^9); %t A261023 Table[k = 1; While[DivisorSigma[1, Prime@ p] != DivisorSigma[1, k] - k, k++]; k, {p, 60}] (* _Michael De Vlieger_, Aug 07 2015 *) %o A261023 (PARI) a(n) = my(k = 1, p = prime(n)); while(sigma(k)-k-1 != p, k++); k; \\ _Michel Marcus_, Aug 12 2015 %o A261023 (PARI) first(m)=my(v=vector(m),k);for(i=1,m,k=1;while(!(prime(i)==sigma(k)-k-1),k++);v[i]=k;);v; \\ _Anders Hellström_, Aug 14 2015 %Y A261023 Cf. A008864, A048050, A070015, A158913. %K A261023 nonn,easy %O A261023 1,1 %A A261023 _Paolo P. Lava_, Aug 07 2015