%I #23 Nov 19 2022 21:51:14
%S 2,27,18,72,612,1764,756,8100,27000,97200,66528,175500,93600,280800,
%T 1731600,661500,680400,3704400,34177500,11107800,16581600,20065500,
%U 108486000,102910500,108353700,181912500,314874000,462672000,4408236000,229975200,2297786400,672348600,925041600,1344697200,158230800
%N a(n) is the smallest number k for which k and the arithmetic derivative k' (A003415) have exactly n triangular divisors (A000217).
%e 2 has only the divisor 1 = A000217(1) and 2' = 1 = A000217(1), so a(1) = 2.
%e 27 and 27' = 27 have the divisors 1 = A000217(1), 3 = A000217(2) triangular numbers, so a(2) = 27.
%t d[0] = d[1] = 0; d[n_] := n*Plus @@ ((Last[#]/First[#]) & /@ FactorInteger[n]); tridiv[n_] := DivisorSum[n, 1 &, IntegerQ[Sqrt[8*# + 1]] &]; seq[len_, nmax_] := Module[{s = Table[0, {len}], c = 0, n = 2, i}, While[c < len && n < nmax, i = tridiv[n]; If[i <= len && s[[i]] == 0 && tridiv[d[n]] == i, c++; s[[i]] = n]; n++]; s]; seq[10, 10^6] (* _Amiram Eldar_, Oct 21 2022 *)
%o (Magma) tr:=func<k|#[d:d in Divisors(k)|IsSquare(8*d+1)]>; f:=func<h |h le 1 select 0 else h*(&+[Factorisation(h)[i][2] / Factorisation(h)[i][1]: i in [1..#Factorisation(h)]])>; a:=[]; for n in [1..30] do k:=2 ; while tr(k) ne n or tr(Floor(f(k))) ne n do k:=k+1; end while; Append(~a,k); end for; a;
%o (PARI) f(n) = sumdiv(n, d, ispolygonal(d, 3)); \\ A007862
%o ad(n) = vecsum([n/f[1]*f[2]|f<-factor(n+!n)~]); \\ A003415
%o a(n) = my(k=2); while((f(k)!=n) || (f(ad(k))!=n), k++); k; \\ _Michel Marcus_, Oct 23 2022
%Y Cf. A000217, A003415, A007862, A130317.
%K nonn
%O 1,1
%A _Marius A. Burtea_, Oct 20 2022