This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A246162 #22 Aug 20 2014 23:58:27 %S A246162 1,2,4,3,5,8,11,7,6,9,13,14,31,47,17,25,12,10,19,15,37,59,20,21,61, %T A246162 185,42,319,62,24,87,137,34,18,55,16,41,97,27,22,67,229,49,415,76,28, %U A246162 103,29,109,425,78,1627,222,54,283,3053,373,79,433,33,131,647,108,1123,166,45,203,26,91,379,71,23 %N A246162 Permutation of natural numbers: a(1) = 1, a(A000069(n)) = A014580(a(n-1)), a(A001969(n)) = A091242(a(n-1)), where A000069 and A001969 are the odious and evil numbers, and A014580 resp. A091242 are the binary coded irreducible resp. reducible polynomials over GF(2). %C A246162 This is an instance of entanglement-permutation, where the two complementary pairs to be entangled with each other are A000069/A001969 (odious and evil numbers) and A014580/A091242 (binary codes for irreducible and reducible polynomials over GF(2)). %C A246162 Because 3 is the only evil number in A014580, it implies that, apart from a(4)=3, all other odious positions contain an odious number. There are also odious numbers in some of the evil positions, precisely all the terms of A246158 in some order, together with all evil numbers larger than 3. (Permutation A246164 has the same property, except there a(7)=3.) See comments in A246161 for more details how this affects the cycle structure of these permutations. %H A246162 Antti Karttunen, <a href="/A246162/b246162.txt">Table of n, a(n) for n = 1..207</a> %H A246162 <a href="/index/Ge#GF2X">Index entries for sequences operating on GF(2)[X]-polynomials</a> %H A246162 <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a> %F A246162 a(1) = 1, and for n > 1, if A010060(n) = 1 [i.e. n is one of the odious numbers, A000069], a(n) = A014580(a(A115384(n)-1)), otherwise, a(n) = A091242(a(A245710(n))). %F A246162 As a composition of related permutations: %F A246162 a(n) = A245702(A233279(n)). %F A246162 a(n) = A246202(A006068(n)). %F A246162 a(n) = A246164(A234612(n)). %F A246162 For all n > 1, A091225(a(n)) = A010060(n). [Maps odious numbers to binary representations of irreducible GF(2) polynomials (A014580) and evil numbers to the corresponding representations of reducible polynomials (A091242), in some order]. %o A246162 (Scheme, with memoization-macro definec) %o A246162 (definec (A246162 n) (cond ((= 1 n) n) ((= 1 (A010060 n)) (A014580 (A246162 (- (A115384 n) 1)))) (else (A091242 (A246162 (A245710 n)))))) %Y A246162 Inverse: A246161. %Y A246162 Related permutations: A006068, A233279, A234612, A237427, A245702, A246202, A246164. %Y A246162 Cf. A010060, A014580, A091242, A115384, A245710. %K A246162 nonn %O A246162 1,2 %A A246162 _Antti Karttunen_, Aug 17 2014. Erroneous comment corrected Aug 20 2014