login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Smallest positive integer k with the same sum of divisors as the n-th integer for which such a k exists.
7

%I #4 Mar 30 2018 03:05:35

%S 6,14,10,14,16,20,21,33,24,28,20,30,33,30,34,30,54,40,24,42,44,42,66,

%T 30,48,42,60,57,68,44,54,40,60,66,54,52,63,85,102,74,66,104,88,66,80,

%U 60,84,99,93,96,86,114,76,132,105,102,60,88,111,90,138,105,114,102,105,138,96

%N Smallest positive integer k with the same sum of divisors as the n-th integer for which such a k exists.

%H Robert Israel, <a href="/A131902/b131902.txt">Table of n, a(n) for n = 1..10000</a>

%F Let S={n>0 : there exists a k>0 and k<n with sigma(k)=sigma(n)}. Then a(n):=min(k>0: sigma(k)=sigma(n-th element of S)

%e a(3)=10 because 17 is the third integer for which a smaller integer with same sum of divisors exists and sigma(17)=1+17=18 and sigma(10)=1+2+5+10=18 and there is no k>0 less than 10 with sigma(k)=18

%p N:= 1000: # to use values of sigma <= N

%p V:= Vector(N): A:= Vector(N):

%p for n from 1 to N do

%p v:= numtheory:-sigma(n);

%p if v <= N then

%p if V[v] = 0 then V[v]:= n

%p else A[n]:= V[v]

%p fi

%p fi

%p od:

%p subs(0=NULL, convert(A,list)); # _Robert Israel_, Mar 30 2018

%t Clear[tmp]; Function[n,If[Head[ #1]===tmp,#1=n;Unevaluated[Sequence[]],#1]& [tmp[DivisorSigma[1,n]]]]/@Range[200]

%Y Cf. A069822, A131903 - A131908.

%K easy,nonn

%O 1,1

%A Peter Pein (petsie(AT)dordos.net), Jul 26 2007