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 A142474 #36 Jun 01 2024 11:12:14 %S A142474 1,0,1,2,4,9,19,41,88,189,406,872,1873,4023,8641,18560,39865,85626, %T A142474 183916,395033,848491,1822473,3914488,8407925,18059374,38789712, %U A142474 83316385,178955183,384377665,825604416,1773314929,3808901426,8181135700,17572253481,37743426307 %N A142474 1 followed by A141015. %C A142474 Essentially the same as A078039, A141015, and A141683. %H A142474 Colin Barker, <a href="/A142474/b142474.txt">Table of n, a(n) for n = 1..1000</a> %H A142474 <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (1,2,1). %F A142474 From _Colin Barker_, Jun 29 2017: (Start) %F A142474 G.f.: x*(1 - x - x^2) / (1 - x - 2*x^2 - x^3). %F A142474 a(n) = a(n-1) + 2*a(n-2) + a(n-3) for n>3. %F A142474 (End) %p A142474 m:=50; S:=series( x*(1-x-x^2)/(1-x-2*x^2-x^3), x, m+1): %p A142474 seq(coeff(S, x, j), j=1..m); # _G. C. Greubel_, Apr 14 2021 %t A142474 m:= 80; Table[SeriesCoefficient[Series[(1+t)/(1+t+t^3), {t,0,m}], n], {n,0,m,2}] %o A142474 (PARI) Vec(x*(1-x-x^2)/(1-x-2*x^2-x^3) + O(x^50)) \\ _Colin Barker_, Jun 29 2017 %o A142474 (Magma) [n le 3 select (1-(-1)^n)/2 else Self(n-1) +2*Self(n-2) +Self(n-3): n in [1..50]]; // _G. C. Greubel_, Apr 14 2021 %o A142474 (Sage) %o A142474 def A142474_list(prec): %o A142474 P.<x> = PowerSeriesRing(ZZ, prec) %o A142474 return P( x*(1-x-x^2)/(1-x-2*x^2-x^3) ).list() %o A142474 a=A142474_list(51); a[1:] # _G. C. Greubel_, Apr 14 2021 %Y A142474 Cf. A078039, A141015, A141683. %K A142474 nonn,less,easy %O A142474 1,4 %A A142474 _Roger L. Bagula_, Sep 21 2008 %E A142474 More terms from _G. C. Greubel_, Jun 26 2017