The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A117824 a(0) = 0, a(1) = 1; for n >= 2, a(n) = a(n-1) + a(n-2) - (n-1) if that number is positive and not already in the sequence, otherwise a(n) = a(n-1) + a(n-2) + (n-1). 3
0, 1, 2, 5, 4, 13, 12, 19, 24, 35, 50, 75, 114, 177, 278, 441, 704, 1129, 1816, 2927, 4724, 7631, 12334, 19943, 32254, 52173, 84402, 136549, 220924, 357445, 578340, 935755, 1514064, 2449787, 3963818, 6413571, 10377354, 16790889, 27168206, 43959057 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
LINKS
MAPLE
a[0]:=0: a[1]:=1: A:={0, 1}: for n from 2 to 42 do if a[n-1]+a[n-2]-n+1>0 and member(a[n-1]+a[n-2]-n+1, A)=false then a[n]:=a[n-1]+a[n-2]-n+1: A:=A union {a[n-1]+a[n-2]-n+1} else a[n]:=a[n-1]+a[n-2]+n-1: A:=A union {a[n-1]+a[n-2]+n-1} fi: od: seq(a[n], n=0..42); # Emeric Deutsch, Apr 30 2006
CROSSREFS
Sequence in context: A084410 A338073 A080067 * A122212 A264071 A212188
KEYWORD
nonn,easy
AUTHOR
N. J. A. Sloane, Apr 30 2006
EXTENSIONS
More terms from Emeric Deutsch, Apr 30 2006
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 May 14 14:06 EDT 2024. Contains 372533 sequences. (Running on oeis4.)