login
a(n) = [ (2nd elementary symmetric function of S(n))/(first elementary symmetric function of S(n)) ], where S(n) = {first n+1 positive integers congruent to 2 mod 3}.
1

%I #19 Sep 08 2022 08:44:48

%S 0,1,4,8,14,22,31,41,53,67,82,98,116,136,157,179,203,229,256,284,314,

%T 346,379,413,449,487,526,566,608,652,697,743,791,841,892,944,998,1054,

%U 1111,1169,1229,1291,1354,1418,1484,1552,1621,1691,1763,1837,1912,1988

%N a(n) = [ (2nd elementary symmetric function of S(n))/(first elementary symmetric function of S(n)) ], where S(n) = {first n+1 positive integers congruent to 2 mod 3}.

%H Vincenzo Librandi, <a href="/A024398/b024398.txt">Table of n, a(n) for n = 1..10000</a>

%H <a href="/index/Rec#order_05">Index entries for linear recurrences with constant coefficients</a>, signature (3,-4,4,-3,1).

%F a(n) = (1/4)*(3*(n^2-n-1) - (-1)^floor(n/2)), n > 1. - _Ralf Stephan_, Jun 09 2005

%F G.f.: x^2*(-1-x-2*x^3+x^4) / ( (x^2+1)*(x-1)^3 ). - _R. J. Mathar_, Oct 08 2011

%t Join[{0}, LinearRecurrence[{3, -4, 4, -3, 1}, {1, 4, 8, 14, 22}, 60]] (* or *) Join[{0}, Table[(3 (n^2 - n - 1) - (-1)^(Floor[n/2]))/4, {n, 2, 55}]] (* _Vincenzo Librandi_, Aug 12 2018 *)

%o (Magma) [0] cat [(3*(n^2-n-1)-(-1)^(n div 2)) div 4: n in [2..60]]; // _Vincenzo Librandi_, Aug 12 2018

%K nonn

%O 1,3

%A _Clark Kimberling_