OFFSET
1,2
LINKS
Alois P. Heinz, Table of n, a(n) for n = 1..10000
EXAMPLE
a(8) = 24 because the smallest prime factor of 9 is 3 and 8*3 = 24.
MAPLE
with(numtheory):
a:= n-> n*`if`(isprime(n+1), 1, min(factorset(n+1)[])):
seq(a(n), n=1..100); # Alois P. Heinz, Mar 03 2014
PROG
(Sage)
q=100 #change q for more terms
[n if is_prime(n+1) else n*min(prime_divisors(n+1)) for n in [1..q]] # Tom Edgar, Mar 03 2014
CROSSREFS
KEYWORD
nonn
AUTHOR
J. Lowell, Mar 01 2014
EXTENSIONS
More terms from Tom Edgar, Mar 03 2014
STATUS
approved