Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #14 Jul 28 2023 15:53:17
%S 1,1,1,1,1,1,9,1,7,1,15,1,25,9,9,1,11,7,21,1,5,15,45,1,49,25,25,9,125,
%T 9,81,1,13,11,33,7,55,21,21,1,77,5,105,15,35,45,135,1,121,49,49,25,
%U 245,25,45,9,343,125,375,9,625,81,27,1,17,13,39,11,65,33,99,7,91,55,11,21,25,21,189,1,143,77,231,5
%N a(n) = A005940(n) / gcd(n, A005940(n)).
%C Denominator of n / A005940(n).
%H Antti Karttunen, <a href="/A364502/b364502.txt">Table of n, a(n) for n = 1..16384</a>
%t nn = 84; Array[Set[a[#], #] &, 2]; Do[If[EvenQ[n], Set[a[n], 2 a[n/2]], Set[a[n], Times @@ Power @@@ Map[{Prime[PrimePi[#1] + 1], #2} & @@ # &, FactorInteger[a[(n + 1)/2]]]]], {n, 3, nn}]; Array[a[#]/GCD[a[#], #] &, nn] (* _Michael De Vlieger_, Jul 28 2023 *)
%o (PARI)
%o A005940(n) = { my(p=2, t=1); n--; until(!n\=2, if((n%2), (t*=p), p=nextprime(p+1))); t };
%o A364502(n) = { my(u=A005940(n)); (u / gcd(n, u)); };
%Y Cf. A005940, A364500, A364501 (numerators), A364546 (positions of 1's).
%Y Cf. also A364492.
%K nonn,frac
%O 1,7
%A _Antti Karttunen_, Jul 28 2023