A158388 -1 followed by infinitely many 1's.
-1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
Offset: 0
Links
- Index entries for linear recurrences with constant coefficients, signature (1).
Programs
-
Mathematica
PadRight[{-1},120,1] (* Harvey P. Dale, Apr 05 2023 *)
-
PARI
a(n)=if(n,1,-1) \\ Charles R Greathouse IV, Jun 13 2013
-
PARI
apply( {A158388(n)=1-!n*2}, [0..90]) \\ M. F. Hasler, May 30 2020
Formula
G.f.: (2x-1)/(1-x). - Philippe Deléham, Mar 19 2009
a(n) = (-1)^A000007(n) = (-1)^[n=0], where [.] is the Iverson bracket. - M. F. Hasler, May 30 2020
Comments