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!)
A259615 a(0)=0, a(1)=a(2)=a(3)=a(4)=1; thereafter, a(n) = Sum_{k=1..5} a(n-k-(a(n-k) mod 5)). 1
0, 1, 1, 1, 1, 3, 4, 5, 9, 9, 11, 19, 23, 27, 45, 87, 105, 205, 401, 587, 747, 1121, 1763, 2145, 4085, 7965, 15529, 16545, 32503, 38323, 49767, 74305, 146847, 180069, 210427, 341745, 650987, 787109, 917411 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,6
LINKS
PROG
(Sage) def first(m):
v=[0, 1, 1, 1, 1]
for i in range(5, m+1):
l=0
for s in range(1, 5+1):
l += v[i-s-v[i-s]%5]
v.append(l)
return v
(Ruby) def first(m)
v=[0, 1, 1, 1, 1]
for i in 5..m-1
i2=0
for j in 1..5
r=i-j
i2 += v[r-v[r]%5]
end
v << i2
end
v
end
CROSSREFS
Cf. A000322, A241154 (sequence obtained without mod 5 in formula).
Sequence in context: A202475 A036710 A098801 * A069807 A132141 A246303
KEYWORD
nonn
AUTHOR
Anders Hellström, Jun 30 2015
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 28 04:05 EDT 2024. Contains 371235 sequences. (Running on oeis4.)