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-16 of 16 results.

A304085 Divisor-or-multiple permutation of natural numbers: a(n) = A052330(A304083(n)).

Original entry on oeis.org

1, 2, 6, 3, 24, 12, 4, 8, 120, 60, 20, 5, 40, 10, 30, 15, 840, 420, 140, 35, 7, 280, 70, 14, 210, 105, 21, 168, 84, 28, 56, 7560, 42, 1890, 945, 315, 63, 9, 3780, 1260, 252, 36, 2520, 630, 126, 18, 1512, 756, 189, 27, 378, 54, 1080, 540, 180, 45, 360, 90, 270, 135, 83160, 504, 72, 216, 108, 41580, 13860, 3465, 693, 99, 11, 27720, 6930, 1386, 198, 22, 20790
Offset: 0

Views

Author

Antti Karttunen, May 06 2018

Keywords

Comments

Each a(n) is always either a divisor or a multiple of a(n+1).

Crossrefs

Cf. A304086 (inverse).
Cf. also A064736, A113552, A207901, A281978, A282291, A302350, A302781, A302783, A303751, A303771 for similar permutations.

Programs

  • PARI
    up_to_e = 16; \\ Good for computing up to n = (2^16)-1
    v050376 = vector(up_to_e);
    ispow2(n) = (n && !bitand(n,n-1));
    i = 0; for(n=1,oo,if(ispow2(isprimepower(n)), i++; v050376[i] = n); if(i == up_to_e,break));
    A050376(n) = v050376[n];
    A052330(n) = { my(p=1,i=1); while(n>0, if(n%2, p *= A050376(i)); i++; n >>= 1); (p); };
    A304085(n) = A052330(A304083(n)); \\ Needs also code from A304083

Formula

a(n) = A052330(A304083(n)).

A302844 Permutation of nonnegative integers: a(n) = A003188(A163356(n)).

Original entry on oeis.org

0, 1, 2, 3, 12, 15, 14, 13, 10, 9, 8, 11, 4, 5, 6, 7, 24, 27, 26, 25, 30, 31, 28, 29, 18, 19, 16, 17, 22, 21, 20, 23, 40, 43, 42, 41, 46, 47, 44, 45, 34, 35, 32, 33, 38, 37, 36, 39, 56, 57, 58, 59, 52, 55, 54, 53, 50, 49, 48, 51, 60, 61, 62, 63, 192, 195, 194, 193, 198, 199, 196, 197, 202, 203, 200, 201, 206, 205
Offset: 0

Views

Author

Antti Karttunen, Apr 14 2018

Keywords

Comments

When A207901, which is a multiplicative walk permutation, is composed from the right with this permutation, the result is A302781, another multiplicative walk permutation.

Crossrefs

Programs

Formula

a(n) = A003188(A163356(n)).
a(n) = A006068(A302846(n)).

A304537 Suspected divisor-or-multiple permutation of squarefree numbers: a(n) = A019565(A304533(n)).

Original entry on oeis.org

1, 2, 6, 3, 15, 5, 65, 13, 26, 182, 7, 14, 42, 21, 105, 35, 455, 91, 910, 10, 30, 210, 70, 2730, 39, 78, 546, 273, 1365, 195, 7995, 41, 82, 246, 123, 615, 205, 2665, 533, 1066, 11726, 11, 22, 66, 33, 165, 55, 715, 143, 286, 2002, 77, 154, 462, 231, 1155, 385, 5005, 1001, 10010, 110, 330, 2310, 770, 30030, 429, 858, 6006, 3003, 15015, 2145, 87945, 451, 902
Offset: 0

Views

Author

Antti Karttunen, May 15 2018

Keywords

Comments

Each a(n) is always either a divisor or a multiple of a(n+1).
Consider A052330. Imagine that it is an automatic piano that "plays sequences" when an appropriate punched "tape" is fed to it (as its input), i.e., when it is composed from the right with an appropriate sequence p, as A019565(p(n)). The 1-bits in the binary expansion of each p(n) are the "holes" in the tape, and they determine which "tunes" are present on beat n. The "tunes" are actually "Fermi-Dirac primes" (A050376) that are multiplied together.
If the tape is constructed in such a way that between the successive beats (when moving from p(n) to p(n+1)), either a subset of 0-bits are toggled on (changed to 1's), or a subset of 1-bits are toggled off (changed to 0's), but no both kind of changes occur simultaneously, then when fed as an input to this piano, the resulting sequence "s" (the output) is guaranteed to satisfy the condition that s(n+1) is either a multiple or a divisor of s(n). Furthermore, if the given sequence p is itself a permutation of natural numbers, then also the produced sequence is. For example, Gray code A003188 and its inverse A006068 are such sequences, and when given as an "input tape" for A052330, they produce permutations A207901 and A302783.
There is a simpler instrument, called "squarefree piano" (A019565), with which it is possible to produce similar divisor-or-multiple sequences, but that contain only squarefree numbers. Given A003188 or A006068 as an input tape for it produces correspondingly sequences A302033 and A284003.
This sequence is obtained by playing "squarefree piano" with the same tape which yields A304531 when "Fermi-Dirac piano" is played with it. However, in this case the sequence A304531 is produced by a greedy algorithm, and thus its tape (A304533) is actually a back-formation, obtained from the "music" (A304531) by applying "tape-recorder" (A052331) to it. Note that this in not a subsequence of A304531, as the terms occur in different order than the squarefree terms of A304531.
See also Peter Munn's Apr 11 2018 message on SeqFan-mailing list.

Crossrefs

Programs

Formula

a(n) = A019565(A304533(n)) = A019565(A052331(A304531(1+n))).

A322017 a(0) = 0; for n > 0, if A003188(n) > A003188(n-1) then a(n) = n-1, else if A003188(n+1) < A003188(n) then a(n) = n+1, otherwise a(n) = 0.

Original entry on oeis.org

0, 0, 1, 0, 3, 4, 7, 0, 7, 8, 9, 12, 0, 12, 15, 0, 15, 16, 17, 0, 19, 20, 23, 24, 0, 24, 25, 28, 0, 28, 31, 0, 31, 32, 33, 0, 35, 36, 39, 0, 39, 40, 41, 44, 0, 44, 47, 48, 0, 48, 49, 0, 51, 52, 55, 56, 0, 56, 57, 60, 0, 60, 63, 0, 63, 64, 65, 0, 67, 68, 71, 0, 71, 72, 73, 76, 0, 76, 79, 0, 79, 80, 81, 0, 83, 84, 87, 88, 0, 88, 89
Offset: 0

Views

Author

Antti Karttunen, Nov 24 2018

Keywords

Comments

For all n, A207901(a(n)) divides A207901(n), and similarly for A302033.

Crossrefs

Programs

  • Mathematica
    g[n_] := BitXor[n, Floor[n/2]]; a[n_] := If[n == 0, 0, If[g[n] > g[n-1],  n-1, If[g[n+1] < g[n], n+1, 0]]]; Array[a, 100, 0] (* Amiram Eldar, Dec 05 2018 *)
  • PARI
    A003188(n) = bitxor(n, n>>1);
    A322017(n) = if(0==n, 0, if(A003188(n)>A003188(n-1), n-1, if(A003188(1+n) < A003188(n), n+1, 0)));

A302030 a(n) = 1+A006068(A052331(n)).

Original entry on oeis.org

1, 2, 4, 8, 16, 3, 32, 7, 64, 15, 128, 5, 256, 31, 13, 512, 1024, 63, 2048, 9, 29, 127, 4096, 6, 8192, 255, 61, 25, 16384, 14, 32768, 511, 125, 1023, 17, 57, 65536, 2047, 253, 10, 131072, 30, 262144, 121, 49, 4095, 524288, 509, 1048576, 8191, 1021, 249, 2097152, 62, 113, 26, 2045, 16383, 4194304, 12, 8388608, 32767, 33, 505, 241, 126
Offset: 1

Views

Author

Antti Karttunen, Apr 13 2018

Keywords

Comments

This is the inverse of A207901 if it is considered with a starting offset 1.

Crossrefs

One more than A302029.

Programs

  • PARI
    up_to_e = 8192;
    v050376 = vector(up_to_e);
    ispow2(n) = (n && !bitand(n,n-1));
    i = 0; for(n=1,oo,if(ispow2(isprimepower(n)), i++; v050376[i] = n); if(i == up_to_e,break));
    A052331(n) = { my(s=0,e); while(n > 1, fordiv(n, d, if(((n/d)>1)&&ispow2(isprimepower(n/d)), e = vecsearch(v050376, n/d); if(!e, print("v050376 too short!"); return(1/0)); s += 2^(e-1); n = d; break))); (s); };
    A006068(n)= { my(s=1, ns); while(1, ns = n >> s; if(0==ns, break()); n = bitxor(n, ns); s <<= 1; ); return (n); } \\ After code in A006068
    A302030(n) = (1+A006068(A052331(n)));

Formula

a(n) = 1+A302029(n) = 1+A006068(A052331(n)).

A322018 a(n) = A006068(A129760(A003188(n))).

Original entry on oeis.org

0, 0, 3, 0, 7, 4, 7, 0, 15, 8, 11, 8, 15, 12, 15, 0, 31, 16, 19, 16, 23, 20, 23, 16, 31, 24, 27, 24, 31, 28, 31, 0, 63, 32, 35, 32, 39, 36, 39, 32, 47, 40, 43, 40, 47, 44, 47, 32, 63, 48, 51, 48, 55, 52, 55, 48, 63, 56, 59, 56, 63, 60, 63, 0, 127, 64, 67, 64, 71, 68, 71, 64, 79, 72, 75, 72, 79, 76, 79, 64, 95, 80, 83, 80, 87, 84, 87, 80
Offset: 0

Views

Author

Antti Karttunen, Nov 27 2018

Keywords

Comments

For all n, A207901(a(n)) divides A207901(n), and similarly for A302033.

Crossrefs

Programs

Formula

a(n) = A006068(A129760(A003188(n))).
Previous Showing 11-16 of 16 results.