This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A126865 #24 Mar 08 2024 09:01:15 %S A126865 1,1,2,1,2,2,2,1,4,2,2,2,2,6,8,1,2,4,2,2,4,2,2,2,4,6,8,6,2,8,2,1,4,2, %T A126865 24,4,2,6,8,2,2,12,2,2,16,2,2,2,4,4,8,6,2,8,8,6,4,2,2,8,2,6,8,1,12,4, %U A126865 2,2,4,24,2,4,2,6,16,18,12,24,2,2,16,2,2,12,4,6,8,2,2,16,8,2,4,2,24,2,2,12,8 %N A126865 a(n) = gcd(Product_{p|n} (p+1)^b(p,n), Product_{p|n} (p-1)^b(p,n)), where the products are over the distinct primes, p, that divide n and p^b(p,n) is the highest power of p dividing n. %C A126865 First occurrence of k or 0 if not possible (including all odd primes k): 2, 1, 0, 9, 0, 14, 0, 15, 0, 0, 0, 42, 0, 0, 0, 45, 0, 76, 0, 589, 0, 0, 0, 35, 0, 0, 0, 4381, 0, 0, ..., . - _Robert G. Wilson v_, Sep 08 2007 %H A126865 Antti Karttunen, <a href="/A126865/b126865.txt">Table of n, a(n) for n = 1..12441</a> %H A126865 Antti Karttunen, <a href="/A126865/a126865.txt">Data supplement: n, a(n) computed for n = 1..100000</a> %F A126865 From _Antti Karttunen_, Dec 17 2018: (Start) %F A126865 a(n) = gcd(A003958(n), A003959(n)). %F A126865 a(A007947(n)) = A066086(n). %F A126865 (End) %e A126865 400 = 2^4 * 5^2. So a(400) = gcd((2+1)^4 * (5+1)^2, (2-1)^4 * (5-1)^2) = gcd(2916, 16) = 4. %t A126865 f[n_] := Block[{fi = FactorInteger@n}, GCD[Times @@ ((First /@ fi - 1)^Last /@ fi), Times @@ ((First /@ fi + 1)^Last /@ fi)]]; Array[f, 99] (* _Robert G. Wilson v_, Sep 08 2007 *) %o A126865 (PARI) %o A126865 A003958(n) = { my(f = factor(n)); for(i=1, #f~, f[i, 1]--); factorback(f); }; %o A126865 A003959(n) = { my(f = factor(n)); for(i=1, #f~, f[i, 1]++); factorback(f); }; %o A126865 A126865(n) = gcd(A003958(n),A003959(n)); \\ _Antti Karttunen_, Dec 17 2018 %Y A126865 Cf. A003958, A003959, A066086, A322362. %K A126865 nonn %O A126865 1,3 %A A126865 _Leroy Quet_, Mar 15 2007 %E A126865 More terms from _Robert G. Wilson v_, Sep 08 2007