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!)
A138037 a(0) = 0, a(n+1) = n + a(n)/(2 - a(n) mod 2). 3
0, 1, 3, 6, 7, 12, 12, 13, 21, 30, 25, 36, 30, 28, 28, 29, 45, 62, 49, 68, 54, 48, 46, 46, 47, 72, 62, 58, 57, 86, 73, 104, 84, 75, 109, 144, 108, 91, 129, 168, 124, 103, 145, 188, 138, 114, 103, 150, 123, 172, 136, 119, 171, 224, 166, 138, 125, 182, 149, 208, 164, 143 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
A138038 and A138039 respectively give record values and where they occur.
LINKS
MAPLE
a[0]:= 0:
for n from 0 to 100 do a[n+1] := n + a[n]/(2 - (a[n] mod 2)) od:
seq(a[n], n=0..101); # Robert Israel, Jan 12 2016
MATHEMATICA
a[0] = 0; a[n_] := n - 1 + a[n - 1]/(2 - Mod[a[n - 1], 2]); Table[a@ n, {n, 20}] (* Michael De Vlieger, Jan 12 2016 *)
nxt[{n_, a_}]:={n+1, n+1+a/(2-Mod[a, 2] )}; NestList[nxt, {0, 0}, 70][[All, 2]] (* Harvey P. Dale, Sep 28 2016 *)
CROSSREFS
Sequence in context: A084125 A053478 A269363 * A209246 A073934 A333790
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Mar 02 2008
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 April 23 16:40 EDT 2024. Contains 371916 sequences. (Running on oeis4.)