OFFSET
0,2
COMMENTS
a(n) is the number of triangles of all sizes in a polyiamond of trapezoid shape with 3 sides of length n and the base of length 2*n. The number of triangular cells in the trapezoid is 3*n^2. This is half of a regular hexagon with side lengths n.
The number of triangles oriented with their bases aligned with the base of the trapezoid is n*(n+1)*(2*n+1)/3 and the number oriented in the opposite direction is n^2*(n+1)/2. a(n) is the sum of these two.
LINKS
Colin Barker, Table of n, a(n) for n = 0..1000
Luce ETIENNE, Illustration a(1), a(2), a(3), a(4) and a(5)
Index entries for linear recurrences with constant coefficients, signature (4,-6,4,-1).
FORMULA
G.f.: x*(3 + 4*x) / (1 - x)^4. - Colin Barker, Feb 17 2015
a(n) = Sum_{j=0..n-1} (n-j)*(3*n-2*j) = Sum_{j=1..n} j*(n+2*j) for n>0.
Sum_{n>=1} 1/a(n) = 21*HarmonicNumber(2/7)/5 - 6/5 = 0.44513027538601361333... . - Vaclav Kotesovec, Sep 22 2016
EXAMPLE
From the second comment: a(1)= 2+1, a(2)= 10+6, a(3)= 28+18, a(4)= 60+40.
MATHEMATICA
Table[n (n + 1) (7 n + 2)/6, {n, 0, 50}] (* Bruno Berselli, Feb 17 2015 *)
PROG
(PARI) concat(0, Vec(x*(4*x+3)/(x-1)^4 + O(x^100))) \\ Colin Barker, Feb 17 2015
(PARI) vector(50, n, n--; n*(n+1)*(7*n+2)/6) \\ Bruno Berselli, Feb 17 2015
(Magma) [n*(n+1)*(7*n+2)/6 : n in [0..50]]; // Wesley Ivan Hurt, Apr 11 2021
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Luce ETIENNE, Feb 17 2015
EXTENSIONS
Edited and extended by Bruno Berselli, Dec 01 2016
STATUS
approved