The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A119673 T(n, k) = 3*T(n-1, k-1) + T(n-1, k) for k < n and T(n, n) = 1, T(n, k) = 0, if k < 0 or k > n; triangle read by rows. 2
1, 1, 1, 1, 4, 1, 1, 7, 13, 1, 1, 10, 34, 40, 1, 1, 13, 64, 142, 121, 1, 1, 16, 103, 334, 547, 364, 1, 1, 19, 151, 643, 1549, 2005, 1093, 1, 1, 22, 208, 1096, 3478, 6652, 7108, 3280, 1, 1, 25, 274, 1720, 6766, 17086, 27064, 24604, 9841, 1, 1, 28, 349, 2542, 11926, 37384, 78322, 105796, 83653, 29524, 1 (list; table; graph; refs; listen; history; text; internal format)
OFFSET
0,5
LINKS
FORMULA
T(n,k) = R(n,k,3) where R(n,k,m) = (1-m)^(-n+k)-m^(k+1)*Pochhammer(n-k, k+1)* hyper2F1([1,n+1],[k+2],m)/(k+1)!. - Peter Luschny, Jul 25 2014
EXAMPLE
Triangle begins:
1;
1, 1;
1, 4, 1;
1, 7, 13, 1;
1, 10, 34, 40, 1;
1, 13, 64, 142, 121, 1;
1, 16, 103, 334, 547, 364, 1;
1, 19, 151, 643, 1549, 2005, 1093, 1;
1, 22, 208, 1096, 3478, 6652, 7108, 3280, 1;
1, 25, 274, 1720, 6766, 17086, 27064, 24604, 9841, 1;
MAPLE
T := (n, k, m) -> (1-m)^(-n+k)-m^(k+1)*pochhammer(n-k, k+1)* hypergeom([1, n+1], [k+2], m)/(k+1)!; A119673 := (n, k) -> T(n, k, 3);
seq(print(seq(round(evalf(A119673(n, k))), k=0..n)), n=0..10); # Peter Luschny, Jul 25 2014
MATHEMATICA
T[_, 0]=1; T[n_, n_]=1; T[n_, k_]/; 0<k<n := T[n, k] = 3T[n-1, k-1] + T[n-1, k]; T[_, _] = 0;
Table[T[n, k], {n, 0, 10}, {k, 0, n}] (* Jean-François Alcover, Jun 13 2019 *)
PROG
(PARI) T(n, k) = if(k<0 || k>n, 0, if(k==n, 1, 3*T(n-1, k-1) +T(n-1, k)));
for(n=0, 12, for(k=0, n, print1(T(n, k), ", "))) \\ G. C. Greubel, Nov 18 2019
(Magma)
function T(n, k)
if k lt 0 or k gt n then return 0;
elif k eq n then return 1;
else return 3*T(n-1, k-1) + T(n-1, k);
end if;
return T;
end function;
[T(n, k): k in [0..n], n in [0..12]]; // G. C. Greubel, Nov 18 2019
(Sage)
@CachedFunction
def T(n, k):
if (k<0 or k>n): return 0
elif (k==n): return 1
else: return 3*T(n-1, k-1) + T(n-1, k)
[[T(n, k) for k in (0..n)] for n in (0..12)] # G. C. Greubel, Nov 18 2019
CROSSREFS
Sequence in context: A209414 A193636 A232968 * A144447 A051455 A346875
KEYWORD
easy,nonn,tabl
AUTHOR
Zerinvary Lajos, Jun 11 2006
EXTENSIONS
Definition clarified by Philippe Deléham, Jun 13 2006
Entry revised by N. J. A. Sloane, Jun 19 2006
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 May 17 17:07 EDT 2024. Contains 372603 sequences. (Running on oeis4.)