OFFSET
0,5
LINKS
G. C. Greubel, Rows n=0..100 of triangle, flattened
FORMULA
T(n,k) = 3^min(k, n-k) = 3^A004197(n,k). - Philippe Deléham, Feb 25 2014
EXAMPLE
Triangle begins
{1},
{1, 1},
{1, 3, 1},
{1, 3, 3, 1},
{1, 3, 9, 3, 1},
{1, 3, 9, 9, 3, 1},
{1, 3, 9, 27, 9, 3, 1},
{1, 3, 9, 27, 27, 9, 3, 1},
{1, 3, 9, 27, 81, 27, 9, 3, 1},
{1, 3, 9, 27, 81, 81, 27, 9, 3, 1},
{1, 3, 9, 27, 81, 243, 81, 27, 9, 3, 1}
MATHEMATICA
Clear[a, k, m]; k = 3; a[0] = {1}; a[1] = {1, 1};
a[n_] := a[n] = Join[{1}, k*a[n - 2], {1}];
Table[a[n], {n, 0, 10}];
Flatten[%]
Table[3^(Min[k, n - k]), {n, 0, 100}, {k, 0, n}] // Flatten (* G. C. Greubel, Sep 01 2018 *)
PROG
(PARI) for(n=0, 15, for(k=0, n, print1(3^(min(k, n-k)), ", "))) \\ G. C. Greubel, Sep 01 2018
(Magma) [[3^(Min(k, n-k)): k in [0..n]]: n in [0..15]]; // G. C. Greubel, Sep 01 2018
CROSSREFS
KEYWORD
AUTHOR
Roger L. Bagula and Gary W. Adamson, Dec 11 2008
EXTENSIONS
Better name by Philippe Deléham, Feb 25 2014
STATUS
approved