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 A291503 #18 Aug 25 2017 16:41:04 %S A291503 1,1,0,0,3,0,5,3,5,3,0,3,6,5,7,7,0,5,10,7,6,0,0,7,19,6,10,6,12,7,29,0, %T A291503 19,0,14,6,22,10,14,0,27,6,20,19,14,0,0,0,20,19,21,14,0,10,27,14,22, %U A291503 12,0,0,24,29,22,21,33,19,0,21,43,14,0,14,30,22,27,22,24,14,45 %N A291503 a(n) is the smallest k such that sigma(k) = phi(n), or 0 if no such k exists. %H A291503 Robert Israel, <a href="/A291503/b291503.txt">Table of n, a(n) for n = 1..10000</a> %F A291503 a(A069825(n)) = 0 for n > 1. %F A291503 a(n) = A051444(A000010(n)). - _Michel Marcus_, Aug 25 2017 %e A291503 a(5) = 3 because sigma(3) = phi(5) and 3 is the smallest number with this property. %p A291503 N:= 100: # to get a(1)..a(N) %p A291503 R:= Vector(N): %p A291503 for k from 1 to N-1 do %p A291503 s:= numtheory:-sigma(k); %p A291503 if s <= N and R[s] = 0 then R[s]:= k fi; %p A291503 od: %p A291503 seq(R[numtheory:-phi(n)],n=1..N); # _Robert Israel_, Aug 25 2017 %o A291503 (PARI) a(n) = for(k=1, eulerphi(n), if(sigma(k)==eulerphi(n), return(k))); 0 \\ after _Charles R Greathouse IV_ at A051444 %Y A291503 Cf. A000010, A000203, A051444, A069825. %K A291503 nonn,easy %O A291503 1,5 %A A291503 _Altug Alkan_, Aug 25 2017