This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A084707 #38 Dec 16 2023 17:45:19 %S A084707 1,3,9,27,73,195,513,1347,3529,9243,24201,63363,165889,434307,1137033, %T A084707 2976795,7793353,20403267,53416449,139846083,366121801,958519323, %U A084707 2509436169,6569789187,17199931393,45030004995,117890083593,308640245787,808030653769 %N A084707 a(n) = 3*a(n-1) - 3*a(n-3) + a(n-4) for n > 3, with a(0) = 1, a(1) = 3, a(2) = 9, a(3) = 27. %C A084707 Define f(x, y) := 9 - x - 3*y + x^2 - 3*x*y + y^2. Then f(x, y) = f(-4-y, -4-x). All of the integer solutions of 0 = f(x, y) with x>=0 are given by x = a(2*n) and y = a(2*n+1) for all n in Z. - _Michael Somos_, Aug 19 2023 %H A084707 Vincenzo Librandi, <a href="/A084707/b084707.txt">Table of n, a(n) for n = 0..1000</a> %H A084707 J. Hietarinta and C.-M. Viallet, <a href="http://www.lpthe.jussieu.fr/~viallet/">Singularity confinement and chaos in discrete systems</a>, Physical Review Letters 81 (1998), pp. 326-328. %H A084707 <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (3,0,-3,1). %F A084707 G.f.: (1+3*x^3)/(1-3*x+3*x^3-x^4). - _Harvey P. Dale_, Mar 14 2011 %F A084707 a(n) = (8*LucasL(2*n) - (-1)^n - 10)/5. - _G. C. Greubel_, Apr 15 2023 %F A084707 a(n) = a(-n) = 4 + 2*a(n-1) + 2*a(n-2) - a(n-3) for all n in Z. - _Michael Somos_, Aug 19 2023 %e A084707 G.f. = 1 + 3*x + 9*x^2 + 27*x^3 + 73*x^4 + 195*x^5 + 513*x^6 + ... - _Michael Somos_, Aug 19 2023 %p A084707 a:=proc(n) option remember; if n=0 then 1 elif n=1 then 3 elif n=2 then 9 elif n=3 then 27 else 3*a(n-1)-3*a(n-3)+a(n-4); fi; end: seq(a(n), n=0..40); # _Wesley Ivan Hurt_, Aug 15 2016 %t A084707 a[n_]:=a[n]=3a[n-1] -3a[n-3] +a[n-4]; a[0]=1; a[1]=3; a[2]=9; a[3]=27; %t A084707 Table[ a[n], {n, 0, 27}] %t A084707 Transpose[NestList[Join[Rest[#],ListCorrelate[{1,-3,0,3},#]]&, {1,3,9,27},30]][[1]] %t A084707 CoefficientList[Series[(1+3 x^3)/(1-3 x+3 x^3-x^4),{x,0,30}],x] (* _Harvey P. Dale_, Mar 14 2011 *) %t A084707 a[ n_] := Floor[(LucasL[2*n] - 1)*8/5]; (* _Michael Somos_, Aug 19 2023 *) %o A084707 (Magma) A084707:=[1,3,9,27]; [n le 4 select A084707[n] else 3*Self(n-1)-3*Self(n-3)+Self(n-4): n in [1..30]]; // _Wesley Ivan Hurt_, Aug 15 2016 %o A084707 (Magma) [(8*Lucas(2*n) -(-1)^n)/5 -2: n in [0..40]]; // _G. C. Greubel_, Apr 15 2023 %o A084707 (SageMath) [(8*lucas_number2(2*n,1,-1) -(-1)^n)/5 -2 for n in range(41)] # _G. C. Greubel_, Apr 15 2023 %o A084707 (PARI) {a(n) = my(w=quadgen(5)); (real((1+w)^n*(2+w))-1)*8\5}; /* _Michael Somos_, Aug 19 2023 */ %Y A084707 Cf. A005248, A069403. %K A084707 nonn,easy %O A084707 0,2 %A A084707 _N. J. A. Sloane_, Jul 06 2003 %E A084707 More terms from _Ray Chandler_, Jul 07 2003