A103284 Triangle, read by rows, where row n+1 is formed by sorting, in ascending order, the result of the convolution of row n with {1,1}.
1, 1, 1, 1, 1, 2, 1, 2, 2, 3, 1, 3, 3, 4, 5, 1, 4, 5, 6, 7, 9, 1, 5, 9, 9, 11, 13, 16, 1, 6, 14, 16, 18, 20, 24, 29, 1, 7, 20, 29, 30, 34, 38, 44, 53, 1, 8, 27, 49, 53, 59, 64, 72, 82, 97, 1, 9, 35, 76, 97, 102, 112, 123, 136, 154, 179, 1, 10, 44, 111, 173, 179, 199, 214, 235, 259
Offset: 0
Examples
Convolution of row 5 {1,4,5,6,7,9} with {1,1} = {1,5,9,11,13,16,9}; sort to obtain row 6: {1,5,9,9,11,13,16}. Rows begin: 1, 1,1, 1,1,2, 1,2,2,3, 1,3,3,4,5, 1,4,5,6,7,9, 1,5,9,9,11,13,16, 1,6,14,16,18,20,24,29, 1,7,20,29,30,34,38,44,53, 1,8,27,49,53,59,64,72,82,97, 1,9,35,76,97,102,112,123,136,154,179,...
Links
- Reinhard Zumkeller, Rows n = 0..125 of triangle, flattened
Programs
-
Haskell
import Data.List (sort) a103284 n k = a103284_tabl !! n !! k a103284_row n = a103284_tabl !! n a103284_tabl = iterate (\xs -> sort $ zipWith (+) (xs++[0]) ([0]++xs)) [1] -- Reinhard Zumkeller, Nov 19 2015
-
PARI
{T(n,k)=local(A=vector(n+1,i,vector(i)),B);A[1][1]=1; for(k=1,n,B=vector(k+1);B[1]=1;B[k+1]=A[k][k]; for(i=2,k,B[i]=A[k][i]+A[k][i-1]); A[k+1]=vecsort(B));return(A[n+1][k+1])}
Formula
Row(n+1) = union of {1} and {T(n,k-1) + T(n,k): k=1..n}, sorted in ascending order. - Reinhard Zumkeller, Nov 19 2015
Comments