OFFSET
2,3
LINKS
FORMULA
EXAMPLE
For n = 12:
- the prime factors of 12 are 2 and 3,
- 3^4 > 2^4 >= 12 > 2^3,
- hence a(n) = 4.
MATHEMATICA
Array[If[PrimeQ@ #, 1, Ceiling@ Log[FactorInteger[#][[1, 1]], #]] &, 105, 2] (* Michael De Vlieger, May 08 2019 *)
PROG
(PARI) a(n) = my (f=factor(n)); logint(n, f[1, 1]) + if (#f~>1, 1, 0)
(Python)
from operator import sub
from sympy import integer_log, primefactors
def A307908(n): return 1+sub(*integer_log(n, min(primefactors(n)))) # Chai Wah Wu, Oct 12 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Rémy Sigrist, May 05 2019
STATUS
approved