|
|
A067513
|
|
Number of divisors d of n such that d+1 is prime.
|
|
27
|
|
|
1, 2, 1, 3, 1, 3, 1, 3, 1, 3, 1, 5, 1, 2, 1, 4, 1, 4, 1, 4, 1, 3, 1, 5, 1, 2, 1, 4, 1, 5, 1, 4, 1, 2, 1, 7, 1, 2, 1, 5, 1, 4, 1, 4, 1, 3, 1, 6, 1, 3, 1, 4, 1, 4, 1, 4, 1, 3, 1, 8, 1, 2, 1, 4, 1, 5, 1, 3, 1, 4, 1, 8, 1, 2, 1, 3, 1, 4, 1, 6, 1, 3, 1, 7, 1, 2, 1, 5, 1, 6, 1, 4, 1, 2, 1, 7, 1, 2, 1, 5, 1, 4, 1
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
1, 2 and 4 are the only numbers such that for every divisor d, d+1 is a prime.
These and only these primes appear as prime divisors of any term of InvPhi[n] set if n is not empty, i.e., if n is from A002202. - Labos Elemer, Jun 24 2002
a(n) is the number of integers k such that n = k - k/p where p is one of the prime divisors of k. (See e.g., A064097, A333123 that are related to the mapping k -> k - k/p.) - Robert G. Wilson v, Jun 12 2022
|
|
LINKS
|
|
|
FORMULA
|
|
|
EXAMPLE
|
a(12) = 5 as the divisors of 12 are 1, 2, 3, 4, 6 and 12 and the corresponding primes are 2,3,5,7 and 13. Only 3+1 = 4 is not a prime.
|
|
MAPLE
|
local a, d;
a := 0 ;
for d in numtheory[divisors](n) do
if isprime(d+1) then
a := a+1 ;
end if;
end do:
a ;
end proc:
|
|
MATHEMATICA
|
a[n_] := Length[Select[Divisors[n]+1, PrimeQ]]
Table[Count[Divisors[n], _?(PrimeQ[#+1]&)], {n, 110}] (* Harvey P. Dale, Feb 29 2012 *)
|
|
PROG
|
(Haskell)
a067513 = sum . map (a010051 . (+ 1)) . a027750_row
(Python)
from sympy import divisors, isprime
def a(n): return sum(1 for d in divisors(n, generator=True) if isprime(d+1))
|
|
CROSSREFS
|
Cf. A000005, A001221, A001222, A002202, A027750, A064097, A185633, A202727, A202728, A322312, A322976, A333123, A346467, A355452.
|
|
KEYWORD
|
easy,nonn,nice
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|