cp's OEIS Frontend

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.

A322354 Greatest common divisor of product p and product (p+2), where p ranges over distinct prime divisors of n; a(n) = gcd(A007947(n), A166590(A007947(n))).

Original entry on oeis.org

1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 5, 2, 1, 2, 1, 2, 3, 2, 1, 2, 1, 2, 1, 2, 1, 10, 1, 2, 1, 2, 7, 2, 1, 2, 3, 2, 1, 6, 1, 2, 5, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 3, 2, 1, 10, 1, 2, 3, 2, 5, 2, 1, 2, 1, 14, 1, 2, 1, 2, 5, 2, 1, 6, 1, 2, 1, 2, 1, 6, 1, 2, 1, 2, 1, 10, 1, 2, 3, 2, 1, 2, 1, 2, 1, 2, 1, 2, 1, 2, 105
Offset: 1

Views

Author

Antti Karttunen, Dec 16 2018

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_] := If[n == 1, 1, Times @@ Power @@@ ({#[[1]] + 2, #[[2]]} & /@ FactorInteger[n])]; rad[n_] := Times @@ (First@# & /@ FactorInteger@n); a[n_] := GCD[rad[n], f[rad[n]]]; Array[a, 120] (* Amiram Eldar, Dec 16 2018 *)
  • PARI
    A166590(n) = { my(f = factor(n)); for(i=1, #f~, f[i, 1] += 2); factorback(f); };
    A322362(n) = gcd(n, A166590(n));
    A007947(n) = factorback(factorint(n)[, 1]);
    A322354(n) = A322362(A007947(n));
    \\ Alternatively as:
    A322354(n) = gcd(A007947(n), A166590(A007947(n)));

Formula

a(n) = A322362(A007947(n)) = gcd(A007947(n), A166590(A007947(n))).
a(n) = A322356(n) * A322357(n).