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.

A158137 Period 9: repeat [-2,4,-2,4,-2,-2,1,1,-2].

This page as a plain text file.
%I A158137 #15 Dec 12 2023 08:05:09
%S A158137 -2,4,-2,4,-2,-2,1,1,-2,-2,4,-2,4,-2,-2,1,1,-2,-2,4,-2,4,-2,-2,1,1,-2,
%T A158137 -2,4,-2,4,-2,-2,1,1,-2,-2,4,-2,4,-2,-2,1,1,-2,-2,4,-2,4,-2,-2,1,1,-2,
%U A158137 -2,4,-2,4,-2,-2,1,1,-2,-2,4,-2,4,-2,-2,1,1,-2,-2,4,-2,4,-2,-2,1,1,-2,-2,4,-2
%N A158137 Period 9: repeat [-2,4,-2,4,-2,-2,1,1,-2].
%C A158137 Rotated by 7 places, the period is palindromic: 1,-2,-2,4,-2,4,-2,-2,1.
%H A158137 <a href="/index/Rec#order_08">Index entries for linear recurrences with constant coefficients</a>, signature (-1,-1,-1,-1,-1,-1,-1,-1).
%F A158137 a(n)= A158090(n)-2 = A158090(n)-A007395(n+1).
%F A158137 G.f.: (-2+2*x+4*x^3+x^6+2*x^4+2*x^7)/((1+x+x^2)*(x^6+x^3+1)). a(n)= -a(n-1)-a(n-2)-a(n-3)-a(n-4)-a(n-5)-a(n-6)-a(n-7)-a(n-8). - _R. J. Mathar_, Apr 09 2009
%t A158137 PadRight[{},120,{-2,4,-2,4,-2,-2,1,1,-2}] (* _Harvey P. Dale_, Dec 11 2018 *)
%o A158137 (PARI) a(n)=[-2,4,-2,4,-2,-2,1,1,-2][n%9+1] \\ _Charles R Greathouse IV_, Jul 13 2016
%Y A158137 Cf. A156346.
%K A158137 sign,easy,less
%O A158137 0,1
%A A158137 _Paul Curtz_, Mar 13 2009
%E A158137 Edited and extended by _R. J. Mathar_, Apr 09 2009