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 A332309 #15 Nov 09 2020 02:57:29 %S A332309 1,1,1,2,1,3,4,9,9,6,15,17,38,29,53,70,65,91,150,229,277,236,439,489, %T A332309 514,897,993,1632,1521,2339,2972,3257,4121,5992,5303,7729,10932,15157, %U A332309 17653,18398,26305,31683,34408,51885,58173,61098,90519,101249,143402,156905 %N A332309 Number of compositions (ordered partitions) of n into distinct parts where no part is a multiple of 3. %H A332309 Alois P. Heinz, <a href="/A332309/b332309.txt">Table of n, a(n) for n = 0..5000</a> %H A332309 <a href="/index/Com#comp">Index entries for sequences related to compositions</a> %e A332309 a(9) = 6 because we have [8, 1], [7, 2], [5, 4], [4, 5], [2, 7] and [1, 8]. %p A332309 b:= proc(n, i, p) option remember; `if`(i*(i+1)/2<n, 0, `if`(n=0, %p A332309 p!, add(b(n-i*j, i-1, p+j), j=0..min(irem(i, 3), 1, n/i)))) %p A332309 end: %p A332309 a:= n-> b(n$2, 0): %p A332309 seq(a(n), n=0..55); # _Alois P. Heinz_, Feb 09 2020 %t A332309 b[n_, i_, p_] := b[n, i, p] = If[i(i+1)/2 < n, 0, If[n == 0, p!, Sum[b[n - i j, i - 1, p + j], {j, 0, Min[Mod[i, 3], 1, n/i]}]]]; %t A332309 a[n_] := b[n, n, 0]; %t A332309 a /@ Range[0, 55] (* _Jean-François Alcover_, Nov 09 2020, after _Alois P. Heinz_ *) %Y A332309 Cf. A000726, A003105, A032020, A032021, A332310, A332311. %K A332309 nonn %O A332309 0,4 %A A332309 _Ilya Gutkovskiy_, Feb 09 2020