OFFSET
1,2
LINKS
T. D. Noe, Table of n, a(n) for n=1..1000
FORMULA
a(n) = n^9 - A064767(n) = n^9 - n^9 * Product (1-1/p^3)*(1-1/p^2)*(1-1/p) where the product is over all the primes p that divide n.
MATHEMATICA
f[n_] := (g = First[ Transpose[ FactorInteger[n]]]; n^9*(1 - Apply[ Times, 1 - 1/g] Apply[ Times, 1 - 1/g^2] Apply[ Times, 1 - 1/g^3])); Table[ f[n], {n, 1, 22} ]
PROG
(PARI) a(n) = {my(f = factor(n), p = f[, 1], e=f[, 2]); n^9 - prod(k = 1, #p, (p[k]-1)*(p[k]^2-1)*(p[k]^3-1)*(p[k]^(9*e[k]-6))); } \\ Amiram Eldar, Aug 03 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Dan Fux (dan.fux(AT)OpenGaia.com or danfux(AT)OpenGaia.com), Nov 25 2001
EXTENSIONS
More terms from Robert G. Wilson v, Nov 30 2001
STATUS
approved