A382871 Number of ways to partition distinct prime numbers into two disjoint sets such that the sum of each set equals n.
1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 2, 3, 3, 2, 3, 4, 6, 2, 5, 0, 5, 9, 7, 14, 8, 6, 10, 9, 21, 19, 11, 18, 15, 29, 34, 35, 34, 24, 31, 51, 55, 48, 76, 34, 60, 93, 89, 97, 91, 76, 83, 156, 164, 189, 145, 157, 172, 186, 283, 276, 218, 242, 280, 405, 433, 476, 446
Offset: 0
Keywords
Examples
a(18) = 2: [13, 5; 11, 7], [13, 3, 2; 11, 7]. a(19) = 3: [19; 17, 2], [19; 11, 5, 3], [17, 2; 11, 5, 3].
Programs
-
PARI
a(n) = my(x='x+O('x^(n+1)), y='y+O('y^(n+1)));if(n==0, 1, polcoef(polcoef(prod(k=1, n, 1+x^prime(k)+y^prime(k)), n), n)/2);
Formula
a(n) = 1/2 * [(x*y)^n] Product_{p prime} (1 + x^p + y^p) for n > 0.
Comments