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-10 of 17 results. Next

A285715 a(n) = A000120(A245611(n)).

Original entry on oeis.org

0, 1, 2, 3, 1, 4, 5, 2, 6, 7, 3, 8, 2, 1, 9, 10, 4, 3, 11, 5, 12, 13, 2, 14, 3, 6, 15, 4, 7, 16, 17, 3, 5, 18, 8, 19, 20, 2, 4, 21, 1, 22, 6, 9, 23, 5, 10, 7, 24, 4, 25, 26, 3, 27, 28, 11, 29, 8, 5, 6, 4, 12, 2, 30, 13, 31, 7, 2, 32, 33, 14, 5, 9, 3, 34, 35, 6, 10, 36, 15, 8, 37, 4, 38, 5, 7, 39, 3, 16, 40, 41, 17, 11, 6, 3, 42, 43, 5, 44, 45, 18, 9, 12, 8, 7
Offset: 1

Views

Author

Antti Karttunen, Apr 25 2017

Keywords

Crossrefs

Cf. A007051 (positions of 0 and 1's).

Programs

Formula

a(1) = 0, a(2) = 1, for n > 2, a(n) = a(A285712(n)) + [n <> 2 mod 3]. (Where [] is Iverson bracket, giving here 1 if n is of the form 3k or 3k+1, and 0 if it is of the form 3k+2.)
a(n) = A000120(A245611(n)).

A285716 a(n) = A080791(A245611(n)).

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 1, 2, 0, 0, 1, 1, 0, 1, 0, 0, 2, 0, 1, 1, 0, 1, 1, 0, 0, 2, 1, 0, 1, 0, 0, 2, 1, 0, 3, 0, 1, 1, 0, 1, 1, 1, 0, 2, 0, 0, 2, 0, 0, 1, 0, 1, 2, 1, 1, 1, 2, 0, 1, 0, 1, 3, 0, 0, 1, 1, 1, 2, 0, 0, 2, 1, 0, 1, 1, 0, 2, 0, 1, 2, 0, 2, 1, 0, 0, 1, 1, 1, 3, 0, 0, 2, 0, 0, 1, 1, 1, 2, 1, 0, 1, 1, 1, 1, 1, 0, 3, 0, 0, 2, 0, 1, 1, 0
Offset: 1

Views

Author

Antti Karttunen, Apr 25 2017

Keywords

Crossrefs

One less than A091304 after the initial term.
Cf. A006254 (gives the positions of zeros after initial a(1)=0.)

Programs

  • Mathematica
    a[n_] := PrimeOmega[2*n - 1] - 1; a[1] = 0; Array[a, 100] (* Amiram Eldar, Jul 23 2023 *)
  • Scheme
    ;; First implementation uses memoization-macro definec:
    (definec (A285716 n) (if (<= n 2) 0 (+ (if (= 2 (modulo n 3)) 1 0) (A285716 (A285712 n)))))
    (define (A285716 n) (A080791 (A245611 n)))

Formula

a(1) = 0, a(2) = 1, for n > 2, a(n) = a(A285712(n)) + [n == 2 mod 3]. (Where [] is Iverson bracket, giving here 1 only if n is of the form 3k+2, and 0 otherwise.)
a(n) = A080791(A245611(n)).
For all n >= 2, a(n) = A091304(n)-1 = A000120(A244153(n))-1. - Antti Karttunen, May 31 2017

A253891 Permutation of natural numbers: a(n) = A245611(A163511(n)).

Original entry on oeis.org

0, 1, 7, 3, 6, 63, 15, 2, 1023, 32767, 13, 11, 255, 511, 127, 31, 28, 507, 134217727, 8388606, 524287, 17179869183, 60, 16777215, 16383, 8388607, 65535, 510, 62, 4095, 4, 14, 1073741823, 33554429, 223, 12855504354071922204335696738729300820177623950262342682411007, 16381, 268435451, 19807040628566084398385987583, 8589934589, 55
Offset: 0

Views

Author

Antti Karttunen, Jan 17 2015

Keywords

Comments

When A243071 is represented as a binary tree, then for any node A243071(k) containing n larger than zero, its left child A243071(2k-1) contains 1+(2*a(n)).

Crossrefs

Inverse: A253892.
Similar permutations: A253791, A253883, A163511, A245611, A243071, A054429.

Programs

Formula

a(n) = A245611(A163511(n)).
As a composition of other related permutations:
a(n) = A054429(A253791(A054429(n))).

A163511 a(0)=1. a(n) = p(A000120(n)) * Product_{m=1..A000120(n)} p(m)^A163510(n,m), where p(m) is the m-th prime.

Original entry on oeis.org

1, 2, 4, 3, 8, 9, 6, 5, 16, 27, 18, 25, 12, 15, 10, 7, 32, 81, 54, 125, 36, 75, 50, 49, 24, 45, 30, 35, 20, 21, 14, 11, 64, 243, 162, 625, 108, 375, 250, 343, 72, 225, 150, 245, 100, 147, 98, 121, 48, 135, 90, 175, 60, 105, 70, 77, 40, 63, 42, 55, 28, 33, 22, 13, 128
Offset: 0

Views

Author

Leroy Quet, Jul 29 2009

Keywords

Comments

This is a permutation of the positive integers.
From Antti Karttunen, Jun 20 2014: (Start)
Note the indexing: the domain starts from 0, while the range excludes zero, thus this is neither a bijection on the set of nonnegative integers nor on the set of positive natural numbers, but a bijection from the former set to the latter.
Apart from that discrepancy, this could be viewed as yet another "entanglement permutation" where the two complementary pairs to be interwoven together are even and odd numbers (A005843/A005408) which are entangled with the complementary pair even numbers (taken straight) and odd numbers in the order they appear in A003961: (A005843/A003961). See also A246375 which has almost the same recurrence.
Note how the even bisection halved gives the same sequence back. (For a(0)=1, take ceiling of 1/2).
(End)
From Antti Karttunen, Dec 30 2017: (Start)
This irregular table can be represented as a binary tree. Each child to the left is obtained by doubling the parent, and each child to the right is obtained by applying A003961 to the parent:
1
|
...................2...................
4 3
8......../ \........9 6......../ \........5
/ \ / \ / \ / \
/ \ / \ / \ / \
/ \ / \ / \ / \
16 27 18 25 12 15 10 7
32 81 54 125 36 75 50 49 24 45 30 35 20 21 14 11
etc.
Sequence A005940 is obtained by scanning the same tree level by level in mirror image fashion. Also in binary trees A253563 and A253565 the terms on level of the tree are some permutation of the terms present on the level n of this tree. A252464(n) gives the distance of n from 1 in all these trees, and A252463 gives the parent of the node containing n.
A252737(n) gives the sum and A252738(n) the product of terms on row n (where 1 is on row 0, 1 on row 1, 3 and 4 on row 2, etc.). A252745(n) gives the number of nodes on level n whose left child is smaller than the right child, and A252744(n) is an indicator function for those nodes.
(End)
Note that the idea behind maps like this (and the mirror image A005940) admits also using alternative orderings of primes, not just standard magnitude-wise ordering (A000040). For example, A332214 is a similar sequence but with primes rearranged as in A332211, and A332817 is obtained when primes are rearranged as in A108546. - Antti Karttunen, Mar 11 2020
From Lorenzo Sauras Altuzarra, Nov 28 2020: (Start)
This sequence is generated from A228351 by applying the following procedure: 1) eliminate the compositions that end in one unless the first one, 2) subtract one unit from every component, 3) replace every tuple [t_1, ..., t_r] by Product_{k=1..r} A000040(k)^(t_k) (see the examples).
Is it true that a(n) = A337909(n+1) if and only if a(n+1) is not a term of A161992?
Does this permutation have any other cycle apart from (1), (2) and (6, 9, 16, 7)? (End)
From Antti Karttunen, Jul 25 2023: (Start)
(In the above question, it is assumed that the starting offset would be 1 instead of 0).
Questions:
Does a(n) = 1+A054429(n) hold only when n is of the form 2^k times 1, 3 or 7, i.e., one of the terms of A029748?
It seems that A007283 gives all fixed points of map n -> a(n), like A335431 seems to give all fixed points of map n -> A332214(n). Is there a general rule for mappings like these that the fixed points (if they exist) must be of the form 2^k times a certain kind of prime, i.e., that any odd composite (times 2^k) can certainly be excluded? See also note in A029747.
(End)
If the conjecture given in A364297 holds, then it implies the above conjecture about A007283. See also A364963. - Antti Karttunen, Sep 06 2023
Conjecture: a(n^k) is never of the form x^k, for any integers n > 0, k > 1, x >= 1. This holds at least for squares, cubes, seventh and eleventh powers (see A365808, A365801, A366287 and A366391). - Antti Karttunen, Sep 24 2023, Oct 10 2023.
See A365805 for why the above holds for any n^k, with k > 1. - Antti Karttunen, Nov 23 2023

Examples

			For n=3, whose binary representation is "11", we have A000120(3)=2, with A163510(3,1) = A163510(3,2) = 0, thus a(3) = p(2) * p(1)^0 * p(2)^0 = 3*1*1 = 3.
For n=9, "1001" in binary, we have A000120(9)=2, with A163510(9,1) = 0 and A163510(9,2) = 2, thus a(9) = p(2) * p(1)^0 * p(2)^2 = 3*1*9 = 27.
For n=10, "1010" in binary, we have A000120(10)=2, with A163510(10,1) = 1 and A163510(10,2) = 1, thus a(10) = p(2) * p(1)^1 * p(2)^1 = 3*2*3 = 18.
For n=15, "1111" in binary, we have A000120(15)=4, with A163510(15,1) = A163510(15,2) = A163510(15,3) = A163510(15,4) = 0, thus a(15) = p(4) * p(1)^0 * p(2)^0 * p(3)^0 * p(4)^0 = 7*1*1*1*1 = 7.
[1], [2], [1,1], [3], [1,2], [2,1] ... -> [1], [2], [3], [1,2], ... -> [0], [1], [2], [0,1], ... -> 2^0, 2^1, 2^2, 2^0*3^1, ... = 1, 2, 4, 3, ... - _Lorenzo Sauras Altuzarra_, Nov 28 2020
		

Crossrefs

Inverse: A243071.
Cf. A007283 (known positions where a(n)=n), A029747, A029748, A364255 [= gcd(n,a(n))], A364258 [= a(n)-n], A364287 (where a(n) < n), A364292 (where a(n) <= n), A364494 (where n|a(n)), A364496 (where a(n)|n), A364963, A364297.
Cf. A365808 (positions of squares), A365801 (of cubes), A365802 (of fifth powers), A365805 [= A052409(a(n))], A366287, A366391.
Cf. A005940, A332214, A332817, A366275 (variants).

Programs

  • Mathematica
    f[n_] := Reverse@ Map[Ceiling[(Length@ # - 1)/2] &, DeleteCases[Split@ Join[Riffle[IntegerDigits[n, 2], 0], {0}], {k__} /; k == 1]]; {1}~Join~
    Table[Function[t, Prime[t] Product[Prime[m]^(f[n][[m]]), {m, t}]][DigitCount[n, 2, 1]], {n, 120}] (* Michael De Vlieger, Jul 25 2016 *)
  • Python
    from sympy import prime
    def A163511(n):
        if n:
            k, c, m = n, 0, 1
            while k:
                c += 1
                m *= prime(c)**(s:=(~k&k-1).bit_length())
                k >>= s+1
            return m*prime(c)
        return 1 # Chai Wah Wu, Jul 17 2023

Formula

For n >= 1, a(2n) is even, a(2n+1) is odd. a(2^k) = 2^(k+1), for all k >= 0.
From Antti Karttunen, Jun 20 2014: (Start)
a(0) = 1, a(1) = 2, a(2n) = 2*a(n), a(2n+1) = A003961(a(n)).
As a more general observation about the parity, we have:
For n >= 1, A007814(a(n)) = A135523(n) = A007814(n) + A209229(n). [This permutation preserves the 2-adic valuation of n, except when n is a power of two, in which cases that value is incremented by one.]
For n >= 1, A055396(a(n)) = A091090(n) = A007814(n+1) + 1 - A036987(n).
For n >= 1, a(A000225(n)) = A000040(n).
(End)
From Antti Karttunen, Oct 11 2014: (Start)
As a composition of related permutations:
a(n) = A005940(1+A054429(n)).
a(n) = A064216(A245612(n))
a(n) = A246681(A246378(n)).
Also, for all n >= 0, it holds that:
A161511(n) = A243503(a(n)).
A243499(n) = A243504(a(n)).
(End)
More linking identities from Antti Karttunen, Dec 30 2017: (Start)
A046523(a(n)) = A278531(n). [See also A286531.]
A278224(a(n)) = A285713(n). [Another filter-sequence.]
A048675(a(n)) = A135529(n) seems to hold for n >= 1.
A250245(a(n)) = A252755(n).
A252742(a(n)) = A252744(n).
A245611(a(n)) = A253891(n).
A249824(a(n)) = A275716(n).
A292263(a(n)) = A292264(n). [A292944(n) + A292264(n) = n.]
--
A292383(a(n)) = A292274(n).
A292385(a(n)) = A292271(n). [A292271(n) + A292274(n) = n.]
--
A292941(a(n)) = A292942(n).
A292943(a(n)) = A292944(n).
A292945(a(n)) = A292946(n). [A292942(n) + A292944(n) + A292946(n) = n.]
--
A292253(a(n)) = A292254(n).
A292255(a(n)) = A292256(n). [A292944(n) + A292254(n) + A292256(n) = n.]
--
A279339(a(n)) = A279342(n).
a(A071574(n)) = A269847(n).
a(A279341(n)) = A279338(n).
a(A252756(n)) = A250246(n).
(1+A008836(a(n)))/2 = A059448(n).
(End)
From Antti Karttunen, Jul 26 2023: (Start)
For all n >= 0, a(A007283(n)) = A007283(n).
A001222(a(n)) = A290251(n).
(End)

Extensions

More terms computed and examples added by Antti Karttunen, Jun 20 2014

A064216 Replace each p^e with prevprime(p)^e in the prime factorization of odd numbers; inverse of sequence A048673 considered as a permutation of the natural numbers.

Original entry on oeis.org

1, 2, 3, 5, 4, 7, 11, 6, 13, 17, 10, 19, 9, 8, 23, 29, 14, 15, 31, 22, 37, 41, 12, 43, 25, 26, 47, 21, 34, 53, 59, 20, 33, 61, 38, 67, 71, 18, 35, 73, 16, 79, 39, 46, 83, 55, 58, 51, 89, 28, 97, 101, 30, 103, 107, 62, 109, 57, 44, 65, 49, 74, 27, 113, 82, 127, 85, 24, 131
Offset: 1

Views

Author

Howard A. Landman, Sep 21 2001

Keywords

Comments

a((A003961(n) + 1) / 2) = n and A003961(a(n)) = 2*n - 1 for all n. If the sequence is indexed by odd numbers only, it becomes multiplicative. In this variant sequence, denoted b, even indices don't exist, and we get b(1) = a(1) = 1, b(3) = a(2) = 2, b(5) = 3, b(7) = 5, b(9) = 4 = b(3) * b(3), ... , b(15) = 6 = b(3) * b(5), and so on. This property can also be stated as: a(x) * a(y) = a(((2x - 1) * (2y - 1) + 1) / 2) for x, y > 0. - Reinhard Zumkeller [re-expressed by Peter Munn, May 23 2020]
Not multiplicative in usual sense - but letting m=2n-1=product_j (p_j)^(e_j) then a(n)=a((m+1)/2)=product_j (p_(j-1))^(e_j). - Henry Bottomley, Apr 15 2005
From Antti Karttunen, Jul 25 2016: (Start)
Several permutations that use prime shift operation A064989 in their definition yield a permutation obtained from their odd bisection when composed with this permutation from the right. For example, we have:
A243505(n) = A122111(a(n)).
A243065(n) = A241909(a(n)).
A244153(n) = A156552(a(n)).
A245611(n) = A243071(a(n)).
(End)

Examples

			For n=11, the 11th odd number is 2*11 - 1 = 21 = 3^1 * 7^1. Replacing the primes 3 and 7 with the previous primes 2 and 5 gives 2^1 * 5^1 = 10, so a(11) = 10. - _Michael B. Porter_, Jul 25 2016
		

Crossrefs

Odd bisection of A064989 and A252463.
Row 1 of A251721, Row 2 of A249821.
Cf. A048673 (inverse permutation), A048674 (fixed points).
Cf. A246361 (numbers n such that a(n) <= n.)
Cf. A246362 (numbers n such that a(n) > n.)
Cf. A246371 (numbers n such that a(n) < n.)
Cf. A246372 (numbers n such that a(n) >= n.)
Cf. A246373 (primes p such that a(p) >= p.)
Cf. A246374 (primes p such that a(p) < p.)
Cf. A246343 (iterates starting from n=12.)
Cf. A246345 (iterates starting from n=16.)
Cf. A245448 (this permutation "squared", a(a(n)).)
Cf. A253894, A254044, A254045 (binary width, weight and the number of nonleading zeros in base-2 representation of a(n), respectively).
Cf. A285702, A285703 (phi and sigma applied to a(n).)
Here obviously the variant 2, A151799(n) = A007917(n-1), of the prevprime function is used.
Cf. also A003961, A270430, A270431.

Programs

  • Mathematica
    Table[Times @@ Power[If[# == 1, 1, NextPrime[#, -1]] & /@ First@ #, Last@ #] &@ Transpose@ FactorInteger[2 n - 1], {n, 69}] (* Michael De Vlieger, Dec 18 2014, revised Mar 17 2016 *)
  • PARI
    a(n) = {my(f = factor(2*n-1)); for (k=1, #f~, f[k,1] = precprime(f[k,1]-1)); factorback(f);} \\ Michel Marcus, Mar 17 2016
    
  • Python
    from sympy import factorint, prevprime
    from operator import mul
    def a(n):
        f=factorint(2*n - 1)
        return 1 if n==1 else reduce(mul, [prevprime(i)**f[i] for i in f]) # Indranil Ghosh, May 13 2017
  • Scheme
    (define (A064216 n) (A064989 (- (+ n n) 1))) ;; Antti Karttunen, May 12 2014
    

Formula

a(n) = A064989(2n - 1). - Antti Karttunen, May 12 2014
Sum_{k=1..n} a(k) ~ c * n^2, where c = Product_{p prime > 2} ((p^2-p)/(p^2-q(p))) = 0.6621117868..., where q(p) = prevprime(p) (A151799). - Amiram Eldar, Jan 21 2023

Extensions

More terms from Reinhard Zumkeller, Sep 26 2001
Additional description added by Antti Karttunen, May 12 2014

A243071 Permutation of nonnegative integers: a(1) = 0, a(2) = 1, a(2n) = 2*a(n), a(2n+1) = 1 + 2*a(A064989(2n+1)).

Original entry on oeis.org

0, 1, 3, 2, 7, 6, 15, 4, 5, 14, 31, 12, 63, 30, 13, 8, 127, 10, 255, 28, 29, 62, 511, 24, 11, 126, 9, 60, 1023, 26, 2047, 16, 61, 254, 27, 20, 4095, 510, 125, 56, 8191, 58, 16383, 124, 25, 1022, 32767, 48, 23, 22, 253, 252, 65535, 18, 59, 120, 509, 2046, 131071
Offset: 1

Views

Author

Antti Karttunen, Jun 20 2014

Keywords

Comments

Note the indexing: the domain starts from 1, while the range includes also zero.
See also the comments at A163511, which is the inverse permutation to this one.

Crossrefs

Inverse: A163511.
Cf. A000040, A000225, A007814, A054429, A064989, A064216, A122111, A209229, A245611 (= (a(2n-1)-1)/2, for n > 1), A245612, A292383, A292385, A297171 (Möbius transform).
Cf. A007283 (known positions where a(n)=n), A364256 [= gcd(n,a(n))], A364288 [= n-a(n)], A364289 [where a(n)>=n], A364290 [where a(n)A364291 [where a(n)<=n], A364497 [where n|a(n)].
Cf. A156552 (variant with inverted binary code), A253566, A332215, A332811, A334859 (other variants).

Programs

  • PARI
    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))))); \\ Antti Karttunen, Jul 18 2020
    
  • PARI
    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) - Antti Karttunen, Jul 28 2023
    
  • Python
    from functools import reduce
    from sympy import factorint, prevprime
    from operator import mul
    def a064989(n):
        f = factorint(n)
        return 1 if n==1 else reduce(mul, (1 if i==2 else prevprime(i)**f[i] for i in f))
    def a(n): return n - 1 if n<3 else 2*a(n//2) if n%2==0 else 1 + 2*a(a064989(n))
    print([a(n) for n in range(1, 101)]) # Indranil Ghosh, Jun 15 2017
  • Scheme
    ;; With memoizing definec-macro from Antti Karttunen's IntSeq-library.
    (definec (A243071 n) (cond ((<= n 2) (- n 1)) ((even? n) (* 2 (A243071 (/ n 2)))) (else (+ 1 (* 2 (A243071 (A064989 n)))))))
    

Formula

a(1) = 0, a(2) = 1, a(2n) = 2*a(n), a(2n+1) = 1 + 2*a(A064989(2n+1)).
For n >= 1, a(A000040(n)) = A000225(n).
For n >= 1, a(2n+1) = 1 + 2*a(A064216(n+1)).
From Antti Karttunen, Jul 18 2020: (Start)
a(n) = A245611(A048673(n)).
a(n) = A253566(A122111(n)).
a(n) = A334859(A225546(n)).
For n >= 2, a(n) = A054429(A156552(n)).
a(n) = A292383(n) + A292385(n) = A292383(n) OR A292385(n).
For n > 1, A007814(a(n)) = A007814(n) - A209229(n). [This map preserves the 2-adic valuation of n, except when n is a power of two, in which cases it is decremented by one.]
(End)

A245612 Permutation of natural numbers: a(0) = 1, a(1) = 2, a(2n) = 3*a(n)-1, a(2n+1) = A254049(a(n)); composition of A048673 and A163511.

Original entry on oeis.org

1, 2, 5, 3, 14, 13, 8, 4, 41, 63, 38, 25, 23, 18, 11, 6, 122, 313, 188, 172, 113, 123, 74, 61, 68, 88, 53, 39, 32, 28, 17, 7, 365, 1563, 938, 1201, 563, 858, 515, 666, 338, 613, 368, 424, 221, 303, 182, 85, 203, 438, 263, 270, 158, 193, 116, 72, 95, 138, 83, 46, 50, 33, 20, 9
Offset: 0

Views

Author

Antti Karttunen, Jul 28 2014

Keywords

Comments

Note the indexing: the domain starts from 0, while the range excludes zero.
From Antti Karttunen, Jul 25 2016: (Start)
This sequence can be represented as a binary tree. Each left hand child is obtained by applying A016789(n-1) when the parent contains n (i.e., multiply by 3, subtract one), and each right hand child is obtained by applying A254049 to the parent's contents:
1
|
...................2...................
5 3
14......../ \........13 8......../ \........4
/ \ / \ / \ / \
/ \ / \ / \ / \
/ \ / \ / \ / \
41 63 38 25 23 18 11 6
122 313 188 172 113 123 74 61 68 88 53 39 32 28 17 7
etc.
(End)

Crossrefs

Programs

  • Mathematica
    Table[(Times @@ Power[If[# == 1, 1, NextPrime@ #] & /@ First@ #, Last@ #] + 1)/2 &@ Transpose@ FactorInteger@ If[n == 0, 1, Prime[#] Product[Prime[m]^(Map[Ceiling[(Length@ # - 1)/2] &, DeleteCases[Split@ Join[Riffle[IntegerDigits[n, 2], 0], {0}], {k__} /; k == 1]][[-m]]), {m, #}] &[DigitCount[n, 2, 1]]], {n, 0, 63}] (* Michael De Vlieger, Jul 25 2016 *)
  • Scheme
    (define (A245612 n) (A048673 (A163511 n))) ;; offset 0, a(0) = 1.

Formula

a(n) = A048673(A163511(n)).
a(0) = 1, a(1) = 2, a(2n) = 3*a(n)-1, a(2n+1) = A254049(a(n)). - Antti Karttunen, Jul 25 2016

A278223 Least number with the same prime signature as the n-th odd number: a(n) = A046523(2n-1).

Original entry on oeis.org

1, 2, 2, 2, 4, 2, 2, 6, 2, 2, 6, 2, 4, 8, 2, 2, 6, 6, 2, 6, 2, 2, 12, 2, 4, 6, 2, 6, 6, 2, 2, 12, 6, 2, 6, 2, 2, 12, 6, 2, 16, 2, 6, 6, 2, 6, 6, 6, 2, 12, 2, 2, 30, 2, 2, 6, 2, 6, 12, 6, 4, 6, 8, 2, 6, 2, 6, 24, 2, 2, 6, 6, 6, 12, 2, 2, 12, 6, 2, 6, 6, 2, 30, 2, 4, 12, 2, 12, 6, 2, 2, 6, 6, 6, 24, 2, 2, 30, 2, 2, 6, 6, 6, 12, 6, 2, 6, 6, 6, 6, 6, 2, 36, 2, 2
Offset: 1

Views

Author

Antti Karttunen, Nov 16 2016

Keywords

Comments

This sequence works as a filter for sequences related to the prime factorization of odd numbers by matching to any sequence that is obtained as f(2*n - 1), where f(n) is any function that depends only on the prime signature of n (see the index entry for "sequences computed from exponents in ..."). The last line in Crossrefs section lists such sequences that were present in the database as of Nov 11 2016, although some of the matches might be spurious.

Crossrefs

Odd bisection of A046523.
Sequences that partition or seem to partition N into same or coarser equivalence classes: A099774, A100007, A193773, A101871, A158280, A158315, A158647, A285716.

Programs

  • Mathematica
    a[n_] := Times @@ (Prime[Range[Length[f = FactorInteger[2*n - 1]]]]^Sort[f[[;; , 2]], Greater]); a[1] = 1; Array[a, 100] (* Amiram Eldar, Jul 23 2023 *)
  • Python
    from sympy import factorint
    def P(n):
        f = factorint(n)
        return sorted([f[i] for i in f])
    def a046523(n):
        x=1
        while True:
            if P(n) == P(x): return x
            else: x+=1
    def a(n): return a046523(2*n - 1) # Indranil Ghosh, May 11 2017
    
  • Python
    from math import prod
    from sympy import prime, factorint
    def A278223(n): return prod(prime(i+1)**e for i,e in enumerate(sorted(factorint((n<<1)-1).values(),reverse=True))) # Chai Wah Wu, Sep 16 2022
  • Scheme
    (define (A278223 n) (A046523 (+ n n -1)))
    (define (A278223 n) (A046523 (A064216 n)))
    

Formula

a(n) = A046523(2n - 1).
a(n) = A046523(A064216(n)).
From Antti Karttunen, May 31 2017: (Start)
a(n) = A278222(A244153(n)).
a(n) = A278531(A245611(n)).
(End)

A244153 Permutation of natural numbers, the odd bisection of A156552 halved; equally, a composition of A064216 and A156552: a(n) = A156552(A064216(n)).

Original entry on oeis.org

0, 1, 2, 4, 3, 8, 16, 5, 32, 64, 9, 128, 6, 7, 256, 512, 17, 10, 1024, 33, 2048, 4096, 11, 8192, 12, 65, 16384, 18, 129, 32768, 65536, 19, 34, 131072, 257, 262144, 524288, 13, 20, 1048576, 15, 2097152, 66, 513, 4194304, 36, 1025, 130, 8388608, 35, 16777216, 33554432, 21, 67108864, 134217728, 2049, 268435456, 258, 67, 68, 24, 4097, 14
Offset: 1

Views

Author

Antti Karttunen, Jun 27 2014

Keywords

Comments

Note the indexing: the domain starts from 1, while the range includes also zero.

Crossrefs

Programs

Formula

a(n) = A156552(2n+1) / 2.
As a composition of related permutations:
a(n) = A156552(A064216(n)).
a(n) = A054429(A245611(n)).

A245607 Permutation of natural numbers, the even bisection of A245605 halved: a(n) = A245605(2*n)/2.

Original entry on oeis.org

1, 2, 3, 5, 4, 9, 13, 6, 17, 37, 8, 25, 7, 10, 69, 33, 26, 11, 41, 16, 277, 45, 18, 65, 21, 14, 1109, 15, 52, 73, 57, 74, 35, 209, 82, 293, 141, 34, 53, 329, 12, 1173, 31, 36, 213, 149, 104, 43, 49, 20, 145, 173, 138, 81, 581, 114, 553, 71, 90, 133, 101, 282, 19, 325, 24, 457, 165, 50, 77, 97, 62, 105, 555, 42
Offset: 1

Views

Author

Antti Karttunen, Jul 29 2014

Keywords

Crossrefs

Programs

Formula

a(n) = A245605(2*n)/2.
As a composition of related permutations:
a(n) = A245605(A064216(n)).
a(n) = A245705(A245707(n)).
Showing 1-10 of 17 results. Next