OFFSET
1,2
COMMENTS
a(n) = A064554(n) for 1 <= n < 91, but a(91) = 481 differs from A064554(91) = 463. - Georg Fischer, Oct 23 2018
LINKS
FORMULA
From Antti Karttunen, Aug 08 2017: (Start)
(End)
MATHEMATICA
Array[If[# == 1, 1, Times @@ Map[Prime[#1 - 1]^#2 & @@ # &, FactorInteger[#]]] &, 65] (* Michael De Vlieger, Apr 22 2021 *)
PROG
(PARI) a(n) = {my(f = factor(n)); for (k=1, #f~, f[k, 1] = prime(f[k, 1]-1); ); factorback(f); }
(Scheme) (define (A290641 n) (if (= 1 n) n (* (A000040 (+ -1 (A020639 n))) (A290641 (A032742 n))))) ;; Antti Karttunen, Aug 08 2017
(Python)
from sympy import factorint, prime
from operator import mul
from functools import reduce
def a(n):
return 1 if n==1 else reduce(mul, [prime(p - 1)**e for p, e in factorint(n).items()])
print([a(n) for n in range(1, 101)]) # Indranil Ghosh, Aug 08 2017
CROSSREFS
KEYWORD
nonn,mult
AUTHOR
Michel Marcus, Aug 08 2017
STATUS
approved