login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A116941 Permutation of the natural numbers in conjunction with A116939 and A003056. 5
0, 1, 3, 2, 4, 6, 5, 7, 9, 11, 8, 10, 12, 14, 16, 13, 15, 17, 19, 21, 23, 18, 20, 22, 24, 26, 28, 30, 25, 27, 29, 31, 33, 35, 37, 39, 32, 34, 36, 38, 40, 42, 44, 46, 48, 41, 43, 45, 47, 49, 51, 53, 55, 57, 59, 50, 52, 54, 56, 58, 60, 62, 64, 66, 68, 70, 61, 63, 65, 67, 69, 71, 73 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,3

COMMENTS

Inverse: A116942;

A003056(n) = A116939(a(n)).

LINKS

Reinhard Zumkeller, Table of n, a(n) for n = 0..10000

Index entries for sequences that are permutations of the natural numbers

FORMULA

a(n) = A074147(n+1) - 1. - Robert G. Wilson v, Mar 09 2017

MATHEMATICA

Table[ Ceiling[(n -1)^2/2] + 2k -2, {n, 12}, {k, n}] // Flatten (* Robert G. Wilson v, Mar 09 2017 after Ivan Neretin in A074147 *)

PROG

(Haskell)

a116941 n = a116941_list !! n

a116941_list = f 0 1 (zip a116939_list [0..]) [] where

   f u v xis'@((x, i):xis) ws

     | x == u    = i : f u v xis ws

     | x == v    = f u v xis (i : ws)

     | otherwise = reverse ws ++ f v x xis' []

-- Reinhard Zumkeller, Jun 28 2013

CROSSREFS

Sequence in context: A049831 A186005 A080782 * A166695 A254107 A116942

Adjacent sequences:  A116938 A116939 A116940 * A116942 A116943 A116944

KEYWORD

nonn

AUTHOR

Reinhard Zumkeller, Feb 27 2006

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.

License Agreements, Terms of Use, Privacy Policy. .

Last modified November 18 10:08 EST 2019. Contains 329261 sequences. (Running on oeis4.)