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.

Previous Showing 11-20 of 68 results. Next

A369044 LCM-transform of bijective bit reverse (A057889).

Original entry on oeis.org

1, 2, 3, 2, 5, 1, 7, 2, 3, 1, 13, 1, 11, 1, 1, 2, 17, 1, 5, 1, 1, 1, 29, 1, 19, 1, 3, 1, 23, 1, 31, 2, 1, 1, 7, 1, 41, 1, 1, 1, 37, 1, 53, 1, 1, 1, 61, 1, 1, 1, 1, 1, 43, 1, 59, 1, 1, 1, 1, 1, 47, 1, 1, 2, 1, 1, 97, 1, 3, 1, 113, 1, 73, 1, 1, 1, 89, 1, 11, 1, 1, 1, 101, 1, 1, 1, 1, 1, 1, 1, 109, 1, 1, 1, 5, 1, 67
Offset: 1

Views

Author

Antti Karttunen, Jan 12 2024

Keywords

Comments

Bijective bit reverse, A057889, is a permutation related to the binary expansion of n that keeps all the numbers of range [2^k, 2^(1+k)[ in the same range, i.e., for all n >= 1, A000523(A057889(n)) = A000523(n), from which it immediately follows that A057889 has the property S mentioned in the comments of A368900, and therefore this sequence is equal to A014963(A057889(n)), for n >= 1.

Crossrefs

Programs

  • PARI
    up_to = 65537; \\ Checked up to 2^17;
    LCMtransform(v) = { my(len = length(v), b = vector(len), g = vector(len)); b[1] = g[1] = 1; for(n=2,len, g[n] = lcm(g[n-1],v[n]); b[n] = g[n]/g[n-1]); (b); };
    A030101(n) = if(n<1,0,subst(Polrev(binary(n)),x,2));
    A057889(n) = if(!n,n,A030101(n/(2^valuation(n,2))) * (2^valuation(n, 2)));
    v369044 = LCMtransform(vector(up_to,i,A057889(i)));
    A369044(n) = v369044[n];
    A014963(n) = { ispower(n, , &n); if(isprime(n), n, 1); };

Formula

a(n) = lcm {1..A057889(n)} / lcm {1..A057889(n-1)}.
a(n) = A014963(A057889(n)). [See comments.]
For n >= 1, Product_{d|n} a(A057889(d)) = n. [Implied by above.]

A245450 Self-inverse permutation of natural numbers, A245703-conjugate of balanced bit-reverse: a(n) = A245704(A057889(A245703(n))).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 13, 8, 9, 10, 19, 12, 7, 14, 15, 16, 53, 18, 11, 20, 21, 22, 23, 24, 25, 26, 27, 33, 41, 30, 113, 32, 28, 34, 35, 36, 47, 39, 38, 92, 29, 54, 163, 85, 45, 462, 37, 60, 49, 70, 51, 94, 17, 42, 55, 74, 57, 156, 193, 48, 101, 62, 115, 64, 259, 77, 73, 132, 69, 50, 181, 102, 67, 56, 169, 76, 66, 78, 137, 87, 180, 398, 139, 84, 44
Offset: 1

Views

Author

Antti Karttunen, Aug 07 2014

Keywords

Crossrefs

Programs

Formula

a(n) = A245704(A057889(A245703(n))).
Other identities. For all n >= 1, the following holds:
A010051(a(n)) = A010051(n). [Maps primes to primes and composites to composites].

A331166 a(n) = min(n, A057889(n)), where A057889 is bijective base-2 reverse.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 11, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 19, 22, 27, 28, 23, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 37, 42, 43, 44, 45, 46, 47, 48, 35, 38, 51, 44, 43, 54, 55, 56, 39, 46, 55, 60, 47, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 69, 74, 83, 84, 85, 86, 87, 88, 77, 90, 91, 92, 93, 94, 95, 96, 67, 70
Offset: 0

Views

Author

Antti Karttunen, Jan 12 2020

Keywords

Comments

There is a large number of sequences b, related to binary expansion of n (A007088), for which it holds that b(n) = b(a(n)) for all n >= 0 (or n >= 1). For example, we have:
For all i, j:
a(i) = a(j) => A002487(i) = A002487(j),
a(i) = a(j) => A005811(i) = A005811(j),
a(i) = a(j) => A286622(i) = A286622(j) => A000120(i) = A000120(j).
For all i, j > 0:
a(i) = a(j) => A007814(i) = A007814(j),
a(i) = a(j) => A280505(i) = A280505(j),
a(i) = a(j) => A305788(i) = A305788(j) => A091222(i) = A091222(j).

Crossrefs

Programs

Formula

a(n) = min(n, A057889(n)).

A366389 Variant of bijective bit-reverse of n (A057889) for which it holds that a(n) == n (mod 3).

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 26, 12, 22, 14, 15, 16, 17, 18, 25, 20, 21, 13, 29, 24, 19, 11, 27, 28, 23, 30, 31, 32, 33, 34, 98, 36, 82, 50, 57, 40, 74, 42, 106, 104, 45, 58, 122, 48, 70, 38, 51, 88, 86, 54, 118, 56, 39, 46, 110, 60, 94, 62, 63, 64, 65, 66, 97, 68, 81, 49, 113, 72, 73, 41, 105, 100, 89, 114, 121
Offset: 0

Views

Author

Antti Karttunen, Oct 22 2023

Keywords

Comments

Like A057889, also this is a self-inverse permutation of nonnegative integers.

Crossrefs

Cf. A010872, A030101, A057889, A073675, A366378, A366379, A366390 (Dirichlet inverse), A366392.
Cf. also A118967.

Programs

Formula

If A057889(n) == n mod 3, then a(n) = A057889(n), otherwise a(n) = A073675(A057889(n)) = A057889(A073675(n)).
For all n >= 0, A010872(a(n)) = A010872(n).

A302027 Permutation of nonnegative integers: a(0) = 0; for n >= 1, a(n) = A057889(1+A057889(n-1)), where A057889 is a bijective bit-reverse.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 13, 14, 11, 12, 15, 16, 17, 18, 25, 22, 21, 26, 27, 30, 19, 20, 29, 28, 23, 24, 31, 32, 33, 34, 49, 38, 41, 42, 51, 46, 37, 50, 53, 54, 43, 58, 55, 62, 35, 36, 57, 44, 45, 52, 59, 60, 39, 40, 61, 56, 47, 48, 63, 64, 65, 66, 97, 70, 81, 74, 99, 78, 73, 82, 101, 86, 83, 90, 103, 94, 69, 98, 105, 102, 85
Offset: 0

Views

Author

Antti Karttunen, Apr 26 2018

Keywords

Crossrefs

Cf. A302028 (inverse).
Cf. A057889.
Cf. also A268717, A302793.

Programs

  • Mathematica
    f[n_] := FromDigits[Reverse[IntegerDigits[n, 2]], 2]*2^IntegerExponent[n, 2]; Fold[Append[#1, f[1 + f[#2 - 1]]] &, {0, 1}, Range[2, 85]] (* Michael De Vlieger, Apr 27 2018, after Ivan Neretin at A057889 *)
  • PARI
    A030101(n) = if(n<1,0,subst(Polrev(binary(n)),x,2));
    A057889(n) = if(!n,n,A030101(n/(2^valuation(n,2))) * (2^valuation(n, 2)));
    A302027(n) = if(!n,n,A057889(1+A057889(n-1)));

Formula

a(0) = 0; for n >= 1, a(n) = A057889(1+A057889(n-1)).

A302028 Permutation of nonnegative integers: a(0) = 0; for n >= 1, a(n) = 1+A057889(A057889(n)-1), where A057889 is a bijective bit-reverse.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 13, 14, 11, 12, 15, 16, 17, 18, 25, 26, 21, 20, 29, 30, 19, 22, 23, 28, 27, 24, 31, 32, 33, 34, 49, 50, 41, 36, 57, 58, 37, 38, 45, 52, 53, 40, 61, 62, 35, 42, 39, 54, 43, 44, 47, 60, 51, 46, 55, 56, 59, 48, 63, 64, 65, 66, 97, 98, 81, 68, 113, 114, 73, 70, 89, 100, 105, 72, 121, 122, 69, 74, 77, 102, 85, 76
Offset: 0

Views

Author

Antti Karttunen, Apr 26 2018

Keywords

Crossrefs

Cf. A302027 (inverse).
Cf. A057889.
Cf. also A268718, A302794.

Programs

Formula

a(0) = 0; for n >= 1, a(n) = 1+A057889(A057889(n)-1).

A331300 Lexicographically earliest infinite sequence such that a(i) = a(j) => f(i) = f(j), where f(n) = min(n, A057889(n)), and A057889 is a bijective base-2 reverse.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 12, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 19, 22, 25, 26, 23, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 34, 38, 39, 40, 41, 42, 43, 44, 32, 35, 45, 40, 39, 46, 47, 48, 36, 42, 47, 49, 43, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 57, 62, 69, 70, 71, 72, 73, 74, 65, 75, 76, 77, 78, 79, 80, 81, 55, 58, 82, 64, 69, 83, 84, 74, 63
Offset: 0

Views

Author

Antti Karttunen, Jan 18 2020

Keywords

Comments

Restricted growth sequence transform of A331166. See comments in that sequence.

Crossrefs

Cf. also A324400, A331303, A305801, A305801, A305900, A295300 for other "top level" filtering sequences.

Programs

  • PARI
    up_to = 100000;
    rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om,invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om,invec[i],i); outvec[i] = u; u++ )); outvec; };
    A030101(n) = if(n<1,0,subst(Polrev(binary(n)),x,2));
    A057889(n) = if(!n,n,A030101(n/(2^valuation(n,2))) * (2^valuation(n, 2)));
    A331166(n) = min(n, A057889(n));
    v331300 = rgs_transform(vector(1+up_to,n,A331166(n-1)));
    A331300(n) = v331300[1+n];
    for(n=0,up_to,write("b331300.txt", n, " ", A331300(n)));

A356331 Bit-reverse the odd part of the negaFibonacci representation of n: a(n) = A356327(A057889(A215024(n))).

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 17, 10, 11, 12, 13, 14, 15, 19, 9, 18, 16, 20, 21, 51, 44, 24, 38, 26, 32, 28, 45, 46, 31, 27, 33, 34, 35, 36, 48, 25, 39, 40, 49, 53, 43, 23, 29, 30, 47, 37, 41, 50, 22, 52, 42, 54, 55, 140, 133, 58, 106, 115, 79, 62, 113, 127, 99
Offset: 0

Views

Author

Rémy Sigrist, Aug 04 2022

Keywords

Comments

This sequence is a self-inverse permutation of the nonnegative integers similar to A343150, A344682, A345201 and A356332.

Examples

			The first terms, alongside the corresponding negaFibonacci representations, are:
  n   a(n)  nega(n)  nega(a(n))
  --  ----  -------  ----------
   0     0        0           0
   1     1        1           1
   2     2      100         100
   3     3      101         101
   4     4    10010       10010
   5     5    10000       10000
   6     6    10001       10001
   7     7    10100       10100
   8     8    10101       10101
   9    17  1001010     1010010
  10    10  1001000     1001000
  11    11  1001001     1001001
  12    12  1000010     1000010
  13    13  1000000     1000000
  14    14  1000001     1000001
  15    15  1000100     1000100
  16    19  1000101     1010001
  17     9  1010010     1001010
  18    18  1010000     1010000
  19    16  1010001     1000101
  20    20  1010100     1010100
  21    21  1010101     1010101
		

Crossrefs

Programs

  • PARI
    See Links section.

Formula

a(a(n)) = n.
a(n) <= A000045(2*k) iff n <= A000045(2*k).

A366276 Permutation of nonnegative integers: a(n) = A057889(A243071(n)).

Original entry on oeis.org

0, 1, 3, 2, 7, 6, 15, 4, 5, 14, 31, 12, 63, 30, 11, 8, 127, 10, 255, 28, 23, 62, 511, 24, 13, 126, 9, 60, 1023, 22, 2047, 16, 47, 254, 27, 20, 4095, 510, 95, 56, 8191, 46, 16383, 124, 19, 1022, 32767, 48, 29, 26, 191, 252, 65535, 18, 55, 120, 383, 2046, 131071, 44, 262143, 4094, 39, 32, 111, 94, 524287, 508, 767, 54
Offset: 1

Views

Author

Antti Karttunen, Oct 06 2023

Keywords

Crossrefs

Cf. A057889, A243071, A366275 (inverse map), A366277 (fixed points of map n -> a(n)).

Programs

  • PARI
    A030101(n) = if(n<1,0,subst(Polrev(binary(n)),x,2));
    A057889(n) = if(!n,n,A030101(n/(2^valuation(n,2))) * (2^valuation(n, 2)));
    A243071(n) = if(n<=2, n-1, my(f=factor(n), p, p2=1, res=0); for(i=1, #f~, p = 1 << (primepi(f[i, 1]) - 1); res += (p*p2*(2^(f[i, 2]) - 1)); p2 <<= f[i, 2]); ((3<<#binary(res\2))-res-1)); \\ (Combining programs given in A156552 and A054429)
    A366276(n) = A057889(A243071(n));

A245453 Self-inverse and multiplicative permutation of natural numbers, A235041-conjugate of balanced bit-reverse: a(n) = A235042(A057889(A235041(n))).

Original entry on oeis.org

0, 1, 2, 3, 4, 19, 6, 7, 8, 9, 38, 13, 12, 11, 14, 57, 16, 59, 18, 5, 76, 21, 26, 53, 24, 361, 22, 27, 28, 109, 114, 31, 32, 39, 118, 133, 36, 41, 10, 33, 152, 37, 42, 103, 52, 171, 106, 61, 48, 49, 722, 177, 44, 23, 54, 247, 56, 15, 218, 17, 228, 47, 62, 63, 64
Offset: 0

Views

Author

Antti Karttunen, Aug 07 2014

Keywords

Comments

a(n) has the same prime signature as n: The permutation maps primes to primes, squares to squares, cubes to cubes, and so on. Permutation A234748 shares the same property.

Examples

			Example of multiplicativity:
a(5)=19, a(11)=13, a(55) = a(5*11) = a(5) * a(11) = 19*13 = 247.
		

Crossrefs

Programs

Formula

a(n) = A235042(A057889(A235041(n))).
Previous Showing 11-20 of 68 results. Next