cp's OEIS Frontend

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.

Showing 1-4 of 4 results.

A246368 Permutation of natural numbers: a(n) = A227413(A005941(n)).

Original entry on oeis.org

1, 2, 4, 3, 6, 7, 8, 5, 9, 13, 10, 17, 20, 19, 12, 11, 46, 23, 166, 41, 15, 29, 858, 59, 14, 71, 16, 67, 6186, 37, 58645, 31, 18, 199, 22, 83, 705348, 983, 32, 179, 10428487, 47, 184718194, 109, 21, 6659, 3840230006, 277, 27, 43, 65, 353
Offset: 1

Views

Author

Antti Karttunen, Aug 26 2014

Keywords

Crossrefs

Inverse: A246367.
Similar or related permutations: A005941, A156552, A227413, A246364, A246366.

Programs

Formula

a(n) = A227413(A005941(n)) = A227413(1+A156552(n)).
Other identities:
For all n >= 1, A010051(a(n)) = 1 - A000035(n). [This permutation maps even numbers to primes and odd numbers to nonprimes, in some order, because the permutation A227413 has the same property and A005941 preserves the parity].

A246364 Permutation of natural numbers: a(n) = A064216(A227413(n)).

Original entry on oeis.org

1, 2, 5, 3, 7, 11, 13, 4, 6, 9, 19, 14, 8, 12, 29, 10, 17, 31, 23, 16, 41, 71, 37, 44, 47, 39, 43, 42, 38, 30, 26, 59, 22, 34, 15, 85, 53, 58, 25, 130, 57, 151, 61, 311, 103, 69, 33, 365, 157, 111, 73, 226, 74, 106, 67, 370, 223, 56, 97, 341, 139, 122, 35, 133, 55, 86, 20, 145, 46, 49, 21, 659, 118, 36, 83, 419, 127, 191, 18
Offset: 1

Views

Author

Antti Karttunen, Aug 26 2014

Keywords

Comments

After a(2) = 2, the rest of the even bisection contains only terms of A246261. However, some of the terms of A246261 are also found in the odd bisection, while terms of A246263, apart from 2, all reside in the odd bisection of this sequence.

Crossrefs

Inverse: A246363.
Related or similar permutations: A064216, A227413, A246366, A246368.

Programs

Formula

a(n) = A064216(A227413(n)).

A246380 Permutation of natural numbers: a(1) = 1, a(2n) = nthcomposite(a(n)), a(2n-1) = nthprime(a(A064989(2n-1)-1)), where nthprime = A000040, nthcomposite = A002808, and A064989(n) shifts the prime factorization of n one step towards smaller primes.

Original entry on oeis.org

1, 4, 2, 9, 7, 6, 23, 16, 3, 14, 13, 12, 43, 35, 17, 26, 37, 8, 101, 24, 5, 22, 19, 21, 53, 62, 83, 51, 79, 27, 233, 39, 191, 54, 149, 15, 103, 134, 11, 36, 47, 10, 151, 34, 41, 30, 29, 33, 73, 75, 241, 86, 113, 114, 89, 72, 1153, 108, 443, 40, 593, 296, 547, 56, 167, 245, 173, 76, 563, 194, 1553, 25
Offset: 1

Views

Author

Antti Karttunen, Aug 29 2014

Keywords

Comments

Has an infinite number of infinite cycles. See comments in A246379.

Crossrefs

Inverse: A246379.
Similar or related permutations: A246376, A246378, A246363, A246364, A246366, A246368, A064216, A246682.

Programs

  • PARI
    default(primelimit,(2^31)+(2^30));
    A002808(n) = { my(k=-1); while( -n + n += -k + k=primepi(n), ); n }; \\ This function from M. F. Hasler
    A064989(n) = {my(f); f = factor(n); if((n>1 && f[1,1]==2), f[1,2] = 0); for (i=1, #f~, f[i,1] = precprime(f[i,1]-1)); factorback(f)};
    A246380(n) = if(1==n, 1, if(!(n%2), A002808(A246380(n/2)), prime(A246380(A064989(n)-1))));
    for(n=1, 3098, write("b246380.txt", n, " ", A246380(n)));
    (Scheme, with memoization-macro definec)
    (definec (A246380 n) (cond ((< n 2) n) ((even? n) (A002808 (A246380 (/ n 2)))) (else (A000040 (A246380 (- (A064989 n) 1))))))

Formula

a(1) = 1, a(2n) = nthcomposite(a(n)), a(2n-1) = nthprime(a(A064989(2n-1)-1)), where nthprime = A000040, nthcomposite = A002808, and A064989(n) shifts the prime factorization of n one step towards smaller primes.
As a composition of related permutations:
a(n) = A246378(A246376(n)).
Other identities. For all n > 1 the following holds:
A010051(a(n)) = A000035(n). [Maps odd numbers larger than one to primes, and even numbers to composites, in some order. Permutations A246378 & A246682 have the same property].

A246365 Permutation of natural numbers: a(n) = A135141(A005940(n)).

Original entry on oeis.org

1, 2, 4, 3, 8, 5, 7, 9, 6, 17, 19, 11, 39, 35, 25, 15, 16, 13, 23, 33, 29, 37, 75, 27, 95, 87, 61, 55, 767, 45, 83, 67, 10, 21, 47, 71, 159, 143, 139, 51, 319, 175, 639, 287, 251, 263, 247, 135, 527, 239, 199, 447, 105, 115, 991, 119, 1015, 443, 4575, 85, 583, 2175, 1343, 151, 12, 31, 63, 69, 131, 77
Offset: 1

Views

Author

Antti Karttunen, Aug 26 2014

Keywords

Comments

Even terms occur at the positions 2^n + 1 (A000051), in some order, and the odd terms everywhere else.

Crossrefs

Inverse: A246366.
Related or similar permutations: A005940, A135141, A246363, A246367.

Programs

Formula

a(n) = A135141(A005940(n)).
Showing 1-4 of 4 results.