

A079998


The characteristic function of the multiples of five.


25



1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

0,1


COMMENTS

Number of permutations satisfying k <= p(i)  i <= r and p(i)  i not in I, i = 1..n, with k = 2, r = 3, I = {1, 0, 1, 2}.
a(n) = 1 if n = 5k, a(n) = 0 otherwise. Also, number of permutations satisfying k <= p(i)  i <= r and p(i)  i not in I, i = 1..n, with k = 1, r = 4, I = {0, 1, 2, 3}.
a(n) is also the number of partitions of n with each part being five (a(0) = 1 because the empty partition has no parts to test equality with five). Hence a(n) is also the number of 2regular graphs on n vertices with each component having girth exactly five.  Jason Kimberley, Oct 02 2011
This sequence is the Euler transformation of A185015.  Jason Kimberley, Oct 02 2011


REFERENCES

D. H. Lehmer, Permutations with strongly restricted displacements. Combinatorial theory and its applications, II (Proc. Colloq., Balatonfured, 1969), pp. 755770. NorthHolland, Amsterdam, 1970.


LINKS

Antti Karttunen, Table of n, a(n) for n = 0..16385
Vladimir Baltic, On the number of certain types of strongly restricted permutations, Applicable Analysis and Discrete Mathematics Vol. 4, No 1 (April, 2010), 119135.
Index entries for characteristic functions
Index entries for linear recurrences with constant coefficients, signature (0, 0, 0, 0, 1).


FORMULA

Recurrence: a(n) = a(n5). G.f.: 1/(x^5  1).
a(n) = (((4*cos(n*2*Pi/5) + 1)^2)/5  1)/4 or a(n) = ((8*(sin(n*2*Pi/5))^2  5)^2  5)/20.  Paolo P. Lava, Aug 24 2006
a(n) = 1(n^4 mod 5) with n >= 0. a(n) = 1/50*(9*(n mod 5) + ((n+1) mod 5) + ((n+2) mod 5) + ((n+3) mod 5) + 11*((n+4) mod 5)) with n >= 0.  Paolo P. Lava, Nov 29 2006
a(n) = 1  A011558(n); a(A008587(n)) = 1; a(A047201(n)) = 0.  Reinhard Zumkeller, Nov 30 2009
a(n) = floor(1/2*cos(2*n*Pi/5) + 1/2).  Gary Detlefs, May 16 2011
a(n) = floor(n/5)  floor((n1)/5).  Tani Akinari, Oct 21 2012
a(n) = binomial(n  1, 4) mod 5.  Wesley Ivan Hurt, Oct 06 2014


MAPLE

A079998:=n>binomial(n1, 4) mod 5: seq(A079998(n), n=0..100); # Wesley Ivan Hurt, Oct 06 2014


MATHEMATICA

Table[Mod[Binomial[n  1, 4], 5], {n, 0, 100}] (* Wesley Ivan Hurt, Oct 06 2014 *)
Table[Boole[Divisible[n, 5]], {n, 0, 99}] (* Alonso del Arte, Nov 29 2014 *)


PROG

(PARI) a(n)=!(n%5) \\ Charles R Greathouse IV, Mar 07 2012
(MAGMA) [Binomial(n1, 4) mod 5 : n in [0..100]]; // Wesley Ivan Hurt, Oct 06 2014
(Scheme) (define (A079998 n) (if (zero? (modulo n 5)) 1 0)) ;; Antti Karttunen, Dec 21 2017


CROSSREFS

Cf. A011558, A008587, A002524A002529, A072827, A072850A072856, A079955A080014.
Characteristic function of multiples of g: A000007 (g = 0), A000012 (g = 1), A059841 (g = 2), A079978 (g = 3), A121262 (g = 4), this sequence (g = 5), A079979 (g = 6), A082784 (g = 7).  Jason Kimberley, Oct 14 2011
Sequence in context: A014159 A014184 A014359 * A320656 A322075 A288220
Adjacent sequences: A079995 A079996 A079997 * A079999 A080000 A080001


KEYWORD

nonn,easy


AUTHOR

Vladimir Baltic, Feb 10 2003


EXTENSIONS

More terms from Antti Karttunen, Dec 21 2017


STATUS

approved



