login
a(n) = ((2 + sqrt(2))^n - (2 - sqrt(2))^n)^2/8.
1

%I #27 Sep 08 2022 08:45:38

%S 0,1,16,196,2304,26896,313600,3655744,42614784,496754944,5790601216,

%T 67500196864,786839961600,9172078759936,106917585289216,

%U 1246322708463616,14528202160472064,169353135091941376,1974124812461670400,23012085209172803584

%N a(n) = ((2 + sqrt(2))^n - (2 - sqrt(2))^n)^2/8.

%H Vincenzo Librandi, <a href="/A144844/b144844.txt">Table of n, a(n) for n = 0..950</a>

%H <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (14,-28,8).

%F From _R. J. Mathar_, Sep 24 2008: (Start)

%F G.f.: x*(1+2*x)/((1-2*x)*(1-12*x+4*x^2)).

%F a(n) = 2^(n-2)*(A001109(n+1) - 3*A001109(n) - 1) = 2^(n-1)*A001108(n). (End)

%F a(n) = 14*a(n-1) - 28*a(n-2) + 8*a(n-3) for n > 2; a(0) = 0, a(1) = 1; a(2) = 16. - _Klaus Brockhaus_, Jul 15 2009

%F a(n) = A007070(n)^2 = (((sqrt(2)+1)^n - (sqrt(2)-1)^n)) / 2) ^ 2. - _Franklin T. Adams-Watters_, Aug 06 2009

%F a(n) = 2^(n-3)*(Q(2*n) - 2), where Q(m) are the Pell-Lucas numbers (A002203). - _G. C. Greubel_, Sep 27 2018

%t Table[ Simplify[ ((2 + Sqrt@2)^n - (2 - Sqrt@2)^n)^2/8], {n, 0, 19}] (* _Robert G. Wilson v_, Sep 24 2008 *)

%t CoefficientList[Series[x (1 + 2 x) / ((1 - 2 x) (1 - 12 x + 4 x^2)), {x, 0, 33}], x] (* _Vincenzo Librandi_, Feb 06 2018 *)

%t LinearRecurrence[{14,-28,8},{0,1,16},20] (* _Harvey P. Dale_, Apr 12 2020 *)

%o (Magma) Z<x>:=PolynomialRing(Integers()); N<r2>:=NumberField(x^2-2); [ Integers()!a: a in [ ((2+r2)^n-(2-r2)^n)^2/8: n in [0..19] ] ]; // _Klaus Brockhaus_, Oct 20 2008

%o (Magma) I:=[0,1,16]; [n le 3 select I[n] else 14*Self(n-1)-28*Self(n-2)+8*Self(n-3): n in [1..20]]; // _Vincenzo Librandi_, Feb 05 2018

%o (PARI) x='x+O('x^30); concat([0], Vec(x*(1+2*x)/((1-2*x)*(1-12*x+4*x^2)) )) \\ _G. C. Greubel_, Sep 27 2018

%K nonn,easy

%O 0,3

%A Al Hakanson (hawkuu(AT)gmail.com), Sep 22 2008