login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A134231
Triangle T(n, k) = n -k +1 with T(n, n-1) = 2*n-1 and T(n, n) = 1, read by rows.
1
1, 3, 1, 3, 5, 1, 4, 3, 7, 1, 5, 4, 3, 9, 1, 6, 5, 4, 3, 11, 1, 7, 6, 5, 4, 3, 13, 1, 8, 7, 6, 5, 4, 3, 15, 1, 9, 8, 7, 6, 5, 4, 3, 17, 1, 10, 9, 8, 7, 6, 5, 4, 3, 19, 1, 11, 10, 9, 8, 7, 6, 5, 4, 3, 21, 1, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 23, 1, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 25, 1
OFFSET
1,2
FORMULA
T(n, k) = A004736(n, k) + A134081(n, k) - I, an infinite lower triangular matrix, where I = Identity matrix.
From G. C. Greubel, Feb 17 2021: (Start)
T(n, k) = n - k + 1 with T(n, n-1) = 2*n - 1 and T(n, n) = 1.
Sum_{k=1..n} T(n, k) = (n-1)*(n+6)/2 + [n=1] = A134227(n). (End)
EXAMPLE
First few rows of the triangle are:
1;
3, 1;
3, 5, 1;
4, 3, 7, 1;
5, 4, 3, 9, 1;
6, 5, 4, 3, 11, 1;
7, 6, 5, 4, 3, 13, 1;
...
MATHEMATICA
T[n_, k_]:= If[k==n, 1, If[k==n-1, 2*n-1, n-k+1]];
Table[T[n, k], {n, 15}, {k, n}]//Flatten (* G. C. Greubel, Feb 17 2021 *)
PROG
(Sage)
def A134231(n, k): return 1 if k==n else 2*n-1 if k==n-1 else n-k+1
flatten([[A134231(n, k) for k in (1..n)] for n in (1..15)]) # G. C. Greubel, Feb 17 2021
(Magma)
A134231:= func< n, k | k eq n select 1 else k eq n-1 select 2*n-1 else n-k+1 >;
[A134231(n, k): k in [1..n], n in [1..15]]; // G. C. Greubel, Feb 17 2021
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
Gary W. Adamson, Oct 14 2007
EXTENSIONS
More terms and title changed by G. C. Greubel, Feb 17 2021
STATUS
approved