%I #14 Nov 16 2022 15:02:24
%S 2,2,12,12,60,20,840,840,2520,2520,27720,27720,360360,360360,720720,
%T 720720,12252240,4084080,232792560,77597520,33256080,5173168,
%U 5354228880,356948592,3824449200,26771144400,11473347600,80313433200,332727080400,2329089562800,144403552893600
%N a(n) is the denominator of the asymptotic density of numbers divisible by their last digit in base n.
%C a(n) divides A003418(n), and a(n) = A003418(n) for n = 1, 2, 4, 6, 8, 10, 12, ...
%H Amiram Eldar, <a href="/A341432/b341432.txt">Table of n, a(n) for n = 2..2300</a>
%F A341431(n)/a(n) = (1/n) * Sum_{k=1..n-1} gcd(k, n)/k. [corrected by _Amiram Eldar_, Nov 16 2022]
%F a(prime(n)) = A185399(n), for n > 1.
%e For n=2, the numbers divisible by their last binary digit are the odd numbers (A005408) whose density is 1/2, therefore a(2) = 2.
%e For n=3, the numbers divisible by their last digit in base 3 are the numbers that are congruent to {1, 2, 4} mod 6 (A047236) whose density is 1/2, therefore a(3) = 2.
%e For n=10, the numbers divisible by their last digit in base 10 are A034709 whose density is 1177/2520, therefore a(10) = 2520.
%t a[n_] := Denominator[Sum[GCD[k, n]/k, {k, 1, n - 1}]/n]; Array[a, 32, 2]
%Y Cf. A003418, A005408, A034709, A047236, A185399, A341431 (numerators).
%K nonn,base,frac,easy
%O 2,1
%A _Amiram Eldar_, Feb 11 2021