login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A302301
Number of ways to write n as a sum of two distinct semiprimes.
1
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 1, 1, 1, 0, 1, 2, 1, 1, 0, 1, 2, 2, 1, 1, 1, 2, 2, 3, 2, 0, 1, 3, 3, 2, 1, 3, 3, 2, 2, 4, 3, 2, 1, 4, 5, 3, 2, 1, 2, 3, 2, 5, 3, 2, 2, 5, 6, 6, 1, 3, 5, 3, 3, 4, 4, 3, 2, 6, 7, 5, 3, 3, 3, 4, 3, 5, 5, 3, 2, 7, 7, 2, 4
OFFSET
0,20
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..20000 (first 1000 terms from Harvey P. Dale)
FORMULA
a(n) = Sum_{i=1..floor((n-1)/2)} [Omega(i) = 2] * [Omega(n-i) = 2], where Omega = A001222 and [] is the Iverson bracket.
EXAMPLE
a(19) = 2; 19 = 15+4 = 10+9.
MAPLE
h:= proc(n) option remember; `if`(n=0, 0,
`if`(numtheory[bigomega](n)=2, n, h(n-1)))
end:
b:= proc(n, i) option remember; series(`if`(n=0, 1, `if`(i<1, 0,
`if`(i>n, 0, x*b(n-i, h(min(n-i, i-1))))+b(n, h(i-1)))), x, 3)
end:
a:= n-> coeff(b(n, h(n)), x, 2):
seq(a(n), n=0..120); # Alois P. Heinz, May 26 2021
MATHEMATICA
Table[Sum[KroneckerDelta[PrimeOmega[i], 2] KroneckerDelta[PrimeOmega[n - i], 2], {i, Floor[(n - 1)/2]}], {n, 100}]
Table[Count[IntegerPartitions[n, {2}], _?(PrimeOmega[#[[1]]]==PrimeOmega[#[[2]]]==2&&#[[1]]!=#[[2]]&)], {n, 90}] (* Harvey P. Dale, Aug 03 2020 *)
PROG
(PARI) a(n) = sum(i=1, (n-1)\2, (bigomega(i)==2)*(bigomega(n-i)==2)); \\ Michel Marcus, Apr 08 2018
CROSSREFS
KEYWORD
nonn,look,easy
AUTHOR
Wesley Ivan Hurt, Apr 04 2018
STATUS
approved