[go: up one dir, main page]

login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A101906
Inverse permutation to A101905.
1
1, 2, 4, 3, 6, 8, 10, 5, 7, 12, 14, 16, 18, 11, 20, 9, 22, 24, 15, 26, 13, 28, 30, 19, 32, 34, 36, 38, 40, 23, 42, 17, 44, 21, 46, 27, 48, 50, 52, 31, 54, 56, 58, 35, 25, 60, 29, 62, 64, 66, 39, 68, 70, 72, 74, 43, 76, 78, 37, 80, 47, 82, 84, 33, 86, 88, 51, 90, 92, 94, 96, 55
OFFSET
1,2
MAPLE
A101261 := proc(nmax) local a, n, anex ; a := [1, 2] ; while nops(a) < nmax do if nops(a) mod 2 = 0 then a := [op(a), 1] ; else n := (nops(a)+1)/2 ; n := op(n, a) ; anex := 2 ; while anex in a or n > 1 do if not anex in a then n := n-1 ; fi ; anex := anex+1 ; od ; a := [op(a), anex] ; fi ; od ; RETURN(a) ; end: A101905 := proc(nmax) local a, n, anex ; a := A101261(2*nmax) ; for n from 2*nmax-1 to 3 by -2 do a := subsop(n=NULL, a) ; od ; RETURN(a) ; end: a := A101905(80) ; n:= 1: while member(n, a, 'ninv') do printf("%d, ", ninv) ; n := n+1 : od : # R. J. Mathar, May 02 2007
CROSSREFS
Sequence in context: A357910 A367082 A039864 * A297403 A120241 A352714
KEYWORD
easy,less,nonn
AUTHOR
Leroy Quet, Dec 20 2004
EXTENSIONS
More terms from R. J. Mathar, May 02 2007
More terms from David Wasserman, Mar 31 2008
STATUS
approved