login
A144432
Triangle, T(n, k), read by rows: T(n, k) = t(n, k)^2 - t(n, k) - 1, where t(n,k) = (m*(n-k) + 1)*t(n-1, k-1) + (m*k - (m-1))*t(n-1, k) and m = -1.
12
-1, -1, -1, -1, -1, -1, -1, 1, 1, -1, -1, 5, 1, 5, -1, -1, 11, 1, 1, 11, -1, -1, 19, 41, 71, 41, 19, -1, -1, 29, 71, 29, 29, 71, 29, -1, -1, 41, 239, 701, 869, 701, 239, 41, -1, -1, 55, 379, 811, 181, 181, 811, 379, 55, -1
OFFSET
1,12
FORMULA
T(n, k) = t(n, k)^2 - t(n, k) - 1, where t(n,k) = (m*(n-k) + 1)*t(n-1, k-1) + (m*k - (m-1))*t(n-1, k) and m = -1.
From G. C. Greubel, Mar 02 2022: (Start)
T(n, n-k) = T(n, k).
T(n, k) = t(n,k)^2 - t(n,k) - 1, where t(n,k) = (-1)^(k-1)*binomial(n-3, k-1) + (-1)^(n+k)*binomial(n-3, k-3) with t(1, k) = t(2, k) = 1.
Sum_{k=1..n} T(n,k) = -n*[n<4] + ( 2*binomial(2*n-6, n-3)*(binomial(n-1,2) - (-1)^n*binomial(n-3,2))/binomial(n-1,2) - n )*[n>=4]. (End)
EXAMPLE
Triangle begins as:
-1;
-1, -1;
-1, -1, -1;
-1, 1, 1, -1;
-1, 5, 1, 5, -1;
-1, 11, 1, 1, 11, -1;
-1, 19, 41, 71, 41, 19, -1;
-1, 29, 71, 29, 29, 71, 29, -1;
-1, 41, 239, 701, 869, 701, 239, 41, -1;
-1, 55, 379, 811, 181, 181, 811, 379, 55, -1;
MATHEMATICA
t[n_, k_, m_]:= t[n, k, m]= If[k==1 || k==n, 1, (m*(n-k)+1)*t[n-1, k-1, m] + (m*(k - 1)+1)*t[n-1, k, m]];
T[n_, k_, m_]:= t[n, k, m]^2 -t[n, k, m] -1;
Table[T[n, k, -1], {n, 15}, {k, n}]//Flatten (* modified by G. C. Greubel, Mar 02 2022 *)
PROG
(Sage)
def t(n, k):
if (n<3): return 1
else: return (-1)^(k-1)*binomial(n-3, k-1) + (-1)^(n+k)*binomial(n-3, k-3)
def A144432(n, k): return t(n, k)^2 - t(n, k) - 1
flatten([[A144432(n, k) for k in (1..n)] for n in (1..15)]) # G. C. Greubel, Mar 02 2022
CROSSREFS
Sequence in context: A019840 A375340 A205109 * A010686 A021070 A176260
KEYWORD
sign,tabl
AUTHOR
Roger L. Bagula, Oct 04 2008
EXTENSIONS
Edited by G. C. Greubel, Mar 02 2022
STATUS
approved