login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A146986 Triangle, read by rows, T(n, k) = binomial(n, k) for n < 2 and binomial(n, k) + 2^(n-1) * binomial(n-2, k-1) otherwise. 3
1, 1, 1, 1, 4, 1, 1, 7, 7, 1, 1, 12, 22, 12, 1, 1, 21, 58, 58, 21, 1, 1, 38, 143, 212, 143, 38, 1, 1, 71, 341, 675, 675, 341, 71, 1, 1, 136, 796, 1976, 2630, 1976, 796, 136, 1, 1, 265, 1828, 5460, 9086, 9086, 5460, 1828, 265, 1, 1, 522, 4141, 14456, 28882, 36092, 28882, 14456, 4141, 522, 1 (list; table; graph; refs; listen; history; text; internal format)
OFFSET
0,5
COMMENTS
Row sums are: {1, 2, 6, 16, 48, 160, 576, 2176, 8448, 33280, 132096, ...} = {1, 2, 2*A242985(n)}. (modified by G. C. Greubel, Jan 09 2020)
LINKS
FORMULA
T(n, k) = binomial(n, k) for n < 2 and binomial(n, k) + 2^(n-1) * binomial(n-2, k-1) otherwise.
Sum_{k=0..n} T(n,k) = n+1 for n < 2 and 16*binomial(2^(n-3) + 1, 2) otherwise. - G. C. Greubel, Jan 09 2020
EXAMPLE
Triangle begins as:
1;
1, 1;
1, 4, 1;
1, 7, 7, 1;
1, 12, 22, 12, 1;
1, 21, 58, 58, 21, 1;
1, 38, 143, 212, 143, 38, 1;
MAPLE
q:=2; seq(seq( `if`(n<2, binomial(n, k), binomial(n, k) + q^(n-1)*binomial(n-2, k-1)), k=0..n), n=0..10); # G. C. Greubel, Jan 09 2020
MATHEMATICA
Table[If[n<2, Binomial[n, m], Binomial[n, m] + 2^(n-1)*Binomial[n-2, m-1]], {n, 0, 10}, {m, 0, n}]//Flatten
PROG
(PARI) T(n, k) = if(n<2, binomial(n, k), binomial(n, k) + 2^(n-1)*binomial(n-2, k-1) ); \\ G. C. Greubel, Jan 09 2020
(Magma) T:= func< n, k, q | n lt 2 select Binomial(n, k) else Binomial(n, k) + q^(n-1)*Binomial(n-2, k-1) >;
[T(n, k, 2): k in [0..n], n in [0..10]]; // G. C. Greubel, Jan 09 2020
(Sage)
@CachedFunction
def T(n, k, q):
if (n<2): return binomial(n, k)
else: return binomial(n, k) + q^(n-1)*binomial(n-2, k-1)
[[T(n, k, 2) for k in (0..n)] for n in (0..10)] # G. C. Greubel, Jan 09 2020
(GAP)
T:= function(n, k, q)
if n<2 then return Binomial(n, k);
else return Binomial(n, k) + q^(n-1)*Binomial(n-2, k-1);
fi; end;
Flat(List([0..10], n-> List([0..n], k-> T(n, k, 2) ))); # G. C. Greubel, Jan 09 2020
CROSSREFS
Sequence in context: A124376 A047671 A081577 * A304141 A305047 A316733
KEYWORD
nonn,tabl
AUTHOR
Roger L. Bagula, Nov 04 2008
EXTENSIONS
Edited by G. C. Greubel, Jan 09 2020
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 10:51 EDT 2024. Contains 371967 sequences. (Running on oeis4.)