OFFSET
1,3
COMMENTS
A palindromic composition of a natural number m is an ordered partition of m into N+1 natural numbers (or parts), p_0, p_1, ..., p_N, of the form m = p_0 + p_1 + ... + p_N such that p_j = p_{N-j}, for each j in {0,...,N}. Two palindromic compositions, sum_{j=0..N} p_j and sum_{j=0..N} q_j (say), are identical if and only if p_j = q_j, j = 0,...,N; otherwise they are taken to be distinct.
Partial sums of rows of A233323.
T(n,k) is defined for n,k >= 0. T(n,k) = T(n,n) = A016116(n) for k>= 0. - Alois P. Heinz, Dec 11 2013
LINKS
Alois P. Heinz, Rows n = 1..141, flattened
V. E. Hoggatt, Jr., and Marjorie Bicknell, Palindromic compositions, Fibonacci Quart., Vol. 13(4), 1975, pp. 350-356.
EXAMPLE
Triangle T(n,k) begins:
1;
1, 2;
1, 1, 2;
1, 3, 3, 4;
1, 2, 3, 3, 4;
1, 5, 6, 7, 7, 8;
1, 3, 6, 6, 7, 7, 8;
1, 8, 11, 14, 14, 15, 15, 16;
1, 5, 11, 12, 14, 14, 15, 15, 16;
1, 13, 20, 27, 28, 30, 30, 31, 31, 32;
MAPLE
T:= proc(n, k) option remember; `if`(n<=k, 1, 0)+
add(T(n-2*j, k), j=1..min(k, iquo(n, 2)))
end:
seq(seq(T(n, k), k=1..n), n=1..14); # Alois P. Heinz, Dec 11 2013
MATHEMATICA
T[n_, k_] := T[n, k] = If[n <= k, 1, 0] + Sum[T[n-2*j, k], {j, 1, Min[k, Quotient[ n, 2]]}]; Table[Table[T[n, k], {k, 1, n}], {n, 1, 14}] // Flatten (* Jean-François Alcover, Mar 09 2015, after Alois P. Heinz *)
PROG
(PARI) T(n, k)=if(n<1, return(n==0)); sum(i=1, k, T(n-2*i, k))+(n<=k) \\ Charles R Greathouse IV, Dec 11 2013
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
L. Edson Jeffery, Dec 11 2013
STATUS
approved