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.
%I A342139 #16 Aug 25 2021 05:27:57 %S A342139 1,1,3,8,28,167,810,4664,38344,207255,2059900,19385131,174417011, %T A342139 1922011637,21058799803,208257199434,2905150193223,38462668421772, %U A342139 481607876817202,7526871509864950 %N A342139 Number of partitions of [2n] into pairs whose sums or differences are primes. %H A342139 Wikipedia, <a href="https://en.wikipedia.org/wiki/Partition_of_a_set">Partition of a set</a> %e A342139 a(2) = 3: {{1,4}, {2,3}}, {{1,3}, {2,4}}, {{1,2}, {3,4}}. %p A342139 b:= proc(s) option remember; `if`(s={}, 1, (j-> add(`if`(i<j and %p A342139 ormap(isprime, [j+i, j-i]), b(s minus {i, j}), 0), i=s))(max(s))) %p A342139 end: %p A342139 a:= n-> b({$1..2*n}): %p A342139 seq(a(n), n=0..15); %t A342139 b[s_] := b[s] = If[s == {}, 1, With[{j = Max[s]}, Sum[If[i < j && AnyTrue[{j+i, j-i}, PrimeQ], b[s ~Complement~ {i, j}], 0], {i, s}]]]; %t A342139 a[n_] := b[Range[2n]]; %t A342139 a /@ Range[0, 15] (* _Jean-François Alcover_, Aug 25 2021, after _Alois P. Heinz_ *) %Y A342139 Cf. A000341, A009692, A342136, A342155. %K A342139 nonn,more %O A342139 0,3 %A A342139 _Alois P. Heinz_, Mar 01 2021