login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A153881 1 followed by -1, -1, -1, ... . 30
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 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
Dirichlet inverse of A074206.
LINKS
FORMULA
G.f: x*(1-2*x)/(1-x). - Mats Granvik, Mar 09 2009, rewritten R. J. Mathar, Mar 31 2010
a(n) = (-1)^A000040(n). - Juri-Stepan Gerasimov, Sep 10 2009
G.f.: x / (1 + x / (1 - 2*x)). - Michael Somos, Apr 02 2012
From Wesley Ivan Hurt, Jun 20 2014: (Start)
a(1) = 1; a(n) = -1, n > 1.
a(n) = 1 - 2*sign(n-1) = 1 - 2*A057427(n-1).
a(n) = (-1)^sign(1-n) = (-1)^A057427(1-n).
a(n) = 2*floor(1/n)-1 = 2*A063524(n)-1. (End)
Dirichlet g.f.: 2 - zeta(s). - Álvar Ibeas, Dec 30 2018
MAPLE
A153881:=n->`if`(n=1, 1, -1); seq(A153881(n), n=1..100); # Wesley Ivan Hurt, Jun 20 2014
MATHEMATICA
Table[1 - 2 Sign[n - 1], {n, 100}] (* Wesley Ivan Hurt, Jun 20 2014 *)
PROG
(Magma) [1 - 2*Sign(n-1) : n in [1..100]]; // Wesley Ivan Hurt, Jun 20 2014
(PARI) a(n)=if(n>1, -1, 1) \\ Charles R Greathouse IV, Sep 24 2015
CROSSREFS
If prefixed by initial 0, we get A134824.
Sequence in context: A186032 A212157 A131554 * A160357 A186039 A332433
KEYWORD
sign,easy
AUTHOR
Mats Granvik, Jan 03 2009
EXTENSIONS
Edited by Charles R Greathouse IV, Mar 18 2010
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified March 18 22:56 EDT 2024. Contains 370952 sequences. (Running on oeis4.)