cp's OEIS Frontend

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.

A096137 Table read by rows: row n contains the sum of each nonempty subset of {1, 2, ..., n}. In each row, the sums are arranged in ascending order.

This page as a plain text file.
%I A096137 #17 Feb 14 2021 09:47:54
%S A096137 1,1,2,3,1,2,3,3,4,5,6,1,2,3,3,4,4,5,5,6,6,7,7,8,9,10,1,2,3,3,4,4,5,5,
%T A096137 5,6,6,6,7,7,7,8,8,8,9,9,9,10,10,10,11,11,12,12,13,14,15,1,2,3,3,4,4,
%U A096137 5,5,5,6,6,6,6,7,7,7,7,8,8,8,8,9,9,9,9,9,10,10,10,10,10,11,11,11,11,11,12
%N A096137 Table read by rows: row n contains the sum of each nonempty subset of {1, 2, ..., n}. In each row, the sums are arranged in ascending order.
%C A096137 The n-th row has 2^n-1 members. A001788 gives the row sums. The sums of the k-element subsets of {1, 2, ..., n} add up to A094305(n-1, k-1).
%H A096137 Alois P. Heinz, <a href="/A096137/b096137.txt">Rows n = 1..15, flattened</a>
%e A096137 The nonempty subsets of {1, 2, 3} are {1}, {2}, {3}, {1,2}, {1,3}, {2,3} and {1,2,3}, which have sums 1, 2, 3, 3, 4, 5 and 6 respectively, so these are the terms of row 3.
%e A096137 Triangle T(n,k) begins:
%e A096137   1;
%e A096137   1, 2, 3;
%e A096137   1, 2, 3, 3, 4, 5, 6;
%e A096137   1, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 9, 10;
%e A096137   ...
%p A096137 T:= proc(n) option remember; `if`(n=0, [][], subsop(1=[][],
%p A096137       sort(map(x-> (x, x+n), [0, T(n-1)])))[])
%p A096137     end:
%p A096137 seq(T(n), n=1..7);  # _Alois P. Heinz_, Jul 24 2019
%t A096137 T[n_] := T[n] = Total /@ Subsets[Range[n], {1, n}] // Sort;
%t A096137 Array[T, 7] // Flatten (* _Jean-François Alcover_, Feb 14 2021 *)
%Y A096137 Cf. A001788, A094305.
%K A096137 nonn,easy,look,tabf
%O A096137 1,3
%A A096137 _Amarnath Murthy_, Jul 06 2004
%E A096137 Edited and extended by _David Wasserman_, Oct 04 2007