login
Triangle read by rows: T(n,m)=floor[(m/n)*row(n)].
0

%I #4 Mar 30 2012 17:34:28

%S 1,1,1,1,6,1,1,23,23,1,1,48,286,48,1,1,384,1535,1535,384,1,1,3840,

%T 7680,23038,7680,3840,1,1,46080,92160,184319,184319,92160,46080,1,1,

%U 645120,1290240,1935360,2580478,1935360,1290240,645120,1,1,10321920,20643840

%N Triangle read by rows: T(n,m)=floor[(m/n)*row(n)].

%C Row sums: A000165

%e {1},

%e {1, 1},

%e {1, 6, 1},

%e {1, 23, 23, 1},

%e {1, 48, 286, 48, 1},

%e {1, 384, 1535, 1535, 384, 1},

%e {1, 3840, 7680, 23038, 7680, 3840, 1},

%e {1, 46080, 92160, 184319, 184319, 92160, 46080, 1},

%e {1, 645120, 1290240, 1935360, 2580478, 1935360, 1290240, 645120, 1},

%e {1, 10321920, 20643840, 30965760, 30965759, 30965759, 30965760, 20643840, 10321920, 1},

%e {1, 185794560, 371589120, 557383680, 743178240, -2, 743178240, 557383680, 371589120, 185794560, 1}

%t Clear[v, n, row, f]; row[n_] = 2^n*n!;

%t f[n_, m_] = Floor[(m/n)*row[n]/2]; v[0] = {1}; v[1] = {1, 1};

%t v[n_] := v[n] = If[Mod[n, 2] == 0, Join[{1}, Table[ f[n, m], {m, 1, Floor[ n/2] - 1}], {row[n] - 2*Sum[ f[n, m], {m, 1, Floor[n/2] - 1}] - 2}, Table[ f[n, m], {m, Floor[n/ 2] - 1, 1, -1}], { 1}],

%t Join[{1}, Table[ f[n, m], {m, 1, Floor[n/2] - 1}], {row[n]/2 - Sum[ f[n, m], { m, 1, Floor[n/2] - 1}] - 1, row[n]/ 2 - Sum[ f[n, m], {m, 1, Floor[ n/2] - 1}] - 1}, Table[ f[n, m], {m, Floor[n/ 2] - 1, 1, -1}], {1}]];

%t Table[v[n], {n, 0, 10}]; Flatten[%]

%K nonn,tabl

%O 0,5

%A _Roger L. Bagula_, Dec 16 2008

%E Edited by _N. J. A. Sloane_, Jan 31 2009