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

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A124502 a(1)=a(2)=1; thereafter, a(n+1) = a(n)+a(n-1)+1 if n is a multiple of 5, otherwise a(n+1) = a(n)+a(n-1). 4
1, 1, 2, 3, 5, 9, 14, 23, 37, 60, 98, 158, 256, 414, 670, 1085, 1755, 2840, 4595, 7435, 12031, 19466, 31497, 50963, 82460, 133424, 215884, 349308, 565192, 914500, 1479693, 2394193, 3873886, 6268079, 10141965, 16410045, 26552010, 42962055, 69514065, 112476120 (list; graph; refs; listen; history; internal format)
OFFSET

1,3

COMMENTS

If we split this sequence into 5 seperate sequences of n mod 5, each individual sequence is of the form a(n)=12*a(n-1)-10*a(n-2)-a(n-3).For example,12*98-10*9-1=1085. This is the same recurrence exhibited in A138134 and the n mod 5 =0 sequence...5,60,670,7435 is A138134.

FORMULA

O.g.f.: x/((1-x)*(x^4+x^3+x^2+x+1)*(1-x-x^2)) . - R. J. Mathar (mathar(AT)strw.leidenuniv.nl), May 30 2008

a(n+5)= a(n) + Fibonacci(n+5), n>5

a(n)=12*a(n-5)-10*a(n-10)-a(n-15) [From Gary Detlefs (gedtlefs(AT)aol.com), Dec 10 2010]

EXAMPLE

a(6)= a(5)+a(4)+1 = 5+3+1 = 9 because n=5 is a multiple of 5.

a(7)= a(6)+a(5) = 9+5 = 14 because n=6 is not a multiple of 5.

MAPLE

A124502:=proc(n) option remember; local t1; if n <= 2 then return 1; fi: if n mod 5 = 1 then t1:=1 else t1:=0; fi: procname(n-1)+procname(n-2)+t1; end proc; [seq(A124502(n), n=1..100)]; - N. J. A. Sloane (njas(AT)research.att.com), May 25 2008

MATHEMATICA

a=0; b=0; lst={a, b}; Do[z=a+b+1; AppendTo[lst, z]; a=b; b=z; z=a+b; AppendTo[lst, z]; a=b; b=z; z=a+b; AppendTo[lst, z]; a=b; b=z; z=a+b; AppendTo[lst, z]; a=b; b=z; z=a+b; AppendTo[lst, z]; a=b; b=z, {n, 4!}]; lst [From Vladimir Orlovsky (4vladimir(AT)gmail.com), Feb 16 2010]

CROSSREFS

Cf. A052952, A004695, A080239, A131132.

Sequence in context: A076027 A056686 A079962 * A173714 A026746 A004699

Adjacent sequences:  A124499 A124500 A124501 * A124503 A124504 A124505

KEYWORD

nonn

AUTHOR

N. J. A. Sloane (njas(AT)research.att.com), May 25 2008

EXTENSIONS

Typo in Maple code corrected by R. J. Mathar (mathar(AT)strw.leidenuniv.nl), May 30 2008

More specific name from R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Dec 09 2009

Indices in definition corrected Nov 25 2010 by N. J. A. Sloane

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

Content is available under The OEIS End-User License Agreement .

Last modified February 15 20:03 EST 2012. Contains 205852 sequences.