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 A171089 #23 Dec 26 2023 12:17:35 %S A171089 6,4,16,34,96,244,646,1684,4416,11554,30256,79204,207366,542884, %T A171089 1421296,3720994,9741696,25504084,66770566,174807604,457652256, %U A171089 1198149154,3136795216,8212236484,21499914246,56287506244,147362604496,385800307234,1010038317216 %N A171089 a(n) = 2*(Lucas(n)^2 - (-1)^n). %C A171089 In Thomas Koshy's book on Fibonacci and Lucas numbers, the formula for even-indexed Lucas numbers in terms of squares of Lucas numbers (A001254) is erroneously given as L(2n) = 2L(n)^2 + 2(-1)^(n - 1) on page 404 as Identity 34.7. - _Alonso del Arte_, Sep 07 2010 %D A171089 Thomas Koshy, "Fibonacci and Lucas Numbers with Applications", John Wiley and Sons, 2001. %H A171089 Vincenzo Librandi, <a href="/A171089/b171089.txt">Table of n, a(n) for n = 0..1000</a> %H A171089 <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (2,2,-1). %F A171089 a(n) = 2*(A000032(n))^2 -2*(-1)^n. %F A171089 a(n) = 2*A047946(n). %F A171089 a(n) = 2*a(n-1) + 2*a(n-2) -a(n-3). %F A171089 G.f.: 2*(3-4*x-2*x^2)/( (1+x)*(x^2-3*x+1) ). %F A171089 a(n) = 2^(1-n)*((-2)^n+(3-sqrt(5))^n+(3+sqrt(5))^n). - _Colin Barker_, Oct 01 2016 %t A171089 f[n_] := 2 (LucasL@n^2 - (-1)^n); Array[f, 27, 0] (* _Robert G. Wilson v_, Sep 10 2010 *) %t A171089 CoefficientList[Series[2*(3 - 4*x - 2*x^2)/((1 + x)*(x^2 - 3*x + 1)), {x, 0, 40}], x] (* _Vincenzo Librandi_, Dec 19 2012 *) %o A171089 (Magma) I:=[6, 4, 16]; [n le 3 select I[n] else 2*Self(n-1) + 2*Self(n-2) - Self(n-3): n in [1..30]]; // _Vincenzo Librandi_, Dec 19 2012 %o A171089 (PARI) a(n) = round(2^(1-n)*((-2)^n+(3-sqrt(5))^n+(3+sqrt(5))^n)) \\ _Colin Barker_, Oct 01 2016 %o A171089 (PARI) Vec(2*(3-4*x-2*x^2)/((1+x)*(x^2-3*x+1)) + O(x^40)) \\ _Colin Barker_, Oct 01 2016 %Y A171089 Cf. A001254. %K A171089 nonn,easy %O A171089 0,1 %A A171089 _R. J. Mathar_, Sep 08 2010 %E A171089 a(21) onwards from _Robert G. Wilson v_, Sep 10 2010