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

A019565 The squarefree numbers ordered lexicographically by their prime factorization (with factors written in decreasing order). a(n) = Product_{k in I} prime(k+1), where I is the set of indices of nonzero binary digits in n = Sum_{k in I} 2^k.

Original entry on oeis.org

1, 2, 3, 6, 5, 10, 15, 30, 7, 14, 21, 42, 35, 70, 105, 210, 11, 22, 33, 66, 55, 110, 165, 330, 77, 154, 231, 462, 385, 770, 1155, 2310, 13, 26, 39, 78, 65, 130, 195, 390, 91, 182, 273, 546, 455, 910, 1365, 2730, 143, 286, 429, 858, 715, 1430, 2145, 4290
Offset: 0

Views

Author

Keywords

Comments

A permutation of the squarefree numbers A005117. The missing positive numbers are in A013929. - Alois P. Heinz, Sep 06 2014
From Antti Karttunen, Apr 18 & 19 2017: (Start)
Because a(n) toggles the parity of n there are neither fixed points nor any cycles of odd length.
Conjecture: there are no finite cycles of any length. My grounds for this conjecture: any finite cycle in this sequence, if such cycles exist at all, must have at least one member that occurs somewhere in A285319, the terms that seem already to be quite rare. Moreover, any such a number n should satisfy in addition to A019565(n) < n also that A048675^{k}(n) is squarefree, not just for k=0, 1 but for all k >= 0. As there is on average a probability of only 6/(Pi^2) = 0.6079... that any further term encountered on the trajectory of A048675 is squarefree, the total chance that all of them would be squarefree (which is required from the elements of A019565-cycles) is soon minuscule, especially as A048675 is not very tightly bounded (many trajectories seem to skyrocket, at least initially). I am also assuming that usually there is no significant correlation between the binary expansions of n and A048675(n) (apart from their least significant bits), or, for that matter, between their prime factorizations.
See also the slightly stronger conjecture in A285320, which implies that there would neither be any two-way infinite cycles.
If either of the conjectures is false (there are cycles), then certainly neither sequence A285332 nor its inverse A285331 can be a permutation of natural numbers. (End)
The conjecture made in A087207 (see also A288569) implies the two conjectures mentioned above. A further constraint for cycles is that in any A019565-trajectory which starts from a squarefree number (A005117), every other term is of the form 4k+2, while every other term is of the form 6k+3. - Antti Karttunen, Jun 18 2017
The sequence satisfies the exponential function identity, a(x + y) = a(x) * a(y), whenever x and y do not have a 1-bit in the same position, i.e., when A004198(x,y) = 0. See also A283475. - Antti Karttunen, Oct 31 2019
The above identity becomes unconditional if binary exclusive OR, A003987(.,.), is substituted for addition, and A059897(.,.), a multiplicative equivalent of A003987, is substituted for multiplication. This gives us a(A003987(x,y)) = A059897(a(x), a(y)). - Peter Munn, Nov 18 2019
Also the Heinz number of the binary indices of n, where the Heinz number of a sequence (y_1,...,y_k) is prime(y_1)*...*prime(y_k), and a number's binary indices (A048793) are the positions of 1's in its reversed binary expansion. - Gus Wiseman, Dec 28 2022

Examples

			5 = 2^2+2^0, e_1 = 2, e_2 = 0, prime(2+1) = prime(3) = 5, prime(0+1) = prime(1) = 2, so a(5) = 5*2 = 10.
From _Philippe Deléham_, Jun 03 2015: (Start)
This sequence regarded as a triangle withs rows of lengths 1, 1, 2, 4, 8, 16, ...:
   1;
   2;
   3,  6;
   5, 10, 15, 30;
   7, 14, 21, 42, 35,  70, 105, 210;
  11, 22, 33, 66, 55, 110, 165, 330, 77, 154, 231, 462, 385, 770, 1155, 2310;
  ...
(End)
From _Peter Munn_, Jun 14 2020: (Start)
The initial terms are shown below, equated with the product of their prime factors to exhibit the lexicographic order. We start with 1, since 1 is factored as the empty product and the empty list is first in lexicographic order.
   n     a(n)
   0     1 = .
   1     2 = 2.
   2     3 = 3.
   3     6 = 3*2.
   4     5 = 5.
   5    10 = 5*2.
   6    15 = 5*3.
   7    30 = 5*3*2.
   8     7 = 7.
   9    14 = 7*2.
  10    21 = 7*3.
  11    42 = 7*3*2.
  12    35 = 7*5.
(End)
		

Crossrefs

Row 1 of A285321.
Equivalent sequences for k-th-power-free numbers: A101278 (k=3), A101942 (k=4), A101943 (k=5), A054842 (k=10).
Cf. A109162 (iterates).
Cf. also A048675 (a left inverse), A087207, A097248, A260443, A054841.
Cf. A285315 (numbers for which a(n) < n), A285316 (for which a(n) > n).
Cf. A276076, A276086 (analogous sequences for factorial and primorial bases), A334110 (terms squared).
For partial sums see A288570.
A003961, A003987, A004198, A059897, A089913, A331590, A334747 are used to express relationships between sequence terms.
Column 1 of A329332.
Even bisection (which contains the odd terms): A332382.
A160102 composed with A052330, and subsequence of the latter.
Related to A000079 via A225546, to A057335 via A122111, to A008578 via A336322.
Least prime index of a(n) is A001511.
Greatest prime index of a(n) is A029837 or A070939.
Taking prime indices gives A048793, reverse A272020, row sums A029931.
A112798 lists prime indices, length A001222, sum A056239.

Programs

  • Haskell
    a019565 n = product $ zipWith (^) a000040_list (a030308_row n)
    -- Reinhard Zumkeller, Apr 27 2013
    
  • Maple
    a:= proc(n) local i, m, r; m:=n; r:=1;
          for i while m>0 do if irem(m,2,'m')=1
            then r:=r*ithprime(i) fi od; r
        end:
    seq(a(n), n=0..60);  # Alois P. Heinz, Sep 06 2014
  • Mathematica
    Do[m=1;o=1;k1=k;While[ k1>0, k2=Mod[k1, 2];If[k2\[Equal]1, m=m*Prime[o]];k1=(k1-k2)/ 2;o=o+1];Print[m], {k, 0, 55}] (* Lei Zhou, Feb 15 2005 *)
    Table[Times @@ Prime@ Flatten@ Position[#, 1] &@ Reverse@ IntegerDigits[n, 2], {n, 0, 55}]  (* Michael De Vlieger, Aug 27 2016 *)
    b[0] := {1}; b[n_] := Flatten[{ b[n - 1], b[n - 1] * Prime[n] }];
      a = b[6] (* Fred Daniel Kline, Jun 26 2017 *)
  • PARI
    a(n)=factorback(vecextract(primes(logint(n+!n,2)+1),n))  \\ M. F. Hasler, Mar 26 2011, updated Aug 22 2014, updated Mar 01 2018
    
  • Python
    from operator import mul
    from functools import reduce
    from sympy import prime
    def A019565(n):
        return reduce(mul,(prime(i+1) for i,v in enumerate(bin(n)[:1:-1]) if v == '1')) if n > 0 else 1
    # Chai Wah Wu, Dec 25 2014
    
  • Scheme
    (define (A019565 n) (let loop ((n n) (i 1) (p 1)) (cond ((zero? n) p) ((odd? n) (loop (/ (- n 1) 2) (+ 1 i) (* p (A000040 i)))) (else (loop (/ n 2) (+ 1 i) p))))) ;; (Requires only the implementation of A000040 for prime numbers.) - Antti Karttunen, Apr 20 2017

Formula

G.f.: Product_{k>=0} (1 + prime(k+1)*x^2^k), where prime(k)=A000040(k). - Ralf Stephan, Jun 20 2003
a(n) = f(n, 1, 1) with f(x, y, z) = if x > 0 then f(floor(x/2), y*prime(z)^(x mod 2), z+1) else y. - Reinhard Zumkeller, Mar 13 2010
For all n >= 0: A048675(a(n)) = n; A013928(a(n)) = A064273(n). - Antti Karttunen, Jul 29 2015
a(n) = a(2^x)*a(2^y)*a(2^z)*... = prime(x+1)*prime(y+1)*prime(z+1)*..., where n = 2^x + 2^y + 2^z + ... - Benedict W. J. Irwin, Jul 24 2016
From Antti Karttunen, Apr 18 2017 and Jun 18 2017: (Start)
a(n) = A097248(A260443(n)), a(A005187(n)) = A283475(n), A108951(a(n)) = A283477(n).
A055396(a(n)) = A001511(n), a(A087207(n)) = A007947(n). (End)
a(2^n - 1) = A002110(n). - Michael De Vlieger, Jul 05 2017
a(n) = A225546(A000079(n)). - Peter Munn, Oct 31 2019
From Peter Munn, Mar 04 2022: (Start)
a(2n) = A003961(a(n)); a(2n+1) = 2*a(2n).
a(x XOR y) = A059897(a(x), a(y)) = A089913(a(x), a(y)), where XOR denotes bitwise exclusive OR (A003987).
a(n+1) = A334747(a(n)).
a(x+y) = A331590(a(x), a(y)).
a(n) = A336322(A008578(n+1)).
(End)

Extensions

Definition corrected by Klaus-R. Löffler, Aug 20 2014
New name from Peter Munn, Jun 14 2020

A329332 Table of powers of squarefree numbers, powers of A019565(n) in increasing order in row n. Square array A(n,k) n >= 0, k >= 0 read by descending antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 4, 3, 1, 1, 8, 9, 6, 1, 1, 16, 27, 36, 5, 1, 1, 32, 81, 216, 25, 10, 1, 1, 64, 243, 1296, 125, 100, 15, 1, 1, 128, 729, 7776, 625, 1000, 225, 30, 1, 1, 256, 2187, 46656, 3125, 10000, 3375, 900, 7, 1, 1, 512, 6561, 279936, 15625, 100000, 50625, 27000, 49, 14
Offset: 0

Views

Author

Peter Munn, Nov 10 2019

Keywords

Comments

The A019565 row order gives the table neat relationships with A003961, A003987, A059897, A225546, A319075 and A329050. See the formula section.
Transposition of this table, that is reflection about its main diagonal, has subtle symmetries. For example, consider the unique factorization of a number into powers of distinct primes. This can be restated as factorization into numbers from rows 2^n (n >= 0) with no more than one from each row. Reflecting about the main diagonal, this factorization becomes factorization (of a related number) into numbers from columns 2^k (k >= 0) with no more than one from each column. This is also unique and is factorization into powers of squarefree numbers with distinct exponents that are powers of two. See the example section.

Examples

			Square array A(n,k) begins:
n\k |  0   1     2      3        4          5           6             7
----+------------------------------------------------------------------
   0|  1   1     1      1        1          1           1             1
   1|  1   2     4      8       16         32          64           128
   2|  1   3     9     27       81        243         729          2187
   3|  1   6    36    216     1296       7776       46656        279936
   4|  1   5    25    125      625       3125       15625         78125
   5|  1  10   100   1000    10000     100000     1000000      10000000
   6|  1  15   225   3375    50625     759375    11390625     170859375
   7|  1  30   900  27000   810000   24300000   729000000   21870000000
   8|  1   7    49    343     2401      16807      117649        823543
   9|  1  14   196   2744    38416     537824     7529536     105413504
  10|  1  21   441   9261   194481    4084101    85766121    1801088541
  11|  1  42  1764  74088  3111696  130691232  5489031744  230539333248
  12|  1  35  1225  42875  1500625   52521875  1838265625   64339296875
Reflection of factorization about the main diagonal: (Start)
The canonical (prime power) factorization of 864 is 2^5 * 3^3 = 32 * 27. Reflecting the factors about the main diagonal of the table gives us 10 * 36 = 10^1 * 6^2 = 360. This is the unique factorization of 360 into powers of squarefree numbers with distinct exponents that are powers of two.
Reflection about the main diagonal is given by the self-inverse function A225546(.). Clearly, all positive integers are in the domain of A225546, whether or not they appear in the table. It is valid to start from 360, observe that A225546(360) = 864, then use 864 to derive 360's factorization into appropriate powers of squarefree numbers as above.
(End)
		

Crossrefs

The range of values is A072774.
Rows (abbreviated list): A000079(1), A000244(2), A000400(3), A000351(4), A011557(5), A001024(6), A009974(7), A000420(8), A001023(9), A009965(10), A001020(16), A001022(32), A001026(64).
A019565 is column 1, A334110 is column 2, and columns that are sorted in increasing order (some without the 1) are: A005117(1), A062503(2), A062838(3), A113849(4), A113850(5), A113851(6), A113852(7).
Other subtables: A182944, A319075, A329050.
Re-ordered subtable of A297845, A306697, A329329.
A000290, A003961, A003987, A059897 and A225546 are used to express relationships between terms of this sequence.
Cf. A285322.

Formula

A(n,k) = A019565(n)^k.
A(k,n) = A225546(A(n,k)).
A(n,2k) = A000290(A(n,k)) = A(n,k)^2.
A(2n,k) = A003961(A(n,k)).
A(n,2k+1) = A(n,2k) * A(n,1).
A(2n+1,k) = A(2n,k) * A(1,k).
A(A003987(n,m), k) = A059897(A(n,k), A(m,k)).
A(n, A003987(m,k)) = A059897(A(n,m), A(n,k)).
A(2^n,k) = A319075(k,n+1).
A(2^n, 2^k) = A329050(n,k).
A(n,k) = A297845(A(n,1), A(1,k)) = A306697(A(n,1), A(1,k)), = A329329(A(n,1), A(1,k)).
Sum_{n>=0} 1/A(n,k) = zeta(k)/zeta(2*k), for k >= 2. - Amiram Eldar, Dec 03 2022

A334866 a(0) = 1, and then after, a(2n) = a(n)^2, a(2n+1) = A334747(a(n)).

Original entry on oeis.org

1, 2, 4, 3, 16, 8, 9, 6, 256, 32, 64, 12, 81, 18, 36, 5, 65536, 512, 1024, 48, 4096, 128, 144, 24, 6561, 162, 324, 27, 1296, 72, 25, 10, 4294967296, 131072, 262144, 768, 1048576, 2048, 2304, 96, 16777216, 8192, 16384, 192, 20736, 288, 576, 20, 43046721, 13122, 26244, 243, 104976, 648, 729, 54, 1679616, 2592, 5184, 108, 625, 50, 100, 15
Offset: 0

Views

Author

Antti Karttunen, Jun 08 2020

Keywords

Comments

This irregular table can be represented as a binary tree. Each child to the left is obtained by squaring the parent, and each child to the right is obtained by applying A334747 to the parent:
1
|
...................2...................
4 3
16......../ \........8 9......../ \........6
/ \ / \ / \ / \
/ \ / \ / \ / \
/ \ / \ / \ / \
256 32 64 12 81 18 36 5
65536 512 1024 48 4096 128 144 24 6561 162 324 27 1296 72 25 10
etc.
This is the mirror image of the tree in A334860.

Crossrefs

Cf. A334865 (inverse permutation), A334860 (mirror image).
Composition of permutations A005940 and A225546.
Cf. A001146 (left edge of the tree), A019565 (right edge), A334110 (the left children of the right edge).

Programs

Formula

a(0) = 1, and then after, a(2n) = a(n)^2, a(2n+1) = A334747(a(n)).
a(n) = A225546(A005940(1+n)).
For all n >= 0, A048675(a(n)) = A087808(n).

A334860 a(0) = 1, a(1) = 2, after which, a(2n) = A334747(a(n)), a(2n+1) = a(n)^2.

Original entry on oeis.org

1, 2, 3, 4, 6, 9, 8, 16, 5, 36, 18, 81, 12, 64, 32, 256, 10, 25, 72, 1296, 27, 324, 162, 6561, 24, 144, 128, 4096, 48, 1024, 512, 65536, 15, 100, 50, 625, 108, 5184, 2592, 1679616, 54, 729, 648, 104976, 243, 26244, 13122, 43046721, 20, 576, 288, 20736, 192, 16384, 8192, 16777216, 96, 2304, 2048, 1048576, 768, 262144, 131072, 4294967296, 30
Offset: 0

Views

Author

Antti Karttunen, Jun 08 2020

Keywords

Comments

This irregular table can be represented as a binary tree. Each child to the left is obtained by applying A334747 to the parent, and each child to the right is obtained by squaring the parent:
1
|
...................2...................
3 4
6......../ \........9 8......../ \........16
/ \ / \ / \ / \
/ \ / \ / \ / \
/ \ / \ / \ / \
5 36 18 81 12 64 32 256
10 25 72 1296 27 324 162 6561 24 144 128 4096 48 1024 512 65536
etc.
This is the mirror image of the tree in A334866.
Fermi-Dirac primes, A050376, occur at rightward growing branches that originate from primes situated at the left edge.
The tree illustrated in A163511 is expanded as x -> 2*x for the left child and x -> A003961(x) for the right child, while this tree is expanded as x -> A225546(2*A225546(x)) for the left child, and x -> A225546(A003961(A225546(x))) for the right child.

Crossrefs

Cf. A000290, A225546, A334204, A334747, A334859 (inverse), A334866 (mirror image).
Cf. A001146 (right edge of the tree), A019565 (left edge), A334110 (the right children of the left edge).
Composition of permutations A163511 and A225546.

Programs

Formula

a(0) = 1, a(1) = 2; and for n > 0, a(2n) = A334747(a(n)), a(2n+1) = a(n)^2.
a(n) = A225546(A163511(n)).
For n >= 0, a(2^n) = A019565(1+n), a(2^((2^n)-1)) = A000040(1+n).
A334109(a(n)) = A334204(n).
It seems that for n >= 1, A048675(a(n)) = A135529(n) = A048675(A163511(n)).

A334109 a(n) = A329697(A225546(n)).

Original entry on oeis.org

0, 0, 0, 1, 0, 0, 0, 1, 2, 0, 0, 1, 0, 0, 0, 1, 0, 2, 0, 1, 0, 0, 0, 1, 4, 0, 2, 1, 0, 0, 0, 1, 0, 0, 0, 3, 0, 0, 0, 1, 0, 0, 0, 1, 2, 0, 0, 1, 8, 4, 0, 1, 0, 2, 0, 1, 0, 0, 0, 1, 0, 0, 2, 2, 0, 0, 0, 1, 0, 0, 0, 3, 0, 0, 4, 1, 0, 0, 0, 1, 2, 0, 0, 1, 0, 0, 0, 1, 0, 2, 0, 1, 0, 0, 0, 1, 0, 8, 2, 5, 0, 0, 0, 1, 0
Offset: 1

Views

Author

Antti Karttunen, Apr 29 2020

Keywords

Comments

Conjecture: Each k >= 0 occurs for the first time at A334110(k) = A019565(k)^2. Note that each k must occur first time on square n, because of the identity a(n) = a(A008833(n)). However, is there any reason to exclude squares with prime exponents > 2 from the candidates? See also comments in A334204.

Crossrefs

Programs

  • Mathematica
    Map[-1 + Length@ NestWhileList[# - #/FactorInteger[#][[-1, 1]] &, #, # != 2^IntegerExponent[#, 2] &] &, Array[If[# == 1, 1, Times @@ Flatten@ Map[Function[{p, e}, Map[Prime[Log2@ # + 1]^(2^(PrimePi@ p - 1)) &, DeleteCases[NumberExpand[e, 2], 0]]] @@ # &, FactorInteger[#]]] &, 105] ] (* Michael De Vlieger, May 26 2020 *)
  • PARI
    A019565(n) = factorback(vecextract(primes(logint(n+!n, 2)+1), n));
    A329697(n) = if(!bitand(n,n-1),0,1+A329697(n-(n/vecmax(factor(n)[, 1]))));
    A334109(n) = { my(f=factor(n),pis=apply(primepi,f[,1]),es=f[,2]); sum(k=1,#f~,(2^(pis[k]-1))*A329697(A019565(es[k]))); };

Formula

Additive with a(prime(i)^j) = A000079(i-1) * A329697(A019565(j)), a(m*n) = a(m)+a(n) if gcd(m,n) = 1.
Alternatively, additive with a(prime(i)^(2^k)) = 2^(i-1) * A329697(prime(k+1)), a(m*n) = a(m)+a(n) if A059895(m,n) = 1. - Peter Munn, May 04 2020
a(n) = A329697(A225546(n)) = A329697(A331736(n)).
a(n) = a(A008833(n)).
For all n >= 0, a(A334110(n)) = n, a(A334860(n)) = A334204(n).
a(A331590(m,k)) = a(m) + a(k); a(A003961(n)) = 2*a(n). - Peter Munn, Apr 30 2020

A336322 a(n) = A225546(A122111(n)).

Original entry on oeis.org

1, 2, 3, 4, 6, 8, 5, 16, 9, 12, 10, 32, 15, 24, 18, 256, 30, 64, 7, 48, 27, 20, 14, 512, 36, 40, 81, 96, 21, 128, 42, 65536, 54, 60, 72, 1024, 35, 120, 45, 768, 70, 192, 105, 80, 162, 28, 210, 131072, 25, 144, 90, 160, 11, 4096, 108, 1536, 135, 56, 22, 2048, 33, 84, 243, 4294967296, 216, 384, 66, 240, 270, 288, 55, 262144, 110, 168, 324, 480, 50
Offset: 1

Views

Author

Antti Karttunen and Peter Munn, Jul 17 2020

Keywords

Comments

A225546 and A122111 are both self-inverse permutations of the positive integers based on prime factorizations, and they share further common properties. For instance, they map the prime numbers to powers of 2: A225546 maps the k-th prime to 2^2^(k-1), whereas A122111 maps it to 2^k.
In composing these permutations, this sequence maps the list of prime numbers to the squarefree numbers, as listed in A019565; and the "normal" numbers (A055932), as listed in A057335, to ascending powers of 2.

Crossrefs

A225546 composed with A122111.
Sorted even bisection: A335738.
Sorted odd bisection (excluding 1): A335740.
Sequences used to express relationship between terms of this sequence: A001222, A003961, A253560, A331590, A350066.
Sequences of sequences (S_1, S_2, ... S_j) with the property a(S_i) = S_{i+1}, or essentially so: (A033844, A000040, A019565), (A057335, A000079, A001146), (A000244, A011764), (A001248, A334110), (A253563, A334866).
The inverse permutation, A336321, lists sequences where the property is weaker (between the sets of terms).

Formula

a(A033844(m)) = A000040(m+1). [Offset corrected Peter Munn, Feb 14 2022]
a(A000040(m)) = A019565(m).
a(A057335(m)) = 2^m.
For m >= 1, a(2^m) = A001146(m-1).
a(A253563(m)) = A334866(m).
From Peter Munn, Feb 14 2022: (Start)
a(A253560(n)) = a(n)^2.
For n >= 2, a(A003961(n)) = A331590(a(n), 2^2^(A001222(n)-1)).
a(A350066(n, k)) = A331590(a(n), a(k)).
(End)
Showing 1-6 of 6 results.