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.

A332995 a(n) = A332895(A332817(n)).

Original entry on oeis.org

0, 1, 2, 2, 4, 5, 4, 5, 8, 8, 10, 11, 8, 8, 10, 10, 16, 17, 16, 17, 20, 20, 22, 23, 16, 17, 16, 16, 20, 21, 20, 21, 32, 32, 34, 35, 32, 32, 34, 34, 40, 41, 40, 41, 44, 44, 46, 47, 32, 32, 34, 34, 32, 33, 32, 32, 40, 40, 42, 43, 40, 40, 42, 42, 64, 65, 64, 65, 68, 68, 70, 71, 64, 65, 64, 64, 68, 69, 68, 69, 80, 80, 82, 83, 80, 80, 82, 82, 88, 89, 88, 89, 92
Offset: 0

Views

Author

Antti Karttunen, Mar 05 2020

Keywords

Comments

In contrast to similarly constructed A292271, this sequence can be computed directly from the binary expansion of n, without involving primes or their distribution at all.

Crossrefs

Differs from a similarly constructed A292593 for the first time at n=511, where a(511) = 341, while A292593(511) = 340.

Programs

Formula

a(n) = A332895(A332817(n)).
a(n) = n - A332996(n) = n XOR A332996(n).
A000120(a(n)) = A332997(n).

A332896 a(1) = 0, and for n > 1, a(n) = 2*a(A332893(n)) + [n == 3 (mod 4)].

Original entry on oeis.org

0, 0, 1, 0, 2, 2, 5, 0, 0, 4, 21, 4, 10, 10, 5, 0, 42, 0, 85, 8, 8, 42, 341, 8, 0, 20, 1, 20, 170, 10, 1365, 0, 40, 84, 11, 0, 682, 170, 21, 16, 2730, 16, 5461, 84, 8, 682, 21845, 16, 0, 0, 85, 40, 10922, 2, 43, 40, 168, 340, 87381, 20, 43690, 2730, 17, 0, 16, 80, 349525, 168, 680, 22, 1398101, 0, 174762, 1364, 1, 340, 32, 42, 5592405, 32, 0, 5460
Offset: 1

Views

Author

Antti Karttunen, Mar 04 2020

Keywords

Comments

Base-2 expansion of a(n) encodes the steps where numbers of the form 4k+3 are encountered when map x -> A332893(x) is iterated down to 1, starting from x=n. See the binary tree illustrated in A332815.

Crossrefs

Programs

Formula

a(1) = 0, and for n > 1, a(n) = 2*a(A332893(n)) + [n == 3 (mod 4)].
Other identities. For n >= 1:
a(2n) = 2*a(n).
a(A108546(n)) = A000975(n-1).

A332897 a(1) = 0, a(2) = 1, and for n > 2, a(n) = a(A332893(n)) + [n == 1 (mod 4)].

Original entry on oeis.org

0, 1, 1, 1, 2, 1, 2, 1, 2, 2, 3, 1, 3, 2, 1, 1, 4, 2, 4, 2, 3, 3, 5, 1, 3, 3, 1, 2, 5, 1, 6, 1, 4, 4, 1, 2, 6, 4, 2, 2, 7, 3, 7, 3, 2, 5, 8, 1, 4, 3, 3, 3, 8, 1, 2, 2, 5, 5, 9, 1, 9, 6, 2, 1, 4, 4, 10, 4, 6, 1, 11, 2, 10, 6, 2, 4, 5, 2, 12, 2, 2, 7, 13, 3, 5, 7, 4, 3, 11, 2, 1, 5, 7, 8, 3, 1, 12, 4, 3, 3, 13, 3, 14, 3, 2
Offset: 1

Views

Author

Antti Karttunen, Mar 04 2020

Keywords

Comments

Starting from x=n, iterate the map x -> A332893(x) which divides even numbers by 2, and for odd n changes every 4k+1 prime in their prime factorization to 4k+3 prime and vice versa (except 3 -> 2), like in A332819. a(n) counts the numbers of the form 4k+1 encountered until 1 has been reached, which is also included in the count when n > 1. This count includes also n itself when it is of the form 4k+1 (A016813) and larger than 1.

Crossrefs

Programs

Formula

a(1) = 0, a(2) = 1, and for n > 2, a(n) = a(A332893(n)) + [n == 1 (mod 4)].
a(n) = A000120(A332895(n)).

A332811 a(n) = A243071(A332808(n)).

Original entry on oeis.org

0, 1, 3, 2, 7, 6, 15, 4, 5, 14, 63, 12, 31, 30, 13, 8, 127, 10, 255, 28, 29, 126, 1023, 24, 11, 62, 9, 60, 511, 26, 4095, 16, 125, 254, 27, 20, 2047, 510, 61, 56, 8191, 58, 16383, 252, 25, 2046, 65535, 48, 23, 22, 253, 124, 32767, 18, 123, 120, 509, 1022, 262143, 52, 131071, 8190, 57, 32, 59, 250, 1048575, 508, 2045, 54, 4194303, 40, 524287, 4094, 21
Offset: 1

Views

Author

Antti Karttunen, Mar 05 2020

Keywords

Crossrefs

Cf. A332817 (inverse permutation).
Cf. also A332215.

Programs

  • PARI
    up_to = 26927;
    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)};
    A243071(n) = if(n<=2, n-1, if(!(n%2), 2*A243071(n/2), 1+(2*A243071(A064989(n)))));
    A332806list(up_to) = { my(v=vector(2), xs=Map(), lista=List([]), p,q,u); v[2] = 3; v[1] = 5; mapput(xs,1,1); mapput(xs,2,2); mapput(xs,3,3);  for(n=4,up_to, p = v[2-(n%2)]; q = nextprime(1+p); while(q%4 != p%4, q=nextprime(1+q)); v[2-(n%2)] = q; mapput(xs,primepi(q),n)); for(i=1, oo, if(!mapisdefined(xs, i, &u), return(Vec(lista)), listput(lista, prime(u)))); };
    v332806 = A332806list(up_to);
    A332806(n) = v332806[n];
    A332808(n) = { my(f=factor(n)); f[,1] = apply(A332806,apply(primepi,f[,1])); factorback(f); };
    A332811(n) = A243071(A332808(n));

Formula

a(n) = A243071(A332808(n)).
For n > 1, a(n) = A054429(A332816(n)).
a(n) = A332895(n) + A332896(n).
a(n) = A332895(n) OR A332896(n) = A332895(n) XOR A332896(n).
A000120(a(n)) = A332899(n).
Showing 1-4 of 4 results.