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!)
A156319 Triangle by columns: (1, 2, 0, 0, 0, ...) in every column. 2
1, 2, 1, 0, 2, 1, 0, 0, 2, 1, 0, 0, 0, 2, 1, 0, 0, 0, 0, 2, 1, 0, 0, 0, 0, 0, 2, 1, 0, 0, 0, 0, 0, 0, 2, 1, 0, 0, 0, 0, 0, 0, 0, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 1 (list; table; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
Binomial transform of the triangle = A110813.
Eigensequence of the triangle = A001045
Inverse = a triangle with (1, -2, 4, -8, 16, ...) in every column.
Triangle T(n,k), 0 <= k <= n, given by [2,-2,0,0,0,0,0,0,...] DELTA [1,0,0,0,0,0,0,0,...] where DELTA is the operator defined in A084938. - Philippe Deléham, Feb 08 2009
LINKS
FORMULA
Triangle read by rows, T(n,k) = 1 if n=k, 2 if k = n-1, 0 otherwise.
By columns, (1, 2, 0, 0, 0, ...) in every column.
T(n,k) = A097806(n,k)*2^(n-k). - Philippe Deléham, Feb 08 2009
G.f.: (1+2*x)*x*y/(1-x*y). - R. J. Mathar, Aug 12 2015
EXAMPLE
First few rows of the triangle:
1;
2, 1;
0, 2, 1;
0, 0, 2, 1;
0, 0, 0, 2, 1;
0, 0, 0, 0, 2, 1;
0, 0, 0, 0, 0, 2, 1;
0, 0, 0, 0, 0, 0, 2, 1;
0, 0, 0, 0, 0, 0, 0, 2, 1;
...
MAPLE
T:= proc (n) option remember;
if k=n then 1
elif k=n-1 then 2
else 0 fi;
end proc;
seq(seq(T(n, k), k=1..n), n = 1..15); # G. C. Greubel, Sep 20 2019
MATHEMATICA
Table[If[k==n, 1, If[k==n-1, 2, 0]], {n, 15}, {k, n}]//Flatten (* G. C. Greubel, Sep 20 2019 *)
Join[{1}, Flatten[Table[PadRight[{2, 1}, n, 0], {n, 3, 20}]]] (* Harvey P. Dale, Feb 28 2022 *)
PROG
(PARI) T(n, k) = if(k==n, 1, if(k==n-1, 2, 0)); \\ G. C. Greubel, Sep 20 2019
(Magma) T:= func< n, k | k eq n select 1 else k eq n-1 select 2 else 0 >;
[T(n, k): k in [1..n], n in [1..15]]; // G. C. Greubel, Sep 20 2019
(Sage)
def T(n, k):
if (k==n): return 1
elif (k==n-1): return 2
else: return 0
[[T(n, k) for k in (1..n)] for n in (1..15)] # G. C. Greubel, Sep 20 2019
(GAP)
T:= function(n, k)
if k=n then return 1;
elif k=n-1 then return 2;
else return 0;
fi;
end;
Flat(List([1..15], n-> List([1..n], k-> T(n, k) ))); # G. C. Greubel, Sep 20 2019
CROSSREFS
Sequence in context: A058531 A093073 A251635 * A190893 A030204 A083650
KEYWORD
nonn,tabl,easy
AUTHOR
Gary W. Adamson, Feb 07 2009
EXTENSIONS
More terms added by G. C. Greubel, Sep 20 2019
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 08:27 EDT 2024. Contains 371964 sequences. (Running on oeis4.)