cp's OEIS Frontend

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.

A122112 a(n) = 4*a(n-2) - a(n-1), with a(0)=1, a(1)=-2.

This page as a plain text file.
%I A122112 #33 Jan 03 2024 08:43:32
%S A122112 1,-2,6,-14,38,-94,246,-622,1606,-4094,10518,-26894,68966,-176542,
%T A122112 452406,-1158574,2968198,-7602494,19475286,-49885262,127786406,
%U A122112 -327327454,838473078,-2147782894,5501675206,-14092806782,36099507606,-92470734734
%N A122112 a(n) = 4*a(n-2) - a(n-1), with a(0)=1, a(1)=-2.
%H A122112 G. C. Greubel, <a href="/A122112/b122112.txt">Table of n, a(n) for n = 0..1000</a>
%H A122112 <a href="/index/Rec#order_02">Index entries for linear recurrences with constant coefficients</a>, signature (-1,4).
%F A122112 a(n) = (-1)^n * A026597(n).
%F A122112 a(n) = Sum_{k=0..n} (-2)^(n-k) * A055830(n,k).
%F A122112 G.f.: (1-x)/(1+x-4*x^2).
%F A122112 a(n) = (-2*i)^n*( ChebyshevU(n, -i/4) - (i/2)*ChebyshevU(n-1, -i/4) ). - _G. C. Greubel_, Dec 23 2021
%F A122112 E.g.f.: exp(-x/2)*(17*cosh(sqrt(17)*x/2) - 3*sqrt(17)*sinh(sqrt(17)*x/2))/17. - _Stefano Spezia_, Apr 03 2023
%p A122112 seq(coeff(series((1-x)/(1+x-4*x^2), x, n+1), x, n), n = 0..30); # _G. C. Greubel_, Oct 02 2019
%t A122112 LinearRecurrence[{-1,4}, {1,-2}, 30] (* _G. C. Greubel_, Oct 02 2019 *)
%o A122112 (PARI) my(x='x+O('x^30)); Vec((1-x)/(1+x-4*x^2)) \\ _G. C. Greubel_, Oct 02 2019
%o A122112 (Magma) R<x>:=PowerSeriesRing(Integers(), 30); Coefficients(R!( (1-x)/(1+x-4*x^2) )); // _G. C. Greubel_, Oct 02 2019
%o A122112 (Sage)
%o A122112 def A122112_list(prec):
%o A122112     P.<x> = PowerSeriesRing(ZZ, prec)
%o A122112     return P((1-x)/(1+x-4*x^2)).list()
%o A122112 A122112_list(30) # _G. C. Greubel_, Oct 02 2019
%o A122112 (GAP) a:=[1,-2];; for n in [3..30] do a[n]:=-a[n-1]+4*a[n-2]; od; a; # _G. C. Greubel_, Oct 02 2019
%Y A122112 Cf. A026597, A055830.
%K A122112 sign,easy
%O A122112 0,2
%A A122112 _Philippe Deléham_, Oct 18 2006
%E A122112 Corrected by _T. D. Noe_, Nov 07 2006