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 A334250 #38 Jul 19 2025 11:58:03 %S A334250 1,1,2,4,12,35,129,567,2920,16110,103467,717608,5748214,47937957, %T A334250 441139750,4319093093,45963368076,510202534002,6150655137844, %U A334250 76789781005325,1028853084775725,14294680087131380 %N A334250 Number of set partitions of [3n] into 3-element subsets {i, i+k, i+2k} with 1<=k<=n. %C A334250 Differs from A331621 first at n=7. %H A334250 Wikipedia, <a href="https://en.wikipedia.org/wiki/Partition_of_a_set">Partition of a set</a> %F A334250 a(n) <= A104429(n) <= A025035(n). %e A334250 a(2) = 2: 123|456, 135|246. %e A334250 a(3) = 4: 123|456|789, 123|468|579, 135|246|789, 147|258|369. %p A334250 b:= proc(s, t) option remember; `if`(s={}, 1, (m-> add( %p A334250 `if`({m-j, m-2*j} minus s={}, b(s minus {m, m-j, m-2*j}, %p A334250 t), 0), j=1..min(t, iquo(m-1, 2))))(max(s))) %p A334250 end: %p A334250 a:= proc(n) option remember; forget(b): b({$1..3*n}, n) end: %p A334250 seq(a(n), n=0..12); %t A334250 b[s_List, t_] := b[s, t] = If[s == {}, 1, Function[m, Sum[If[{m - j, m - 2j} ~Complement~ s == {}, b[s ~Complement~ {m, m - j, m - 2j}, t], 0], {j, 1, Min[t, Quotient[m - 1, 2]]}]][Max[s]]]; %t A334250 a[n_] := a[n] = b[Range[3n], n]; %t A334250 Table[Print[n, " ", a[n]]; a[n], {n, 0, 12}] (* _Jean-François Alcover_, May 10 2020, after Maple *) %Y A334250 Cf. A014307 (the same for 2-element subsets), A025035, A059108, A104429 (where k is not restricted), A285527, A331621, A337520. %Y A334250 Main diagonal of A360334. %K A334250 nonn,more %O A334250 0,3 %A A334250 _Alois P. Heinz_, Apr 20 2020 %E A334250 a(17)-a(21) from _Martin Fuller_, Jul 19 2025