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.
%I A102048 #26 Feb 16 2025 08:32:55 %S A102048 1,1,1,2,1,2,1,5,3,2,1,5,1,2,3,12,1,7,1,4,3,2,1,10,5,2,11,4,1,7,1,27, %T A102048 3,2,5,16,1,2,3,9,1,6,1,4,10,2,1,22,7,11,3,4,1,24,5,9,3,2,1,14,1,2,10, %U A102048 58,5,6,1,4,3,11,1,33,1,2,17,4,7,6,1,19,37,2,1,13,5,2,3,8,1,21,7,4,3,2,5 %N A102048 Exponent of A046021(n) (least inverse of Kempner function A002034) when written as a power of A006530(n) (largest prime dividing n), with a(1) = 1. %D A102048 R. L. Graham, D. E. Knuth and O. Patashnik, Factorial Factors, Section 4.4 in Concrete Mathematics, 2nd ed. Reading, MA: Addison-Wesley, pp. 111-115, 1994. %H A102048 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/GreatestPrimeFactor.html">Greatest Prime Factor</a> %H A102048 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/Factorial.html">Factorial</a> %H A102048 <a href="/index/Fa#factorial">Index entries for sequences related to factorial numbers.</a> %F A102048 a(n) = log(A046021(n))/log(A006530(n)) for n > 1. %F A102048 a(n) = 1 + Sum_{k=1..floor(log(n-1)/log(P))} floor((n-1)/P^k) for n > 1, where P = A006530(n) is the greatest prime factor of n. %e A102048 a(6) = 2 because A046021(6) = 9 = 3^2 = A006530(6)^2. %t A102048 With[{p=First[Last[FactorInteger[n, FactorComplete->True]]]}, 1+Sum[Floor[(n-1)/p^k], {k, Floor[Log[n-1]/Log[p]]}]] %o A102048 (PARI) A102048(n,p=A006530(n))=1+if(n>1,sum(k=1,logint(n-=1,p),n\p^k)) \\ _M. F. Hasler_, Nov 27 2018 %o A102048 (Python) %o A102048 from sympy import primefactors, integer_log %o A102048 def A102048(n): %o A102048 if n == 1: return 1 %o A102048 p = max(primefactors(n)) %o A102048 return 1+sum((n-1)//p**k for k in range(1,integer_log(n-1,p)[0]+1)) # _Chai Wah Wu_, Oct 17 2024 %Y A102048 Cf. A046021, A006530. %Y A102048 Cf. A294168, A276350, A299020. %K A102048 nonn %O A102048 1,4 %A A102048 _Jonathan Sondow_, Dec 26 2004