cp's OEIS Frontend

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.

A343019 a(n) is the smallest number m such that tau(m+1) = tau(m) - n.

This page as a plain text file.
%I A343019 #23 Jul 03 2024 10:05:02
%S A343019 2,4,6,16,12,24,30,36,84,324,60,144,192,120,210,288,180,528,240,576,
%T A343019 480,360,420,900,1344,960,720,5184,1008,840,1320,2400,1260,17424,1800,
%U A343019 14640,2640,1680,2160,8280,4800,3600,11220,7056,3780,6240,2520,82944,6480
%N A343019 a(n) is the smallest number m such that tau(m+1) = tau(m) - n.
%C A343019 tau(m) = the number of divisors of m (A000005).
%C A343019 A greedy inverse of A051950.
%C A343019 Sequences of numbers m such that tau(m+1) = tau(m) - n for 0 <= n <= 5:
%C A343019 n = 0: 2, 14, 21, 26, 33, 34, 38, 44, 57, 75, 85, 86, 93, ... (A005237).
%C A343019 n = 1: 4, 8, 81, 441, 625, 1089, 2024, 2401, 3025, 3968, ... (A068208).
%C A343019 n = 2: 6, 10, 20, 22, 32, 45, 46, 50, 58, 68, 76, 82, 92, ... (A227874).
%C A343019 n = 3: 16, 64, 224, 675, 1444, 2115, 3843, 5475, 6724, 9801, ...
%C A343019 n = 4: 12, 18, 28, 52, 54, 56, 105, 110, 114, 128, 148, 154, ...
%C A343019 n = 5: 24, 80, 225, 484, 1024, 1088, 1156, 1225, 1521, 2116, ...
%H A343019 Robert Israel, <a href="/A343019/b343019.txt">Table of n, a(n) for n = 0..174</a>
%e A343019 For n = 3; a(3) = 16 because 16 is the smallest number such that tau(17) = 2 = tau(16) - 3 = 5 - 3.
%p A343019 N:= 50: # for a(0)..a(N)
%p A343019 V:= Array(0..N): count:=0: t:= numtheory:-tau(1):
%p A343019 for m from 1 while count < N+1 do
%p A343019   s:= numtheory:-tau(m+1); v:= t - s;
%p A343019   if v >= 0 and v <= N and V[v] = 0 then
%p A343019     count:= count+1; V[v]:= m;
%p A343019   fi;
%p A343019   t:= s;
%p A343019 od:
%p A343019 convert(V,list); # _Robert Israel_, Jul 03 2024
%t A343019 d = Differences @ Table[DivisorSigma[0, n], {n, 1, 10^5}]; a[n_] := If[(p = Position[d, -n]) != {}, p[[1, 1]], 0]; s = {}; n = 0; While[(a1 = a[n]) > 0, AppendTo[s, a1]; n++]; s (* _Amiram Eldar_, Apr 03 2021 *)
%o A343019 (Magma) Ax:=func<n|exists(r){m: m in[1..10^6] | #Divisors(m + 1) - #Divisors(m) eq -n} select r else 0>; [Ax(n): n in [0..50]]
%o A343019 (PARI) a(n) = my(m=1); while (numdiv(m+1) != numdiv(m) - n, m++); m; \\ _Michel Marcus_, Apr 03 2021
%o A343019 (Python)
%o A343019 from itertools import count, pairwise
%o A343019 from sympy import divisor_count
%o A343019 def A343019(n): return next(m+1 for m, t in enumerate(pairwise(map(divisor_count,count(1)))) if t[1] == t[0]-n) # _Chai Wah Wu_, Jul 25 2022
%Y A343019 Cf. A000005 (tau), A051950, A080371, A080372, A343018.
%K A343019 nonn
%O A343019 0,1
%A A343019 _Jaroslav Krizek_, Apr 02 2021