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 A078040 #17 Mar 19 2025 09:38:59 %S A078040 1,-2,4,-10,22,-50,114,-258,586,-1330,3018,-6850,15546,-35282,80074, %T A078040 -181730,412442,-936050,2124394,-4821378,10942266,-24833810,56361098, %U A078040 -127913250,290303066,-658851762,1495284394,-3393594050,7701866362,-17479623250,39670544074,-90033523298 %N A078040 Expansion of (1-x)/(1+x-2*x^2+2*x^3). %H A078040 <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (-1,2,-2). %F A078040 a(0) = 1, a(1) = -2, a(2) = 4, a(n) = -a(n-1) + 2*a(n-2) - 2*a(n-3) for n > 2. - _Harvey P. Dale_, Dec 09 2011 %F A078040 a(n) = A077970(n)-A077970(n-1). - _R. J. Mathar_, Mar 19 2025 %t A078040 CoefficientList[Series[(1-x)/(1+x-2x^2+2x^3),{x,0,40}],x] (* or *) LinearRecurrence[{-1,2,-2},{1,-2,4},40] (* _Harvey P. Dale_, Dec 09 2011 *) %o A078040 (PARI) Vec((1-x)/(1+x-2*x^2+2*x^3)+O(x^99)) \\ _Charles R Greathouse IV_, Sep 27 2012 %Y A078040 First differences of A077970. %K A078040 sign,easy %O A078040 0,2 %A A078040 _N. J. A. Sloane_, Nov 17 2002