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!)
A225850 Inverse of permutation in A167151. 8
0, 1, 2, 3, 4, 6, 8, 5, 10, 12, 14, 16, 7, 18, 20, 22, 24, 26, 9, 28, 30, 32, 34, 36, 38, 40, 11, 42, 44, 46, 48, 50, 52, 54, 56, 13, 58, 60, 62, 64, 66, 68, 70, 72, 74, 15, 76, 78, 80, 82, 84, 86, 88, 90, 92, 94, 17, 96, 98, 100, 102, 104, 106, 108, 110, 112 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
For n > 0: a(A005228(n)) = 2*n-1 and a(A030124(n)) = 2*n.
For n > 0: A232739(n) = a(A232739(n+1))/2. - Antti Karttunen, Dec 04 2013
LINKS
FORMULA
If n < 3, a(n) = n, otherwise a(n) = (2*(A232747(n)+A232749(n))) - (A232746(n)-A232746(n-1)). - Antti Karttunen, Dec 04 2013
MATHEMATICA
nmax = 100; A5228 = {1};
Module[{d = 2, k = 1}, Do[While[MemberQ[A5228, d], d++]; k += d; d++; AppendTo[A5228, k], {n, 1, nmax}]];
a46[n_] := For[k = 1, True, k++, If[A5228[[k]] > n, Return[k - 1]]];
a47[n_] := If[n == 1, 1, a46[n] (a46[n] - a46[n - 1])];
a48[n_] := a48[n] = If[n == 1, 0, a48[n-1] + (1 - (a46[n] - a46[n-1]))];
a49[n_] := If[n == 1, 0, a48[n] (a48[n] - a48[n - 1])];
a[n_] := If[n < 3, n, 2 (a47[n] + a49[n]) - (a46[n] - a46[n - 1])];
Table[a[n], {n, 0, nmax}] (* Jean-François Alcover, Dec 09 2021 *)
PROG
(Haskell)
import Data.List (elemIndex)
import Data.Maybe (fromJust)
a225850 = fromJust . (`elemIndex` a167151_list)
(Scheme)
(define (A225850 n) (if (< n 3) n (- (* 2 (+ (A232747 n) (A232749 n))) (- (A232746 n) (A232746 (- n 1))))))
;; Antti Karttunen, Dec 04 2013
CROSSREFS
Inverse permutation: A167151.
Cf. also A005228, A030124, A232739, A232746, A232747, A232749, and also the permutation pair A232751/A232752.
Sequence in context: A277905 A257802 A369271 * A038150 A182831 A257725
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, May 17 2013
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 April 25 10:39 EDT 2024. Contains 371967 sequences. (Running on oeis4.)