%I #38 Mar 17 2022 07:07:42
%S 2,4,6,8,10,12,14,16,18,20,24,26,28,30,32,36,38,40,42,44,48,50,52,54,
%T 56,60,62,63,64,66,68,70,72,74,75,78,80,84,88,90,92,96,98,100,102,104,
%U 108,110,112,114,116,120,122,124,126,128,130,132,135,138,140
%N Numbers k such that k has more divisors than k-1.
%C Numbers k such that A051950(k) > 0. - _Robert Israel_, Aug 03 2014
%H Robert Israel, <a href="/A240171/b240171.txt">Table of n, a(n) for n = 1..10000</a>.
%e 22 has the same number of divisors as 21 (4 divisors), so 22 is not a term.
%e 63 has 6 divisors, and 62 has only 4, so 63 is a term.
%p N:= 1000: # to get all entries <= N
%p L:= map(numtheory:-tau,[$1..N]):
%p A:= select(t -> L[t] > L[t-1],[$2..N]); # _Robert Israel_, Aug 03 2014
%t Flatten[Position[Partition[DivisorSigma[0,Range[200]],2,1],_?(#[[1]]< #[[2]]&),{1},Heads->False]]+1 (* _Harvey P. Dale_, Feb 08 2015 *)
%o (PARI)
%o for(n=1,10^3,if(numdiv(n)>numdiv(n-1),print1(n,", "))) \\ _Derek Orr_, Aug 02 2014
%Y Cf. A000005, A051950.
%K nonn,easy
%O 1,1
%A _J. Lowell_, Aug 02 2014
|