# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/ Search: id:a175933 Showing 1-1 of 1 %I A175933 #21 Mar 01 2016 23:32:48 %S A175933 0,0,1,2,1,1,1,2,2,0,1,1,2,1,1,0,1,1,2,1,1,0,1,1,2,0,0,0,1,1,1,2,2,0, %T A175933 2,0,2,1,1,0,1,1,3,1,1,0,2,1,3,0,0,0,2,1,1,0,0,0,2,1,2,1,1,0,1,0,2,1, %U A175933 1,0,1,1,3,1,1,0,2,0,1,1,1,0,1,1,2,0,0,0,2,1,2,0,0,0,1,0,1,1,1,0,1,1,3,1,1 %N A175933 Number of ways of writing n=p+k with p a prime number and k a primorial number. %C A175933 Number of partitions of n into the sum of a prime number and a primorial number. Number of decompositions of n into an unordered sum of a prime number and a primorial number. %C A175933 For n through small powers of 10, the range of partition values seen is about log_10(n)+2. - _Bill McEachen_, Jan 07 2016 %H A175933 Bill McEachen, Table of n, a(n) for n = 1..10000 %e A175933 a(4)=2 because 4(natural) = 2(prime)+2(primorial) = 3(prime)+1(primorial). %p A175933 A002110 := proc(n) option remember; if n = 0 then 1; else mul( ithprime(k),k=1..n) ; end if; end proc: %p A175933 A175933 := proc(n) a := 0 ; for k from 0 do p := A002110(k) ; if p +2 > n then return a; elif isprime(n-p) then a := a+1 ; end if; end do: end proc: %p A175933 seq(A175933(n),n=1..120) ; # _R. J. Mathar_, Oct 25 2010 %t A175933 t = Table[Product[Prime@ k, {k, n}], {n, 0, 5}]; Table[Count[Map[First, Function[k, Transpose@ {k - #, #} &@ Prime@ Range@ PrimePi@ k]@ n], x_ /; MemberQ[t, x]], {n, 120}] (* _Michael De Vlieger_, Jan 09 2016 *) %o A175933 (PARI) lyst(maxx)={n=1; while (n<=maxx,c=0; q=1; for(i5=0, n, if(i5>0, q=q*prime(i5)); if(q>n-2,break); z=truncate(q); if(isprime(n-z),c++)); print1(c,","); n+=1);} \\ _Bill McEachen_, Jan 07 2016 %o A175933 (PARI) A175933(n,p=1,k=1,c=0)={until(2>n-k*=p=nextprime(p+1),isprime(n-k)&&c++);c} \\ _M. F. Hasler_, Jan 21 2016 %Y A175933 Cf. A002110, A062602, A129363. %K A175933 nonn %O A175933 1,4 %A A175933 _Juri-Stepan Gerasimov_, Oct 24 2010 %E A175933 a(85), a(89), etc. corrected by _R. J. Mathar_, Oct 25 2010 # Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE