[go: up one dir, main page]

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!)
Revision History for A247799 (Underlined text is an addition; strikethrough text is a deletion.)

Showing all changes.
A247799 a(0) = 1; a(n) = a(n-1) + (if n = a(k) for some k then k else n).
(history; published version)
#4 by Reinhard Zumkeller at Fri Sep 26 20:44:28 EDT 2014
STATUS

editing

approved

#3 by Reinhard Zumkeller at Fri Sep 26 17:22:18 EDT 2014
COMMENTS

a(n) <= A000217(n).

PROG

(Haskell)

import Data.List (elemIndex); import Data.Maybe (maybe)

a247799 n = a247799_list !! n

a247799_list = 0 : f 1 [0] where

f x zs@(z:_) = y : f (x + 1) (y : zs) where

y = z + maybe x id (elemIndex x $ reverse zs)

CROSSREFS

Cf. A000217.

#2 by Reinhard Zumkeller at Fri Sep 26 17:20:23 EDT 2014
NAME

allocateda(0) = 1; a(n) = a(n-1) + (if n = a(k) for some k then k Reinhardelse Zumkellern).

DATA

0, 1, 3, 5, 9, 12, 18, 25, 33, 37, 47, 58, 63, 76, 90, 105, 121, 138, 144, 163, 183, 204, 226, 249, 273, 280, 306, 333, 361, 390, 420, 451, 483, 491, 525, 560, 596, 605, 643, 682, 722, 763, 805, 848, 892, 937, 983, 993, 1041, 1090, 1140, 1191, 1243, 1296

OFFSET

0,3

LINKS

Reinhard Zumkeller, <a href="/A247799/b247799.txt">Table of n, a(n) for n = 0..1000</a>

KEYWORD

allocated

nonn

AUTHOR

Reinhard Zumkeller, Sep 26 2014

STATUS

approved

editing

#1 by Reinhard Zumkeller at Wed Sep 24 02:17:58 EDT 2014
NAME

allocated for Reinhard Zumkeller

KEYWORD

allocated

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 August 30 07:09 EDT 2024. Contains 375532 sequences. (Running on oeis4.)