The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A171911 Van Eck's sequence (cf. A181391), but starting with a(1) = 1. 12
 1, 0, 0, 1, 3, 0, 3, 2, 0, 3, 3, 1, 8, 0, 5, 0, 2, 9, 0, 3, 9, 3, 2, 6, 0, 6, 2, 4, 0, 4, 2, 4, 2, 2, 1, 23, 0, 8, 25, 0, 3, 19, 0, 3, 3, 1, 11, 0, 5, 34, 0, 3, 7, 0, 3, 3, 1, 11, 11, 1, 3, 5, 13, 0, 10, 0, 2, 33, 0, 3, 9, 50, 0, 4, 42, 0, 3, 7, 25, 40, 0, 5, 20, 0, 3, 8, 48, 0, 4, 15 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,5 COMMENTS After the initial value, the sequence is extended by a(n+1) = min { k > 0: a(n-k) = a(n) } or 0 if no such k exists, i.e., if a(n) did not appear earlier. LINKS Chai Wah Wu, Table of n, a(n) for n = 1..10001 MATHEMATICA t = {1}; Do[ d = Quiet[Check[Position[t, Last[t]][[-2]][[1]], 0], Part::partw]; If[d == 0, x = 0, x = Length[t] - d]; AppendTo[t, x], 100] t (* Horst H. Manninger, Aug 03 2020 *) PROG (Python) A171911_list, l = [1, 0], 0 for n in range(1, 10**4):     for m in range(n-1, -1, -1):         if A171911_list[m] == l:             l = n-m             break     else:   # break did not occur         l = 0     A171911_list.append(l) # Chai Wah Wu, Jan 02 2015 (PARI) A171911_vec(N, a=1, i=Map())={vector(N, n, a=if(n>1, iferr(n-mapget(i, a), E, 0)+mapput(i, a, n), a))} \\ M. F. Hasler, Jun 11 2019 CROSSREFS Cf. A181391, A171912, A171913, A171914, A171915, A171916, A171917, A171918 (same but starting with 0, 2, ..., 8). Sequence in context: A298082 A085919 A105824 * A180193 A229964 A309722 Adjacent sequences:  A171908 A171909 A171910 * A171912 A171913 A171914 KEYWORD nonn AUTHOR N. J. A. Sloane, Oct 22 2010 EXTENSIONS Edited by M. F. Hasler, Jun 11 2019 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified September 24 21:35 EDT 2020. Contains 337322 sequences. (Running on oeis4.)