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!)
 A244319 Self-inverse permutation of natural numbers: a(1) = 1, a(2n) = A003961(1+a(A064989(2n-1))), a(2n+1) = 1+A003961(a(A064989(2n+1)-1)). 12
 1, 3, 2, 9, 6, 5, 26, 11, 4, 21, 8, 125, 56, 25, 16, 15, 344, 115, 36, 1015, 10, 39, 204, 41, 14, 7, 52, 45, 86, 301, 176, 155, 298, 51, 50, 19, 518, 305, 22, 189, 24, 895, 1376, 49, 28, 825, 1268, 11875, 44, 35, 34, 27, 3186, 6625, 2388, 13, 454, 153, 126, 3191, 476, 131 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,2 COMMENTS After 1, maps each even number to a unique odd number and vice versa, i.e., for all n > 1, A000035(a(n)) XOR A000035(n) = 1, where XOR is given in A003987. LINKS Antti Karttunen, Table of n, a(n) for n = 1..10001 FORMULA a(1) = 1, a(2n) = A003961(1+a(A064989(2n-1))), a(2n+1) = A243501(a(A064989(2n+1)-1)). As a composition of related permutations: a(n) = A245609(A048673(n)) = A064216(A245610(n)). PROG (PARI) A003961(n) = my(f = factor(n)); for (i=1, #f~, f[i, 1] = nextprime(f[i, 1]+1)); factorback(f); \\ This function from Michel Marcus A064989(n) = my(f = factor(n)); for(i=1, #f~, if((2 == f[i, 1]), f[i, 1] = 1, f[i, 1] = precprime(f[i, 1]-1))); factorback(f); A244319(n) = if(1==n, 1, if(0==(n%2), A003961(1+A244319(A064989(n-1))), 1+A003961(A244319(A064989(n)-1)))); for(n=1, 10001, write("b244319.txt", n, " ", A244319(n))) (Scheme, with Antti Karttunen's IntSeq-library for memoizing definec-macro) (definec (A244319 n) (cond ((= 1 n) 1) ((even? n) (A003961 (+ 1 (A244319 (A064989 (- n 1)))))) (else (A243501 (A244319 (-1+ (A064989 n))))))) CROSSREFS Cf. A000035, A003987, A003961, A064989, A243501. Related permutations: A048673, A064216, A245609-A245610. Similar entanglement permutations: A245605-A245606, A235491, A236854, A243347, A244152. Sequence in context: A125152 A229119 A269867 * A269359 A270199 A082819 Adjacent sequences:  A244316 A244317 A244318 * A244320 A244321 A244322 KEYWORD nonn AUTHOR Antti Karttunen, Jul 18 2014; description corrected and PARI code added Jul 30 2014 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 August 9 11:08 EDT 2020. Contains 336323 sequences. (Running on oeis4.)