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 505 results. Next

A278222 The least number with the same prime signature as A005940(n+1).

Original entry on oeis.org

1, 2, 2, 4, 2, 6, 4, 8, 2, 6, 6, 12, 4, 12, 8, 16, 2, 6, 6, 12, 6, 30, 12, 24, 4, 12, 12, 36, 8, 24, 16, 32, 2, 6, 6, 12, 6, 30, 12, 24, 6, 30, 30, 60, 12, 60, 24, 48, 4, 12, 12, 36, 12, 60, 36, 72, 8, 24, 24, 72, 16, 48, 32, 64, 2, 6, 6, 12, 6, 30, 12, 24, 6, 30, 30, 60, 12, 60, 24, 48, 6, 30, 30, 60, 30, 210, 60, 120, 12, 60, 60, 180, 24, 120, 48, 96, 4, 12, 12
Offset: 0

Views

Author

Antti Karttunen, Nov 15 2016

Keywords

Comments

This sequence can be used for filtering certain base-2 related sequences, because it matches only with any such sequence b that can be computed as b(n) = f(A005940(n+1)), where f(n) is any function that depends only on the prime signature of n (some of these are listed under the index entry for "sequences computed from exponents in ...").
Matching in this context means that the sequence a matches with the sequence b iff for all i, j: a(i) = a(j) => b(i) = b(j). In other words, iff the sequence b partitions the natural numbers to the same or coarser equivalence classes (as/than the sequence a) by the distinct values it obtains.
Because the Doudna map n -> A005940(1+n) is an isomorphism from "unary-binary encoding of factorization" (see A156552) to the ordinary representation of the prime factorization of n, it follows that the equivalence classes of this sequence match with any such sequence b, where b(n) is computed from the lengths of 1-runs in the binary representation of n and the order of those 1-runs does not matter. Particularly, this holds for any sequence that is obtained as a "Run Length Transform", i.e., where b(n) = Product S(i), for some function S, where i runs through the lengths of runs of 1's in the binary expansion of n. See for example A227349.
However, this sequence itself is not a run length transform of any sequence (which can be seen for example from the fact that A046523 is not multiplicative).
Furthermore, this matches not only with sequences involving products of S(i), but with any sequence obtained with any commutative function applied cumulatively, like e.g., A000120 (binary weight, obtained in this case as Sum identity(i)), and A069010 (number of runs of 1's in binary representation of n, obtained as Sum signum(i)).

Crossrefs

Similar sequences: A278217, A278219 (other base-2 related variants), A069877 (base-10 related), A278226 (primorial base), A278234-A278236 (factorial base), A278243 (Stern polynomials), A278233 (factorization in ring GF(2)[X]), A046523 (factorization in Z).
Cf. also A286622 (rgs-transform of this sequence) and A286162, A286252, A286163, A286240, A286242, A286379, A286464, A286374, A286375, A286376, A286243, A286553 (various other sequences involving this sequence).
Sequences that partition N into same or coarser equivalence classes: too many to list all here (over a hundred). At least every sequence listed under index-entry "Run Length Transforms" is included (e.g., A227349, A246660, A278159), and also sequences like A000120 and A069010, and their combinations like A136277.

Programs

  • Mathematica
    f[n_, i_, x_] := Which[n == 0, x, EvenQ@ n, f[n/2, i + 1, x], True, f[(n - 1)/2, i, x Prime@ i]]; Array[If[# == 1, 1, Times @@ MapIndexed[ Prime[First[#2]]^#1 &, Sort[FactorInteger[#][[All, -1]], Greater]]] &@ f[# - 1, 1, 1] &, 99] (* Michael De Vlieger, May 09 2017 *)
  • PARI
    A046523(n)=factorback(primes(#n=vecsort(factor(n)[, 2], , 4)), n)
    a(n)=my(p=2, t=1); for(i=0,exponent(n), if(bittest(n,i), t*=p, p=nextprime(p+1))); A046523(t) \\ Charles R Greathouse IV, Nov 11 2021
  • Python
    from sympy import prime, factorint
    import math
    def A(n): return n - 2**int(math.floor(math.log(n, 2)))
    def b(n): return n + 1 if n<2 else prime(1 + (len(bin(n)[2:]) - bin(n)[2:].count("1"))) * b(A(n))
    def a005940(n): return b(n - 1)
    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(a005940(n + 1)) # Indranil Ghosh, May 05 2017
    
  • Scheme
    (define (A278222 n) (A046523 (A005940 (+ 1 n))))
    

Formula

a(n) = A046523(A005940(1+n)).
a(n) = A124859(A278159(n)).
a(n) = A278219(A006068(n)).

Extensions

Misleading part of the name removed by Antti Karttunen, Apr 07 2022

A005941 Inverse of the Doudna sequence A005940.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 9, 8, 7, 10, 17, 12, 33, 18, 11, 16, 65, 14, 129, 20, 19, 34, 257, 24, 13, 66, 15, 36, 513, 22, 1025, 32, 35, 130, 21, 28, 2049, 258, 67, 40, 4097, 38, 8193, 68, 23, 514, 16385, 48, 25, 26, 131, 132, 32769, 30, 37, 72, 259, 1026, 65537, 44, 131073, 2050, 39, 64
Offset: 1

Views

Author

Keywords

Comments

a(2^k) = 2^k. - Robert G. Wilson v, Feb 22 2005
Fixed points: A029747. - Reinhard Zumkeller, Aug 23 2006
Question: Is there a simple proof that a(c) = c would never allow an odd composite c as a solution? See also A364551. - Antti Karttunen, Jul 30 2023

References

  • J. H. Conway, personal communication.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A103969. Inverse of A005940. One more than A156552.
Cf. A364559 [= a(n)-n], A364557 (Möbius transform), A364558.
Cf. A029747 [known positions where a(n) = n], A364560 [where a(n) <= n], A364561 [where a(n) <= n and n is odd], A364562 [where a(n) > n], A364548 [where n divides a(n)], A364549 [where odd n divides a(n)], A364550 [where a(n) divides n], A364551 [where a(n) divides n and n is odd].

Programs

  • Maple
    A005941 := proc(n)
        local k ;
        for k from 1 do
        if A005940(k) = n then # code reuse
            return k;
        end if;
        end do ;
    end proc: # R. J. Mathar, Mar 06 2010
  • Mathematica
    f[n_] := Block[{p = Partition[ Split[ Join[ IntegerDigits[n - 1, 2], {2}]], 2]}, Times @@ Flatten[ Table[q = Take[p, -i]; Prime[ Count[ Flatten[q], 0] + 1]^q[[1, 1]], {i, Length[p]}] ]]; t = Table[ f[n], {n, 10^5}]; Flatten[ Table[ Position[t, n, 1, 1], {n, 64}]] (* Robert G. Wilson v, Feb 22 2005 *)
  • PARI
    A005941(n) = { 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]); (1+res) }; \\ (After David A. Corneth's program for A156552) - Antti Karttunen, Jul 30 2023
  • Python
    from sympy import primepi, factorint
    def A005941(n): return sum((1<Chai Wah Wu, Mar 11 2023
    
  • Scheme
    (define (A005941 n) (+ 1 (A156552 n))) ;; Antti Karttunen, Jun 26 2014
    

Formula

a(n) = h(g(n,1,1), 0) / 2 + 1 with h(n, m) = if n=0 then m else h(floor(n/2), 2*m + n mod 2) and g(n, i, x) = if n=1 then x else (if n mod prime(i) = 0 then g(n/prime(i), i, 2*x+1) else g(n, i+1, 2*x)). - Reinhard Zumkeller, Aug 23 2006
a(n) = 1 + A156552(n). - Antti Karttunen, Jun 26 2014

Extensions

More terms from Robert G. Wilson v, Feb 22 2005
a(61) inserted by R. J. Mathar, Mar 06 2010

A324054 a(n) = A000203(A005940(1+n)).

Original entry on oeis.org

1, 3, 4, 7, 6, 12, 13, 15, 8, 18, 24, 28, 31, 39, 40, 31, 12, 24, 32, 42, 48, 72, 78, 60, 57, 93, 124, 91, 156, 120, 121, 63, 14, 36, 48, 56, 72, 96, 104, 90, 96, 144, 192, 168, 248, 234, 240, 124, 133, 171, 228, 217, 342, 372, 403, 195, 400, 468, 624, 280, 781, 363, 364, 127, 18, 42, 56, 84, 84, 144, 156, 120, 112, 216, 288, 224
Offset: 0

Views

Author

Antti Karttunen, Feb 14 2019

Keywords

Comments

As noted by David A. Corneth, the function f(n) = a(n-1) [that is, the offset-1 version of this sequence] seems to be "almost multiplicative". Sequence A324109 gives the positions n where f(n) satisfies the multiplicativity in a sense that f(n) = f(p(1)^e(1)) * ... * f(p(k)^e(k)), when n = p(1)^e(1) * ... * p(k)^e(k), and A324110 the positions where this does not hold.

Crossrefs

Cf. also A106737, A290077 (tau and phi similarly permuted).

Programs

  • Mathematica
    nn = 76; a[0] = 1; Do[Set[a[n], Prime[1 + DigitCount[n, 2, 0]]*a[n - 2^Floor@ Log2@ n]], {n, nn}]; Array[DivisorSigma[1, a[#]] &, nn, 0] (* Michael De Vlieger, Aug 03 2022 *)
  • PARI
    A005940(n) = { my(p=2, t=1); n--; until(!n\=2, if((n%2), (t*=p), p=nextprime(p+1))); t }; \\ From A005940
    A324054(n) = sigma(A005940(1+n));
    
  • PARI
    A324054(n) = { my(p=2,mp=p*p,m=1); while(n, if(!(n%2), p=nextprime(1+p); mp = p*p, if(3==(n%4),mp *= p,m *= (mp-1)/(p-1))); n>>=1); (m); };
    
  • Python
    from math import prod
    from itertools import accumulate
    from collections import Counter
    from sympy import prime
    def A324054(n): return prod(((p:=prime(len(a)+1))**(b+1)-1)//(p-1) for a, b in Counter(accumulate(bin(n)[2:].split('1')[:0:-1])).items()) # Chai Wah Wu, Mar 10 2023

Formula

a(n) = A000203(A005940(1+n)).
a(n) = A324056(n) * A038712(1+n).

A347381 Distance from n to the nearest common ancestor of n and sigma(n) in the Doudna-tree (A005940).

Original entry on oeis.org

0, 0, 1, 1, 1, 0, 3, 2, 2, 3, 3, 2, 2, 3, 1, 3, 6, 3, 5, 1, 4, 5, 7, 2, 3, 4, 3, 0, 8, 4, 10, 4, 4, 7, 2, 4, 4, 7, 3, 4, 10, 4, 9, 4, 3, 9, 13, 4, 4, 4, 7, 7, 15, 4, 5, 5, 6, 9, 15, 4, 7, 10, 3, 5, 4, 6, 12, 6, 8, 5, 19, 5, 9, 6, 4, 8, 3, 5, 19, 4, 3, 11, 20, 4, 7, 11, 9, 6, 22, 4, 4, 8, 11, 15, 7, 5, 24, 5, 3, 5, 20
Offset: 1

Views

Author

Antti Karttunen, Aug 30 2021

Keywords

Comments

a(n) tells about the degree of relatedness between n and sigma(n) in Doudna tree (see the illustration in A005940). It is 0 for those n where sigma(n) is one of the descendants of n, 1 for those n where the nearest common ancestor of n and sigma(n) is the parent of n, 2 for those n where the nearest common ancestor of n and sigma(n) is the grandparent of n, and so on.

Crossrefs

Indices of 0 .. 5 in this sequence are given by {2} U A336702, A347391, A347392, A347393, A347394, A374465.
Cf. A000203, A027687, A156552, A252463, A252464, A332221, A347380, A347383, A347384, A347390, A374481 [a(prime(n))], A374482 (indices of records), A374483 (record values).
Cf. also A336834.

Programs

  • PARI
    A000523(n) = logint(n,2);
    Abincompreflen(x, y) = if(!x || !y, 0, my(xl=A000523(x), yl=A000523(y), s=min(xl,yl), k=0); x >>= (xl-s); y >>= (yl-s); while(s>=0 && !bitand(1,bitxor(x>>s,y>>s)), s--; k++); (k));
    A156552(n) = {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]); res}; \\ From A156552
    A061395(n) = if(n>1, primepi(vecmax(factor(n)[, 1])), 0);
    A252464(n) = if(1==n,0,(bigomega(n) + A061395(n) - 1));
    A347381(n) = (A252464(n)-Abincompreflen(A156552(n), A156552(sigma(n))));
    
  • 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)};
    A252463(n) = if(!(n%2),n/2,A064989(n));
    A347381(n) = if(1==n,0, my(lista=List([]), i, k=n, stemvec, stemlen, sbr=sigma(n)); while(k>1, listput(lista,k); k = A252463(k)); stemvec = Vecrev(Vec(lista)); stemlen = #stemvec; while(1, if((i=vecsearch(stemvec,sbr))>0, return(stemlen-i)); sbr = A252463(sbr)));

Formula

a(n) = A252464(n) - A347380(n), where A347380(n) is the length of the common prefix in binary expansions of A156552(n) and A332221(n) = A156552(sigma(n)).

Extensions

Name changed, old name is now in formula section. - Antti Karttunen, Jul 09 2024

A103969 Positions n such that A005941(n) = A005940(n).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 14, 16, 18, 20, 24, 28, 32, 36, 40, 48, 56, 64, 72, 80, 96, 112, 128, 144, 160, 192, 224, 256, 288, 320, 384, 448, 512, 576, 640, 768, 896, 1024, 1152, 1280, 1536, 1792, 2048, 2304, 2560, 3072, 3584, 4096, 4608, 5120, 6144, 7168
Offset: 1

Views

Author

Robert G. Wilson v, Feb 22 2005

Keywords

Comments

Sequence with n>=5 appears to be quintisected with the quintisections multiples of A000079 (powers of two): a(5m) = 5,10,20,40... = 5*2^(m-1) for m>0; a(5m+1) = 6,12,24,48,... = 6*2^(m-1); likewise a(5m+2) = 7*2^(m-1); a(5m+3) = 8*2^(m-1); a(5m+4) = 9*2^(m-1). - Ralf Stephan, Nov 13 2010
From Antti Karttunen, Aug 01 2023: (Start)
Numbers k for which A005940(A005940(k)) = k, or equally, for which A005941(A005941(k)) = k, i.e., numbers that are either fixed points of permutation A005940/A005941, or elements of its 2-cycles.
If n is a term then also 2*n is present, and vice versa.
Question: Are 1, 3, 5, 7 and 9 the only odd terms of this sequence?
(End)

Examples

			56 is in the sequence since A005940(56) = A005941(56) = 72.
7 is in the sequence since A005940(7) = 9, and A005940(9) = 7, thus also A005941(7) = 9, and A005941(9) = 7. - _Antti Karttunen_, Aug 01 2023
		

Crossrefs

Cf. A005940, A005941, A029747 (subsequence).

Programs

  • Mathematica
    f[n_] := Block[{p = Partition[ Split[ Join[ IntegerDigits[n - 1, 2], {2}]], 2]}, Times @@ Flatten[ Table[q = Take[p, -i]; Prime[ Count[ Flatten[q], 0] + 1]^q[[1, 1]], {i, Length[p]}] ]]; t = Table[ f[n], {n, 10^4}]; u = Flatten[ Table[ Position[t, n, 1, 1], {n, 10^4}]]; Do[ If[ u[[n]] == {}, u[[n]] = {0}], {n, 10^4}]; Flatten[ Position[ Take[t, 10^4] - Flatten[u], 0]]
  • Python
    from math import prod
    from itertools import accumulate, count, islice
    from sympy import prime, primepi, factorint
    from collections import Counter
    def A103969_gen(startvalue=1): # generator of terms >= startvalue
        return filter(lambda n:sum((1<A103969_list = list(islice(A103969_gen(),20)) # Chai Wah Wu, Mar 11 2023

Formula

Empirical g.f.: x*(1 +x +x^2 +x^3 +x^4)^2 / (1-2*x^5). - Colin Barker, Nov 18 2016

Extensions

Definition corrected and example updated by R. J. Mathar, Mar 06 2010

A347391 Numbers k such that sigma(k) is either their sibling in Doudna tree (A005940), or one of the sibling's descendants.

Original entry on oeis.org

3, 4, 5, 15, 20, 189, 945, 2125, 6375, 9261, 46305, 401625, 19679625
Offset: 1

Views

Author

Antti Karttunen, Aug 30 2021

Keywords

Comments

Numbers k > 1 such that nearest common ancestor of k and sigma(k) in Doudna tree is the parent of k, and sigma(k) is not a descendant of k.
Any hypothetical odd term x in A005820 (triperfect numbers) would also be a member of this sequence. This is illustrated in the following diagram which shows how the neighborhood of such x would look like in the Doudna tree (A005940). If m (the parent of x, x = A003961(m), m = A064989(x)) is even, then x is a multiple of 3, while if m is odd, then 3 does not divide x. Because the abundancy index decreases when traversing leftwards in the Doudna tree, m must be a term of A068403. Both x and m would also need to be squares, by necessity.
.
<--A003961-- m ---(*2)--->
.............../ \...............
/ \
/ \
x 2m
/ \ / \
etc.../ \.....2x sigma(x) = 3x..../ \.....4m
/ \ / \ / \
etc. etc. etc. \ / etc.
\ /
6x 9x = sigma(2x)
/ \ / \
etc. \ etc. etc.
\
12x = sigma(3x) if m odd.
.
From the diagram we also see that 2x would then need to be a term of A347392 (as well as that of A159907 and also in A074388, thus sqrt(x) should be a term of A097023), and furthermore, if x is not a multiple of 3 (i.e., when m is odd), then sigma(3*x) = 4*sigma(x) = 4*(3*x), thus 3*x = sigma(x) would be a term of A336702 (particularly, in A027687) and x would be a term of A323653.
Moreover, any odd square x in this sequence (for which sigma(x) would also be odd), would have an abundancy index of at least three (sigma(x)/x >= 3). See comments in A347383.
Note how 401625 = 6375 * 63 = 945 * 425, 46305 = 945 * 49, 9261 = 189 * 49, 6375 = 2125 * 3, 945 = 189 * 5 = 15 * 63 and 9261*2125 = 19679625. It seems that when the multiplicands are coprime, then they are both terms of this sequence, e.g. 2125 and 3, 189 and 5, 2125 and 9261.
From Antti Karttunen, Jul 10 2024: (Start)
Regarding the observation above, for two coprime odd numbers x, y, if both are included here because sigma(x) = 2^a * A064989(x) and sigma(y) = 2^b * A064989(y), then also their product x*y is included because in that case sigma(x*y) = 2^(a+b) * A064989(x*y).
Also, for two coprime odd numbers x, y, if both are included here because sigma(x) = A065119(i) * x and sigma(y) = A065119(j) * y, then also their product x*y is included because sigma(x*y) = A065119(k) * x*y, where A065119(k) = A065119(i)*A065119(j). The existence of such numbers (that would include odd triperfect and odd 6-perfect numbers, see A046061) is so far hypothetical, none is known.
It is not possible that the odd x is in this sequence if sigma(x) = k*A003961^e(x) and e = A061395(k)-2 >= 1.
Note that all odd terms < 2^33 here are some of the exponentially odd divisors of 19679625 (see A374199, also A374463 and A374464).
(End)
Question: from a(6) = 189 onward, are the rest of terms all in A347390?
Conjecture: sequence is finite.
If it exists, a(14) > 2^33.

Examples

			Sigma(3) = 4 is located as the sibling of 3 in the Doudna-tree (see the illustration in A005940), thus 3 is included in this sequence.
Sigma(4) = 7 is located as a grandchild of 3 (which is the sibling of 4) in the Doudna-tree, thus 4 is included in this sequence.
Sigma(5) = 6 is located as the sibling of 5 in the Doudna-tree, thus 5 is included in this sequence.
189 (= 3^3 * 7) is a term, as sigma(189) = 320, and 320 occurs as a descendant of 80 (which is the right sibling of 189) in the Doudna tree, as illustrated below:
.
             40
            /  \
   A003961 /    \ *2
          /      \
        189       80
        / \      / \
     etc   etc etc  160
                   / \
                 etc  320
                     / \
                   etc. etc.
.
945 (= 3^3 * 5 * 7) is a term, as sigma(945) = 1920, and 1920 occurs as a descendant of 240, which is the right sibling of 945 in the Doudna tree, as illustrated below:
            120
            /  \
   A003961 /    \ *2
          /      \
        945       240
        / \      / \
     etc   etc  etc  480
                   / \
                 etc  960
                     / \
                   etc. 1920
                        / \
                     etc. etc.
		

Crossrefs

Programs

  • PARI
    isA347391(n) = (1==A347381(n));
    
  • 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)};
    A252463(n) = if(!(n%2),n/2,A064989(n));
    isA347391(n) = if(1==n,0,my(m=A252463(n), s=sigma(n)); while(s>m, if(s==n, return(0)); s = A252463(s)); (s==m));

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

Original entry on oeis.org

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

Views

Author

Antti Karttunen, Jun 27 2014

Keywords

Comments

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

Crossrefs

Programs

Formula

a(n) = A048673(A005940(n+1)).
From Antti Karttunen, May 30 2017: (Start)
a(0) = 1, a(1) = 2, a(2n) = A254049(a(n)), a(2n+1) = 3*a(n)-1.
a(n) = A245612(A054429(n)).
(End)

A324055 Deficiency of Doudna-sequence: a(n) = A033879(A005940(1+n)).

Original entry on oeis.org

1, 1, 2, 1, 4, 0, 5, 1, 6, 2, 6, -4, 19, -3, 14, 1, 10, 4, 10, -2, 22, -12, 12, -12, 41, 7, 26, -19, 94, -12, 41, 1, 12, 8, 18, 0, 38, -12, 22, -10, 58, -4, 18, -48, 102, -54, 30, -28, 109, 25, 66, -17, 148, -72, 47, -51, 286, 32, 126, -64, 469, -39, 122, 1, 16, 10, 22, 4, 46, -12, 42, -8, 70, 4, 42, -56, 178, -60, 58, -26, 118, 20
Offset: 0

Views

Author

Antti Karttunen, Feb 14 2019

Keywords

Comments

Both here and in the mirror image sequence A324185, the lowermost (asinh) scatter plot shows on the y = 0 line the numbers that correspond to the perfect numbers. Compare also to the scatter plot of A243492.

Crossrefs

See A106737, A290077, A323915, A324052, A324054, A324056, A324057, A324058, A324114, A324335, A324340, A324348, A324349, A324394, A324395 for other sequences as permuted by A005940, and compare their scatter plots.

Programs

  • Mathematica
    Array[Block[{p = Partition[Split[Join[IntegerDigits[#, 2], {2}]], 2]}, 2 # - DivisorSigma[1, #] &[Times @@ Flatten@ Table[Prime[Count[Flatten@ #, 0] + 1]^#[[1, 1]] &@ Take[p, -i], {i, Length[p]}]]] &, 82, 0] (* Michael De Vlieger, Mar 11 2019, after Robert G. Wilson v at A005940 *)
  • PARI
    A005940(n) = { my(p=2, t=1); n--; until(!n\=2, if((n%2), (t*=p), p=nextprime(p+1))); t }; \\ From A005940
    A033879(n) = (2*n-sigma(n));
    A324055(n) = A033879(A005940(1+n));
    
  • PARI
    A324055(n) = { my(m1=2,m2=1,p=2,mp=p*p); while(n, if(!(n%2), p=nextprime(1+p); mp = p*p, m1 *= p; if(3==(n%4),mp *= p,m2 *= (mp-1)/(p-1))); n>>=1); (m1-m2); };

Formula

a(n) = A033879(A005940(1+n)).
a(n) = 2*A005940(1+n) - A324054(n).
For n > 0, a(n) = A324185(A054429(n)).
a(n) = A324348(n) + A000120(A005940(1+n)).

A329603 a(n) = A005940(1+(1+(3*A156552(n)))) = (1/2) * A005940(1+(3*A156552(2*n))).

Original entry on oeis.org

2, 5, 8, 15, 18, 11, 50, 45, 20, 125, 98, 33, 242, 245, 32, 135, 338, 77, 578, 375, 72, 605, 722, 99, 42, 845, 60, 735, 1058, 17, 1682, 405, 200, 1445, 162, 231, 1922, 1805, 392, 1125, 2738, 1331, 3362, 1815, 44, 2645, 3698, 297, 110, 275, 968, 2535, 4418, 539, 450, 2205, 1352, 4205, 5618, 51, 6962, 4805, 500, 1215, 882, 1859, 7442, 4335, 2312
Offset: 1

Views

Author

Antti Karttunen, Nov 21 2019

Keywords

Comments

Function n -> 3n+1 (A016777) conjugated by A156552. - Antti Karttunen, Aug 21 2021

Crossrefs

Permutation of A329604.
A skewed diagonal of A341510.

Programs

  • PARI
    A005940(n) = { my(p=2, t=1); n--; until(!n\=2, if((n%2), (t*=p), p=nextprime(p+1))); t };
    A156552(n) = { my(f = factor(n), 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]); res };
    A329603(n) = ((1/2)*A005940(1+(3*A156552(2*n))));
    
  • Python
    from math import prod
    from itertools import accumulate
    from collections import Counter
    from sympy import prime, primepi, factorint
    def A329603(n): return prod(prime(len(a)+1)**b for a, b in Counter(accumulate(bin(1+3*sum((1<Chai Wah Wu, Mar 11 2023

Formula

a(n) = (1/2) * A005940(1+(3*A156552(2*n))).
From Antti Karttunen, Feb 14 2021: (Start)
A156552(2*a(n)) = 3*A156552(2*n) = 3*(1+2*A156552(n)) = 3 + 6*A156552(n).
a(n) = A341510(n,2n) = A005940(1+A156552(n)+A156552(2n)) = A005940(1+(1+(3*A156552(n)))).
a(n) = A005940(1+A016777(A156552(n))).
For all n >= 1, A329903(a(n)) = A332814(a(n)) = A332823(A332461(a(n))) = 1.
For all n >= 1, A341354(a(n)) > 0.
For all n >= 1, A000035(a(n)) = 1 - A000035(n). [Flips the parity of n]
(End)
a(n) = A332449(2*n)/2, a(n) = Sum_{d|n} A347117(d). - Antti Karttunen, Aug 21 2021

Extensions

New primary definition added by Antti Karttunen, Feb 14 2021

A332449 a(n) = A005940(1+(3*A156552(n))).

Original entry on oeis.org

1, 4, 9, 10, 25, 16, 49, 30, 21, 36, 121, 22, 169, 100, 81, 90, 289, 40, 361, 250, 225, 196, 529, 66, 55, 484, 105, 490, 841, 64, 961, 270, 441, 676, 625, 154, 1369, 1156, 1089, 750, 1681, 144, 1849, 1210, 39, 1444, 2209, 198, 91, 84, 1521, 1690, 2809, 120, 1225, 1470, 2601, 2116, 3481, 34, 3721, 3364, 1029, 810, 3025, 400
Offset: 1

Views

Author

Antti Karttunen, Feb 14 2020

Keywords

Crossrefs

Cf. A329609 (terms sorted into ascending order).
Cf. A000290, A003961, A005117 (positions of squares), A005940, A010052, A156552, A277010, A329603, A332450, A332451, A347119, A347120, A353267 [= A348717(a(n))], A353269, A353270 [= gcd(n, a(n))], A353271, A353272, A353273.
Cf. also A332223.

Programs

  • PARI
    A005940(n) = { my(p=2, t=1); n--; until(!n\=2, if((n%2), (t*=p), p=nextprime(p+1))); t }; \\ From A005940
    A156552(n) = {my(f = factor(n), 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]); res}; \\ From A156552
    A332449(n) = A005940(1+(3*A156552(n)));

Formula

a(n) = A005940(1+(3*A156552(n))).
a(p) = p^2 for all primes p.
a(u) = A332451(u) and A010052(a(u)) = 1 for all squarefree numbers (A005117).
a(A003961(n)) = A003961(a(n)) = A005940(1+(6*A156552(n))).
From Antti Karttunen, Apr 10 2022: (Start)
a(n) = A347119(n) * A000290(A347120(n)) = A353270(n) * A353272(n).
a(A353269(n)) = 1 for all n.
(End)
Showing 1-10 of 505 results. Next