cp's OEIS Frontend

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.

A078899 Number of times the greatest prime factor of n is the greatest prime factor for numbers <=n; a(1)=1.

Original entry on oeis.org

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

Views

Author

Reinhard Zumkeller, Dec 12 2002

Keywords

Comments

For n>1: a(n)=1 iff n is prime;
a(n) = n/p for n<=p*(p+1) and p = greatest prime factor of n.

Crossrefs

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