%I #48 Sep 08 2022 08:46:17
%S 2,5,17,28,3126,3376,65537,823544,3748097,52521876
%N Numbers n such that n-1 = (tau(n-1)-1)^k for some k>=0, where tau(n) is the number of divisors of n (A000005).
%C Corresponding pairs of numbers (tau(n-1)-1, k): (0, 0); (2, 2); (4, 2); (3, 3); (5, 5); (15, 3); (16, 4); (7, 7); ...
%C Numbers from A125137 (numbers of the form p^p + 1 where p = prime) are terms: 285311670612, 302875106592254, 827240261886336764178, 1978419655660313589123980, 20880467999847912034355032910568, ...
%C Prime terms are in A258429: 2, 5, 17, 65537, ...
%C A Fermat prime from A019434 of the form F(n) = 2^(2^n) + 1 is a term if k = 2^n * log(2) / log(2^n) is an integer.
%C a(11), if it exists, is > 10^10. - _Lars Blomberg_, Nov 14 2016
%e 3376 is in the sequence because 3375 = (tau(3375)-1)^3 = 15^3.
%o (Magma) Set(Sort([n: n in[2..1000000], k in [0..20] | (n-1) eq (NumberOfDivisors(n-1)-1)^k]))
%o (PARI) isok(n) = {if (n==2, return(1)); my(dd = numdiv(n-1) - 1); if (dd > 1, my(k = 1); while(dd^k < n-1, k++); dd^k == n-1;);} \\ _Michel Marcus_, Oct 11 2016
%Y Cf. A000005, A019434, A125137, A258429.
%K nonn,more
%O 1,1
%A _Jaroslav Krizek_, Oct 10 2016
%E a(9)-a(10) from _Michel Marcus_, Oct 11 2016