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.

A067432 Number of ways to represent the n-th prime in form p*q+p+q, where p and q are primes (see A066938).

This page as a plain text file.
%I A067432 #14 Feb 05 2021 05:04:07
%S A067432 0,0,0,0,1,0,1,0,2,0,1,0,1,0,2,1,1,0,0,3,0,1,1,1,0,0,0,1,0,1,1,1,0,0,
%T A067432 0,1,0,0,2,0,2,0,3,0,0,0,0,0,1,0,0,4,0,3,0,1,1,1,0,0,0,1,0,1,0,0,0,0,
%U A067432 0,0,0,4,0,0,0,3,0,0,0,0,2,0,4,0,1,1,1,0,0,0
%N A067432 Number of ways to represent the n-th prime in form p*q+p+q, where p and q are primes (see A066938).
%C A067432 a(A049084(A066938(n))) > 0; a(A049084(A198273(n))) = 0; a(A049084(A198277(n))) = n and a(A049084(m)) <> n for m < A198277(n). [_Reinhard Zumkeller_, Oct 23 2011]
%C A067432 a(n) < A072670(n).
%H A067432 Reinhard Zumkeller, <a href="/A067432/b067432.txt">Table of n, a(n) for n = 1..10000</a>
%e A067432 a(15) = 2 as A000040(15) = 47 = 3*11+3+11 = 5*7+5+7.
%o A067432 (Haskell)
%o A067432 a067432 n = length [p | let prime_n = a000040 n,
%o A067432    p <- takeWhile (< a000196 prime_n) a000040_list,
%o A067432    let (q,m) = divMod (prime_n - p) (p + 1),
%o A067432    m == 0, a010051 q == 1]
%o A067432 a067432_list = map a067432 [1..]
%o A067432 -- _Reinhard Zumkeller_, Oct 23 2011
%Y A067432 Cf. A000196, A010051.
%K A067432 nonn
%O A067432 1,9
%A A067432 _Reinhard Zumkeller_, Feb 15 2002