login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


A164287
Sequence resulting from an infinite series of reordering steps applied to the sequence of natural numbers A000027: At step n number n is moved from its position p to position p+k, where k is the actual number at position p+1.
2
1, 3, 2, 4, 5, 8, 6, 7, 9, 12, 13, 10, 11, 16, 14, 17, 18, 15, 20, 24, 19, 25, 21, 22, 23, 31, 26, 34, 27, 33, 28, 37, 29, 38, 36, 30, 39, 32, 35, 46, 44, 47, 40, 48, 41, 42, 43, 49, 50, 53, 45, 58, 51, 59, 61, 52, 67, 54, 68, 55, 69, 56, 70, 57, 60, 73, 62, 63, 64, 65, 66, 80
OFFSET
1,2
COMMENTS
This sequence is a permutation of the natural numbers.
LINKS
E. Angelini, Colour, drag and drop sequence [Cached copy, with permission]
E. Angelini, Color, read and jump sequence [Cached copy, with permission]
MAPLE
mx:= 620: # increase mx to get more items
l:= [i$i=1..2*mx]: pos:= proc(n) global l; local i; for i to nops(l) while l[i]<>n do od; `if`(i>nops(l), -1, i) end: for n from 1 to mx do p:= pos(n); k:= l[p+1]; l:= [l[1..p-1][], l[p+1..p+k][], l[p], l[p+k+1..nops(l)][]] od: p:= pos(mx+1): a:= n-> `if`(n<p, l[n], NULL): seq(a(n), n=1..p);
MATHEMATICA
max = 200; r = Range[max]; For[n = 1, True, n++, p = Position[r, n]; If[p == {} || (q = p[[1, 1]] + r[[p[[1, 1]] + 1]] + 1) > max, Break[], c = r[[q]]; r = r /. {a___, n, b___, c, d___} :> {a, b, n, c, d}]]; A164287 = r[[1 ;; 72]] (* Jean-François Alcover, Jun 14 2012 *)
CROSSREFS
Cf. A164286.
Sequence in context: A370803 A326357 A354731 * A086962 A001612 A275901
KEYWORD
nice,nonn,look
AUTHOR
Eric Angelini and Alois P. Heinz, Aug 12 2009
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | 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 September 22 19:55 EDT 2024. Contains 376138 sequences. (Running on oeis4.)