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.

A141198 a(n) is the number of divisors of n that are each one more than a power of a prime.

Original entry on oeis.org

0, 1, 1, 2, 1, 3, 0, 3, 2, 3, 0, 5, 0, 2, 2, 3, 1, 5, 0, 5, 1, 1, 0, 7, 1, 2, 2, 4, 0, 6, 0, 4, 2, 2, 1, 7, 0, 2, 1, 6, 0, 5, 0, 3, 3, 1, 0, 8, 0, 4, 2, 3, 0, 6, 1, 5, 1, 1, 0, 10, 0, 2, 2, 4, 2, 4, 0, 4, 1, 4, 0, 10, 0, 2, 2, 3, 0, 4, 0, 7, 2, 2, 0, 9, 2, 1, 1, 4, 0, 9, 0, 2, 1, 1, 1, 9, 0, 3, 3, 6, 0, 5, 0
Offset: 1

Views

Author

Leroy Quet, Jun 12 2008

Keywords

Comments

1 is considered here to be a power of a prime. 0 is not considered here to be a power of a prime.

Examples

			The divisors of 9 are 1, 3 and 9. 1 is one more than 0, not a power of a prime. 3 is one more than 2, a power of a prime. And 9 is one more than 8, a power of a prime. There are therefore 2 such divisors that are each one more than a power of a prime. So a(9) = 2.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := DivisorSum[n, 1 &, # == 2 || PrimePowerQ[#-1] &]; Array[a, 100] (* Amiram Eldar, Jun 22 2025 *)
  • PARI
    a(n) = sumdiv(n, d, d == 2 || isprimepower(d - 1)); \\ Amiram Eldar, Jun 22 2025

Extensions

Corrected and extended by Diana L. Mecum, Jul 05 2007