%I #21 Apr 26 2024 03:13:47
%S 0,1,2,6,4,30,6,42,8,90,10,66,12,2730,14,30,16,510,18,798,20,2310,22,
%T 138,24,13650,26,54,28,870,30,14322,32,5610,34,210,36,1919190,38,78,
%U 40,13530,42,1806,44,2070,46,282,48,324870,50,1122,52,1590,54,43890,56
%N a(n) = n*denominator(n*Bernoulli(n-1)) for n >= 1 and a(0) = 0.
%C Conjecture: For n>1: denominator(Bernoulli(n-1)) = n*denominator(n*Bernoulli(n-1)) <=> n is Korselt <=> n is prime or n is Carmichael.
%H Amiram Eldar, <a href="/A326579/b326579.txt">Table of n, a(n) for n = 0..10000</a>
%H Bernd C. Kellner and Jonathan Sondow, <a href="http://math.colgate.edu/~integers/v52/v52.pdf">On Carmichael and polygonal numbers, Bernoulli polynomials, and sums of base-p digits</a>, Integers 21 (2021), #A52, 21 pp.; <a href="https://arxiv.org/abs/1902.10672">arXiv preprint</a>, arXiv:1902.10672 [math.NT], 2019-2021.
%H Carl Pomerance, J. L. Selfridge, and Samuel S. Wagstaff, Jr., <a href="http://dx.doi.org/10.1090/S0025-5718-1980-0572872-7">The pseudoprimes to 25*10^9</a>, Math. Comp., 35 (1980), 1003-1026.
%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Carmichael_number#Korselt's_criterion">Carmichael numbers, Korselt's criterion</a>.
%F a(2*n) = 2*n.
%p A326579 := n -> `if`(n = 0, 0, n*denom(n*bernoulli(n-1))): seq(A326579(n), n=0..56);
%t a[n_] := n * Denominator[n * BernoulliB[n - 1]]; a[0] = 0; Array[a, 60, 0] (* _Amiram Eldar_, Apr 26 2024 *)
%o (PARI) a(n) = if (n, n*denominator(n*bernfrac(n-1)), 0); \\ _Michel Marcus_, Jul 19 2019
%Y Cf. A326578, A326478, A326577, A027641/A027642 (Bernoulli), A002997 (Carmichael), A324050 (Korselt).
%K nonn
%O 0,3
%A _Peter Luschny_, Jul 17 2019