login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A168181 Characteristic function of numbers that are not multiples of 8. 15
0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,1

COMMENTS

Multiplicative with a(p^e) = (if p=2 then A019590(e) else 1), p prime and e>0.

Period 8 Repeat: [0, 1, 1, 1, 1, 1, 1, 1]. - Wesley Ivan Hurt, Jun 21 2014

LINKS

Table of n, a(n) for n=0..104.

Index entries for characteristic functions

Index entries for linear recurrences with constant coefficients, signature (0,0,0,0,0,0,0,1).

FORMULA

a(n+8) = a(n);

a(n) = A000007(A010877(n));

a(A047592(n)) = 1; a(A008590(n)) = 0;

A033440(n) = SUM(a(k)*(n-k): 0<=k<=n).

Dirichlet g.f. (1-1/8^s)*zeta(s). - R. J. Mathar, Feb 19 2011

For the general case: the characteristic function of numbers that are not multiples of m is a(n) = floor((n-1)/m)-floor(n/m)+1, m,n > 0. - Boris Putievskiy, May 08 2013

a(n) = sign(n mod 8). - Wesley Ivan Hurt, Jun 21 2014

a(n) = sign( 1 - floor(cos(Pi*n/4)) ). - Wesley Ivan Hurt, Jun 21 2014

Euler transform of length 8 sequence [ 1, 0, 0, 0, 0, 0, -1, 1]. - Michael Somos, Jun 24 2014

Moebius transform is length 8 sequence [ 1, 0, 0, 0, 0, 0, 0, -1]. - Michael Somos, Jun 24 2014

G.f.: x * (1 - x^7) / ((1 - x) * (1 - x^8)). - Michael Somos, Jun 24 2014

EXAMPLE

G.f. = x + x^2 + x^3 + x^4 + x^5 + x^6 + x^7 + x^9 + x^10 + x^11 + ...

MAPLE

with(numtheory); A168181:=n->signum(n mod 8); seq(A168181(n), n=0..100); # Wesley Ivan Hurt, Jun 21 2014

MATHEMATICA

Table[Sign[Mod[n, 8]], {n, 0, 100}] (* Wesley Ivan Hurt, Jun 21 2014 *)

PROG

(MAGMA) [Sign(n mod 8) : n in [0..100]]; // Wesley Ivan Hurt, Jun 21 2014

(PARI) a(n)=n%8 > 0 \\ Felix Fröhlich, Aug 11 2014

CROSSREFS

Cf. A168185, A145568, A168184, A168182, A109720, A097325, A011558, A166486, A011655, A000035.

Sequence in context: A109720 A022932 A079421 * A164980 A168182 A168046

Adjacent sequences:  A168178 A168179 A168180 * A168182 A168183 A168184

KEYWORD

mult,nonn,easy

AUTHOR

Reinhard Zumkeller, Nov 30 2009

STATUS

approved

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

License Agreements, Terms of Use, Privacy Policy .

Last modified July 23 05:58 EDT 2017. Contains 289686 sequences.