%I #23 Mar 11 2024 04:38:47
%S 1,-1,2,0,5,7,22,48,121,287,698,1680,4061,9799,23662,57120,137905,
%T 332927,803762,1940448,4684661,11309767,27304198,65918160,159140521,
%U 384199199,927538922,2239277040,5406093005
%N a(n+3) = a(n+2) + 3*a(n+1) + a(n).
%C a(n) + a(n+1) = A000129(n); a(n+2) - a(n) = A001333(n)
%C Floretion Algebra Multiplication Program, FAMP Code: 2jbasekrokseq[A*H] with A = + .25'i + .25i' + .25'ii' + .25'jj' + .25'kk' + .25'jk' + .25'kj' + .25e; H = - 2'i - 'j + 'k; roktype : Y[15] = Y[15] + (-1)^p (internal program code)
%H Harvey P. Dale, <a href="/A111352/b111352.txt">Table of n, a(n) for n = 0..1000</a>
%H Robert Munafo, <a href="http://www.mrob.com/pub/seq/floretion.html">Sequences Related to "Floretions"</a>.
%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (1,3,1).
%F a(n) = (1/4*sqrt(2)-1/4)*(1+sqrt(2))^n + (-1/4*sqrt(2)-1/4)*(1-sqrt(2))^n + 3/2*(-1)^n.
%F G.f.: (2*x-1)/((x+1)*(x^2+2*x-1)).
%F a(n) = 3*(-1)^n/2+A001333(n-1)/2, n>0. [_R. J. Mathar_, Nov 10 2009]
%t LinearRecurrence[{1,3,1},{1,-1,2},30] (* _Harvey P. Dale_, Jul 26 2020 *)
%Y Cf. A000129, A001333.
%K easy,sign
%O 0,3
%A _Creighton Dement_, Oct 29 2005