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.

A107286 a(0) = 0; for n>0, minimal prime factor of n, or 1 if n is 1 or a prime.

Original entry on oeis.org

0, 1, 1, 1, 2, 1, 2, 1, 2, 3, 2, 1, 2, 1, 2, 3, 2, 1, 2, 1, 2, 3, 2, 1, 2, 5, 2, 3, 2, 1, 2, 1, 2, 3, 2, 5, 2, 1, 2, 3, 2, 1, 2, 1, 2, 3, 2, 1, 2, 7, 2, 3, 2, 1, 2, 5, 2, 3, 2, 1, 2, 1, 2, 3, 2, 5, 2, 1, 2, 3, 2, 1, 2, 1, 2, 3, 2, 7, 2, 1, 2, 3, 2, 1, 2, 5, 2, 3, 2, 1, 2, 7, 2, 3, 2, 5, 2, 1, 2, 3
Offset: 0

Views

Author

Giovanni Teofilatto, May 20 2005

Keywords

Crossrefs

Cf. A020639.

Programs

  • PARI
    a(n) = if (n==0, 0, if (n==1, 1, if (isprime(n), 1, factor(n)[1,1]))) \\ Michel Marcus, Jun 03 2013