A078899 Number of times the greatest prime factor of n is the greatest prime factor for numbers <=n; a(1)=1.
1, 1, 1, 2, 1, 2, 1, 3, 3, 2, 1, 4, 1, 2, 3, 4, 1, 5, 1, 4, 3, 2, 1, 6, 5, 2, 7, 4, 1, 6, 1, 5, 3, 2, 5, 8, 1, 2, 3, 7, 1, 6, 1, 4, 8, 2, 1, 9, 7, 9, 3, 4, 1, 10, 5, 8, 3, 2, 1, 10, 1, 2, 9, 6, 5, 6, 1, 4, 3, 10, 1, 11, 1, 2, 11, 4, 7, 6, 1, 12, 12, 2, 1, 11, 5, 2, 3, 8, 1, 13, 7, 4, 3, 2, 5, 13, 1, 12, 9
Offset: 1
Links
- Alois P. Heinz, Table of n, a(n) for n = 1..20000
Programs
-
Maple
p:= proc() 0 end: a:= proc(n) option remember; local t; t:= max(numtheory[factorset](n)[]); p(t):= p(t)+1 end: seq(a(n), n=1..100); # Alois P. Heinz, Oct 09 2015
-
Mathematica
p[_] = 0; a[1] = 1; a[n_] := a[n] = Module[{t}, t = FactorInteger[n][[-1, 1]]; p[t] = p[t]+1]; Array[a, 100] (* Jean-François Alcover, Jun 09 2018, after Alois P. Heinz *)
Formula
Ordinal transform of A006530 (Gpf). - Franklin T. Adams-Watters, Aug 28 2006
Comments