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

 

Logo

Please make a donation to keep the OEIS running. We are now in our 55th year. In the past year we added 12000 new sequences and reached 8000 citations (which often say "discovered thanks to the OEIS"). We need to raise money to hire someone to manage submissions, which would reduce the load on our editors and speed up editing.
Other ways to donate

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A082784 Characteristic function of multiples of 7. 22

%I

%S 1,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,

%T 0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,

%U 0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0

%N Characteristic function of multiples of 7.

%C a(0)=1, a(n)=0 for 1<=n<7, a(n+7)=a(n).

%C a(n) = 1-A109720(n); a(A008589(n))=1; a(A047304(n))=0. - _Reinhard Zumkeller_, Nov 30 2009

%C This sequence is the Euler transformation of A185017. - _Jason Kimberley_, Oct 14 2011

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

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

%F a(n) = 0^(n mod 7).

%F a(n) = (1/147)*(-20*(n mod 7)+((n+1) mod 7)+((n+2) mod 7)+((n+3) mod 7)+((n+4) mod 7)+((n+5) mod 7)+22*((n+6) mod 7)). - _Paolo P. Lava_, Sep 29 2006

%F a(n) = 1-(n^6 mod 7). - _Paolo P. Lava_, Oct 02 2006

%F Multiplicative with a(p) = (if p=7 then 1 else 0), p prime. - _Reinhard Zumkeller_, Nov 30 2009

%F a(n) = floor(n/7)-floor((n-1)/7). - _Tani Akinari_, Oct 26 2012

%F a(n) = C(n-1,6) mod 7. - _Wesley Ivan Hurt_, Oct 07 2014

%F From _Wesley Ivan Hurt_, Jul 11 2016: (Start)

%F G.f.: 1/(1-x^7).

%F a(n) = a(n-7) for n>6.

%F a(n) = (gcd(n,7) - 1)/6. (End)

%e a(14) = a(2*7) = 1; a(41) = a(5*7+6) = 0.

%p A082784:=n->0^(n mod 7): seq(A082784(n), n=0..100); # _Wesley Ivan Hurt_, Oct 07 2014

%t Table[Mod[Binomial[n - 1, 6], 7], {n, 0, 100}] (* _Wesley Ivan Hurt_, Oct 07 2014 *)

%o (Haskell)

%o a082784 = a000007 . (`mod` 7)

%o a082784_list = cycle [1,0,0,0,0,0,0]

%o -- _Reinhard Zumkeller_, Oct 27 2012

%o (PARI) a(n)=!(n%7) \\ _Charles R Greathouse IV_, Dec 03 2012

%o (MAGMA) [Binomial(n-1,6) mod 7 : n in [0..100]]; // _Wesley Ivan Hurt_, Oct 07 2014

%Y Cf. A008589, A076309.

%Y Characteristic function of multiples of g: A000007 (g=0), A000012 (g=1), A059841 (g=2), A079978 (g=3), A121262 (g=4), A079998 (g=5), A079979 (g=6), this sequence (g=7). - _Jason Kimberley_, Oct 14 2011

%Y Cf. A000007.

%K nonn,easy

%O 0,1

%A _Reinhard Zumkeller_, May 22 2003

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.

License Agreements, Terms of Use, Privacy Policy. .

Last modified December 9 13:50 EST 2019. Contains 329877 sequences. (Running on oeis4.)