%I #25 Jun 14 2026 09:17:01
%S 1,1,3,1,1,7,13,7,1,1,12,45,69,45,12,1,1,18,108,296,411,296,108,18,1,
%T 1,25,215,890,2015,2633,2015,890,215,25,1,1,33,381,2180,7110,14148,
%U 17739,14148,7110,2180,381,33,1,1,42,623,4662,20391,56238,101941,124029,101941,56238,20391,4662,623,42,1
%N Triangle T(n,k), where row n lists the coefficients of the n-th palindromic polynomial p(n) defined by a recurrence of order 2.
%C This should be the h^* vectors of some reflexive polytopes.
%H Alois P. Heinz, <a href="/A394446/b394446.txt">Rows n = 1..100, flattened</a>
%F T(n,k) = [x^k] p(n) with p(0) = 1; p(1) = 1+3*x+x^2; (n+2)*p(n) = p(1)*(2*n+1)*p(n-1)-(1+x+x^2)^2*(n-1)*p(n-2).
%e The first few polynomials are:
%e 1,
%e x^2 + 3*x + 1,
%e x^4 + 7*x^3 + 13*x^2 + 7*x + 1,
%e x^6 + 12*x^5 + 45*x^4 + 69*x^3 + 45*x^2 + 12*x + 1.
%e Triangle T(n,k) begins:
%e 1;
%e 1, 3, 1;
%e 1, 7, 13, 7, 1;
%e 1, 12, 45, 69, 45, 12, 1;
%e 1, 18, 108, 296, 411, 296, 108, 18, 1;
%e 1, 25, 215, 890, 2015, 2633, 2015, 890, 215, 25, 1;
%e ...
%p b:= proc(n) option remember; `if`(n=0, 1, `if`(n=1, 1+3*x+x^2,
%p expand((b(1)*(2*n+1)*b(n-1)-(1+x+x^2)^2*(n-1)*b(n-2))/(n+2))))
%p end:
%p T:= n-> coeffs(b(n)):
%p seq(T(n), n=0..7); # _Alois P. Heinz_, Mar 20 2026
%t b[n_] := b[n] = If[n == 0, 1, If[n == 1, 1+3*x + x^2, Expand[(b[1]*(2*n+1)*b[n-1] - (1+x+x^2)^2*(n-1)*b[n- 2])/(n+2)]]];
%t T[n_] := CoefficientList[b[n], x];
%t Table[T[n], {n, 0, 7}] // Flatten (* _Jean-François Alcover_, Jun 14 2026, after _Alois P. Heinz_ *)
%o (SageMath)
%o @cached_function
%o def a(n):
%o R = PolynomialRing(ZZ, 'x')
%o if n == 0:
%o return R.one()
%o p5 = R([1, 3, 1])
%o if n == 1:
%o return p5
%o p9 = R([1, 1, 1])**2
%o return (p5*(2*n+1)*a(n-1)-p9*(n-1)*a(n-2)) / (n + 2)
%Y Row sums give A059231(n+1).
%Y Main diagonal gives A128079.
%Y Columns k=0-1 give: A000012, A055998.
%K nonn,tabf
%O 0,3
%A _F. Chapoton_, Mar 20 2026