login
A135859
Row sums of triangle A135858.
5
1, 4, 13, 34, 73, 136, 229, 358, 529, 748, 1021, 1354, 1753, 2224, 2773, 3406, 4129, 4948, 5869, 6898, 8041, 9304, 10693, 12214, 13873, 15676, 17629, 19738, 22009, 24448, 27061, 29854, 32833, 36004, 39373, 42946, 46729, 50728, 54949
OFFSET
1,2
COMMENTS
Number of binary 3 X (n-1) matrices such that each row and column has at most one 1. - Dmitry Kamenetsky, Jan 20 2018
LINKS
FORMULA
Row sums of triangle A135858. Binomial transform of [1, 3, 6, 6, 0, 0, 0, ...].
G.f.: x*(1+3*x^2+2*x^3) / (1-x)^4. - R. J. Mathar, Apr 04 2012
a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - a(n-4). - Vincenzo Librandi, Jun 29 2012
a(n) = n^3 - 3*n^2 + 5*n - 2. - R. J. Mathar, Oct 20 2017
E.g.f.: 2 - (2 - 3*x - x^3)*exp(x). - G. C. Greubel, Aug 11 2022
EXAMPLE
a(3) = 13 = sum of row 3 terms of triangle A135858: (7, + 5 + 1).
a(4) = 34 = (1, 3, 3, 1) dot (1, 3, 6, 6) = (1 + 9 + 18 + 6).
MAPLE
seq(5*n - 2 + n^3 - 3*n^2, n=1..10^2); # Muniru A Asiru, Jan 24 2018
MATHEMATICA
CoefficientList[Series[(1+3*x^2+2*x^3)/(x-1)^4, {x, 0, 40}], x] (* Vincenzo Librandi, Jun 29 2012 *)
PROG
(Magma) I:=[1, 4, 13, 34]; [n le 4 select I[n] else 4*Self(n-1)-6*Self(n-2)+4*Self(n-3)-Self(n-4): n in [1..50]]; // Vincenzo Librandi, Jun 29 2012
(GAP) List([1..10^4], n-> 5*n - 2 + n^3 - 3*n^2); # Muniru A Asiru, Jan 24 2018
(SageMath) [n^3 -3*n^2 +5*n -2 for n in (1..50)] # G. C. Greubel, Aug 11 2022
CROSSREFS
Cf. A135858.
Sequence in context: A227122 A176361 A322599 * A161531 A101946 A029860
KEYWORD
nonn,easy
AUTHOR
Gary W. Adamson, Dec 01 2007
STATUS
approved