The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A168181 Characteristic function of numbers that are not multiples of 8. 16

%I

%S 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,

%T 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,

%U 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

%N Characteristic function of numbers that are not multiples of 8.

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

%C Period 8 Repeat: [0, 1, 1, 1, 1, 1, 1, 1]. - _Wesley Ivan Hurt_, Jun 21 2014

%H Antti Karttunen, <a href="/A168181/b168181.txt">Table of n, a(n) for n = 0..16384</a>

%H <a href="/index/Ch#char_fns">Index entries for characteristic functions</a>

%H <a href="/index/Rec#order_08">Index entries for linear recurrences with constant coefficients</a>, signature (0,0,0,0,0,0,0,1).

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

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

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

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

%F Dirichlet g.f. (1-1/8^s)*zeta(s). - _R. J. Mathar_, Feb 19 2011

%F 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

%F a(n) = sign(n mod 8). - _Wesley Ivan Hurt_, Jun 21 2014

%F a(n) = sign( 1 - floor(cos(Pi*n/4)) ). - _Wesley Ivan Hurt_, Jun 21 2014

%F Euler transform of length 8 sequence [ 1, 0, 0, 0, 0, 0, -1, 1]. - _Michael Somos_, Jun 24 2014

%F Moebius transform is length 8 sequence [ 1, 0, 0, 0, 0, 0, 0, -1]. - _Michael Somos_, Jun 24 2014

%F G.f.: x * (1 - x^7) / ((1 - x) * (1 - x^8)). - _Michael Somos_, Jun 24 2014

%F a(n) = 1-A253513(n). - _Antti Karttunen_, Oct 08 2017

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

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

%t Table[Sign[Mod[n,8]], {n, 0, 100}] (* _Wesley Ivan Hurt_, Jun 21 2014 *)

%o (MAGMA) [Sign(n mod 8) : n in [0..100]]; // _Wesley Ivan Hurt_, Jun 21 2014

%o (PARI) a(n)=n%8 > 0 \\ _Felix FrÃ¶hlich_, Aug 11 2014

%Y Cf. A168185, A145568, A168184, A168182, A109720, A097325, A011558, A166486, A011655, A000035, A010877, A244413, A253513.

%K mult,nonn,easy

%O 0,1

%A _Reinhard Zumkeller_, Nov 30 2009

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

Last modified April 16 18:21 EDT 2021. Contains 343050 sequences. (Running on oeis4.)