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.

A192878 Constant term in the reduction by (x^2 -> x + 1) of the polynomial p(n,x) given in Comments.

This page as a plain text file.
%I A192878 #32 Sep 08 2022 08:45:58
%S A192878 3,0,4,5,18,42,115,296,780,2037,5338,13970,36579,95760,250708,656357,
%T A192878 1718370,4498746,11777875,30834872,80726748,211345365,553309354,
%U A192878 1448582690,3792438723,9928733472,25993761700,68052551621,178163893170,466439127882,1221153490483
%N A192878 Constant term in the reduction by (x^2 -> x + 1) of the polynomial p(n,x) given in Comments.
%C A192878 The polynomial p(n,x) is defined by p(0,x) = 1, p(1,x) = x + 1, and p(n,x) = x*p(n-1,x) + 2*(x^2)*p(n-1,x) + 1.  See A192872.
%C A192878 For n>0, also the coefficient of x in the reduction x^2 -> x + 1 of the polynomial A000285(n-1)*x^(n-1). - _R. J. Mathar_, Jul 12 2011
%H A192878 Colin Barker, <a href="/A192878/b192878.txt">Table of n, a(n) for n = 0..1000</a>
%H A192878 <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (2,2,-1).
%F A192878 a(n) = 2*a(n-1) + 2*a(n-2) - a(n-3).
%F A192878 G.f.: ( 3 - 2*x^2 - 6*x ) / ( (1+x)*(1 - 3*x + x^2) ). - _R. J. Mathar_, May 07 2014
%F A192878 a(n) = (2^(-n)*(7*(-2)^n - (-4+sqrt(5))*(3+sqrt(5))^n + (3-sqrt(5))^n*(4+sqrt(5))))/5. - _Colin Barker_, Sep 29 2016
%e A192878 The first six polynomials and reductions:
%e A192878 p(0,x) = 3 -> 3
%e A192878 p(1,x) = x -> x
%e A192878 p(2,x) = 4*x^2 -> 4 + 4*x
%e A192878 p(3,x) = 5*x^3 -> 5 + 10*x
%e A192878 p(4,x) = 9*x^4 -> 18 + 27*x
%e A192878 p(5,x) = 14*x^5 -> 42 + 27*x
%e A192878 In general, p(n,x) = A104449(n)*x^n -> A192878(n) + A192879(n)*x.
%t A192878 q = x^2; s = x + 1; z = 25;
%t A192878 p[0, x_] := 3; p[1, x_] := x;
%t A192878 p[n_, x_] := p[n - 1, x]*x + p[n - 2, x]*x^2;
%t A192878 Table[Expand[p[n, x]], {n, 0, 7}]
%t A192878 reduce[{p1_, q_, s_, x_}] :=
%t A192878 FixedPoint[(s PolynomialQuotient @@ #1 +
%t A192878        PolynomialRemainder @@ #1 &)[{#1, q, x}] &, p1]
%t A192878 t = Table[reduce[{p[n, x], q, s, x}], {n, 0, z}];
%t A192878 u1 = Table[Coefficient[Part[t, n], x, 0], {n, 1, z}]  (* A192878 *)
%t A192878 u2 = Table[Coefficient[Part[t, n], x, 1], {n, 1, z}]  (* A192879 *)
%t A192878 FindLinearRecurrence[u1]
%t A192878 FindLinearRecurrence[u2]
%t A192878 LinearRecurrence[{2,2,-1}, {3,0,4}, 30] (* _G. C. Greubel_, Jan 08 2019 *)
%o A192878 (PARI) a(n) = round((2^(-n)*(7*(-2)^n-(-4+sqrt(5))*(3+sqrt(5))^n+(3-sqrt(5))^n*(4+sqrt(5))))/5) \\ _Colin Barker_, Sep 29 2016
%o A192878 (PARI) Vec((3-2*x^2-6*x)/((1+x)*(x^2-3*x+1)) + O(x^40)) \\ _Colin Barker_, Sep 29 2016
%o A192878 (Magma) m:=30; R<x>:=PowerSeriesRing(Integers(), m); Coefficients(R!( (3-2*x^2-6*x)/((1+x)*(x^2-3*x+1)) )); // _G. C. Greubel_, Jan 08 2019
%o A192878 (Sage) ((3-2*x^2-6*x)/((1+x)*(x^2-3*x+1))).series(x, 30).coefficients(x, sparse=False) # _G. C. Greubel_, Jan 08 2019
%o A192878 (GAP) a:=[3,0,4];; for n in [4..30] do a[n]:=2*a[n-1]+2*a[n-2]-a[n-3]; od; a; # _G. C. Greubel_, Jan 08 2019
%Y A192878 Cf. A000285, A192872, A192879.
%K A192878 nonn,easy
%O A192878 0,1
%A A192878 _Clark Kimberling_, Jul 11 2011