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

A003602 Kimberling's paraphrases: if n = (2k-1)*2^m then a(n) = k.

Original entry on oeis.org

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

Views

Author

Keywords

Comments

Fractal sequence obtained from powers of 2.
k occurs at (2*k-1)*A000079(m), m >= 0. - Robert G. Wilson v, May 23 2006
Sequence is T^(oo)(1) where T is acting on a word w = w(1)w(2)..w(m) as follows: T(w) = "1"w(1)"2"w(2)"3"(...)"m"w(m)"m+1". For instance T(ab) = 1a2b3. Thus T(1) = 112, T(T(1)) = 1121324, T(T(T(1))) = 112132415362748. - Benoit Cloitre, Mar 02 2009
Note that iterating the post-numbering operator U(w) = w(1) 1 w(2) 2 w(3) 3... produces the same limit sequence except with an additional "1" prepended, i.e., 1,1,1,2,1,3,2,4,... - Glen Whitney, Aug 30 2023
In the binary expansion of n, first swallow all zeros from the right, then add 1, and swallow the now-appearing 0 bit as well. - Ralf Stephan, Aug 22 2013
Although A264646 and this sequence initially agree in their digit-streams, they differ after 48 digits. - N. J. A. Sloane, Nov 20 2015
"[This is a] fractal because we get the same sequence after we delete from it the first appearance of all positive integers" - see Cobeli and Zaharescu link. - Robert G. Wilson v, Jun 03 2018
From Peter Munn, Jun 16 2022: (Start)
The sequence is the list of positive integers interleaved with the sequence itself. Provided the offset is suitable (which is the case here) a term of such a self-interleaved sequence is determined by the odd part of its index. Putting some of the formulas given here into words, a(n) is the position of the odd part of n in the list of odd numbers.
Applying the interleaving transform again, we get A110963.
(End)
Omitting all 1's leaves A131987 + 1. - David James Sycamore, Jul 26 2022
a(n) is also the smallest positive number not among the terms between a(a(n-1)) and a(n-1) inclusive (with a(0)=1 prepended). - Neal Gersh Tolunsky, Mar 07 2023

Examples

			From _Peter Munn_, Jun 14 2022: (Start)
Start of table showing the interleaving with the positive integers:
   n  a(n)  (n+1)/2  a(n/2)
   1    1      1
   2    1               1
   3    2      2
   4    1               1
   5    3      3
   6    2               2
   7    4      4
   8    1               1
   9    5      5
  10    3               3
  11    6      6
  12    2               2
(End)
		

References

  • Michel Rigo, Formal Languages, Automata and Numeration Systems, 2 vols., Wiley, 2014. Mentions this sequence - see "List of Sequences" in Vol. 2.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

a(n) is the index of the column in A135764 where n appears (see also A054582).
Cf. A000079, A000265, A001511, A003603, A003961, A014577 (with offset 1, reduction mod 2), A025480, A035528, A048673, A101279, A110963, A117303, A126760, A181988, A220466, A249745, A253887, A337821 (2-adic valuation).
Cf. also A349134 (Dirichlet inverse), A349135 (sum with it), A349136 (Möbius transform), A349431, A349371 (inverse Möbius transform).
Cf. A264646.

Programs

  • Haskell
    a003602 = (`div` 2) . (+ 1) . a000265
    -- Reinhard Zumkeller, Feb 16 2012, Oct 14 2010
    
  • Haskell
    import Data.List (transpose)
    a003602 = flip div 2 . (+ 1) . a000265
    a003602_list = concat $ transpose [[1..], a003602_list]
    -- Reinhard Zumkeller, Aug 09 2013, May 23 2013
    
  • Maple
    A003602:=proc(n) options remember: if n mod 2 = 1 then RETURN((n+1)/2) else RETURN(procname(n/2)) fi: end proc:
    seq(A003602(n), n=1..83); # Pab Ter
    nmax := 83: for m from 0 to ceil(simplify(log[2](nmax))) do for k from 1 to ceil(nmax/(m+2)) do a((2*k-1)*2^m) := k od: od: seq(a(k), k=1..nmax); # Johannes W. Meijer, Feb 04 2013
    A003602 := proc(n)
        a := 1;
        for p in ifactors(n)[2] do
            if op(1,p) > 2 then
                a := a*op(1,p)^op(2,p) ;
            end if;
        end do  :
        (a+1)/2 ;
    end proc: # R. J. Mathar, May 19 2016
  • Mathematica
    a[n_] := Block[{m = n}, While[ EvenQ@m, m /= 2]; (m + 1)/2]; Array[a, 84] (* or *)
    a[1] = 1; a[n_] := a[n] = If[OddQ@n, (n + 1)/2, a[n/2]]; Array[a, 84] (* Robert G. Wilson v, May 23 2006 *)
    a[n_] := Ceiling[NestWhile[Floor[#/2] &, n, EvenQ]/2]; Array[a, 84] (* Birkas Gyorgy, Apr 05 2011 *)
    a003602 = {1}; max = 7; Do[b = {}; Do[AppendTo[b, {k, a003602[[k]]}], {k, Length[a003602]}]; a003602 = Flatten[b], {n, 2, max}]; a003602 (* L. Edson Jeffery, Nov 21 2015 *)
  • PARI
    A003602(n)=(n/2^valuation(n,2)+1)/2; /* Joerg Arndt, Apr 06 2011 */
    
  • Python
    import math
    def a(n): return (n/2**int(math.log(n - (n & n - 1), 2)) + 1)/2 # Indranil Ghosh, Apr 24 2017
    
  • Python
    def A003602(n): return (n>>(n&-n).bit_length())+1 # Chai Wah Wu, Jul 08 2022
  • Scheme
    (define (A003602 n) (let loop ((n n)) (if (even? n) (loop (/ n 2)) (/ (+ 1 n) 2)))) ;; Antti Karttunen, Feb 04 2015
    

Formula

a(n) = (A000265(n) + 1)/2.
a((2*k-1)*2^m) = k, for m >= 0 and k >= 1. - Robert G. Wilson v, May 23 2006
Inverse Weigh transform of A035528. - Christian G. Bower
G.f.: 1/x * Sum_{k>=0} x^2^k/(1-2*x^2^(k+1) + x^2^(k+2)). - Ralf Stephan, Jul 24 2003
a(2*n-1) = n and a(2*n) = a(n). - Pab Ter (pabrlos2(AT)yahoo.com), Oct 25 2005
a(A118413(n,k)) = A002024(n,k); = a(A118416(n,k)) = A002260(n,k); a(A014480(n)) = A001511(A014480(n)). - Reinhard Zumkeller, Apr 27 2006
Ordinal transform of A001511. - Franklin T. Adams-Watters, Aug 28 2006
a(n) = A249745(A126760(A003961(n))) = A249745(A253887(A048673(n))). That is, this sequence plays the same role for the numbers in array A135764 as A126760 does for the odd numbers in array A135765. - Antti Karttunen, Feb 04 2015 & Jan 19 2016
G.f. satisfies g(x) = g(x^2) + x/(1-x^2)^2. - Robert Israel, Apr 24 2015
a(n) = A181988(n)/A001511(n). - L. Edson Jeffery, Nov 21 2015
a(n) = A025480(n-1) + 1. - R. J. Mathar, May 19 2016
a(n) = A110963(2n-1) = A349135(4*n). - Antti Karttunen, Apr 18 2022
a(n) = (1 + n)/2, for n odd; a(n) = a(n/2), for n even. - David James Sycamore, Jul 28 2022
a(n) = n/2^A001511(n) + 1/2. - Alan Michael Gómez Calderón, Oct 06 2023
a(n) = A123390(A118319(n)). - Flávio V. Fernandes, Mar 02 2025

Extensions

More terms from Pab Ter (pabrlos2(AT)yahoo.com), Oct 25 2005

A113415 Expansion of Sum_{k>0} x^k/(1-x^(2k))^2.

Original entry on oeis.org

1, 1, 3, 1, 4, 3, 5, 1, 8, 4, 7, 3, 8, 5, 14, 1, 10, 8, 11, 4, 18, 7, 13, 3, 17, 8, 22, 5, 16, 14, 17, 1, 26, 10, 26, 8, 20, 11, 30, 4, 22, 18, 23, 7, 42, 13, 25, 3, 30, 17, 38, 8, 28, 22, 38, 5, 42, 16, 31, 14, 32, 17, 55, 1, 44, 26, 35, 10, 50, 26, 37, 8, 38, 20, 65, 11, 50, 30, 41
Offset: 1

Views

Author

Michael Somos, Oct 29 2005

Keywords

Comments

Arithmetic mean between the number of odd divisors (A001227) and their sum (A000593). This fact was essentially found by the algorithmic search of Jon Maiga's Sequence Machine, and is easily seen to be correct when compared to the PARI-program given by the original author. - Antti Karttunen, Dec 07 2021

Crossrefs

Quadrisection of A349916.

Programs

  • Mathematica
    Array[DivisorSum[#, If[OddQ[#], (# + 1)/2, 0] &] &, 79] (* Michael De Vlieger, Dec 08 2021 *)
  • PARI
    a(n)=if(n<1, 0, sumdiv(n, d, if(d%2, (d+1)/2)))

Formula

G.f.: Sum_{k>0} x^k/(1-x^(2k))^2 = Sum_{k>0} k x^(2k-1)/(1-x^(2k-1)).
a(n) = (1/2) * Sum_{d|n} (d+1)*(d mod 2). - Wesley Ivan Hurt, Nov 25 2021 [From PARI prog]
From Antti Karttunen, Dec 07 2021: (Start)
All these formulas, except the last, were found by the Sequence Machine in some form or another:
a(n) = (1/2) * (A000593(n)+A001227(n)).
a(n) = A069734(A000265(n)). [See either Rutherford's or Luschny's formula in A069734]
a(n) = A349371(n) / A001511(n).
a(n) = A349371(A000265(n)) = A336840(A064989(n)).
a(n) = a(2*n) = a(A000265(n)) = A349916(4*n).
(End)

A336840 Inverse Möbius transform of A048673.

Original entry on oeis.org

1, 3, 4, 8, 5, 14, 7, 22, 17, 18, 8, 42, 10, 26, 26, 63, 11, 65, 13, 55, 38, 30, 16, 124, 30, 38, 80, 81, 17, 100, 20, 185, 44, 42, 50, 206, 22, 50, 56, 164, 23, 148, 25, 94, 127, 62, 28, 368, 68, 117, 62, 120, 31, 316, 58, 244, 74, 66, 32, 318, 35, 78, 189, 550, 74, 172, 37, 133, 92, 196, 38, 626, 41, 86, 174, 159
Offset: 1

Views

Author

Antti Karttunen, Aug 07 2020

Keywords

Comments

Arithmetic mean of the number of divisors (A000005) and prime-shifted sigma (A003973), thus a(n) is the average between the number of and the sum of divisors of A003961(n).
The local minima occur on primes p, where p/2 < a(p) <= (p+1).

Crossrefs

Programs

  • PARI
    A048673(n) = { my(f = factor(n)); for(i=1, #f~, f[i, 1] = nextprime(f[i, 1]+1)); (factorback(f)+1)/2; };
    A336840(n) = sumdiv(n,d,A048673(d));
    
  • PARI
    A336840(n) = { my(f = factor(n)); for(i=1, #f~, f[i, 1] = nextprime(f[i, 1]+1)); (1/2)*(numdiv(n)+sigma(factorback(f))); };

Formula

a(n) = Sum_{d|n} A048673(d).
a(n) = (1/2) * (A000005(n) + A003973(n)).
a(n) = A113415(A003961(n)). - Antti Karttunen, Jun 01 2022
a(n) = A349371(A003961(n)) = A364063(A048673(n)). - Antti Karttunen, Nov 30 2024

A349431 Dirichlet convolution of A003602 (Kimberling's paraphrases) with A055615 (Dirichlet inverse of n).

Original entry on oeis.org

1, -1, -1, -1, -2, 1, -3, -1, -1, 2, -5, 1, -6, 3, 4, -1, -8, 1, -9, 2, 6, 5, -11, 1, -2, 6, -1, 3, -14, -4, -15, -1, 10, 8, 12, 1, -18, 9, 12, 2, -20, -6, -21, 5, 4, 11, -23, 1, -3, 2, 16, 6, -26, 1, 20, 3, 18, 14, -29, -4, -30, 15, 6, -1, 24, -10, -33, 8, 22, -12, -35, 1, -36, 18, 4, 9, 30, -12, -39, 2, -1, 20
Offset: 1

Views

Author

Antti Karttunen, Nov 17 2021

Keywords

Comments

Dirichlet convolution of this sequence with A000010 gives A349136, which also proves the formula involving A023900.
Convolution with A000203 gives A349371.

Crossrefs

Sequence A297381 negated.
Cf. A003602, A023900, A055615, A297381, A349432 (Dirichlet inverse), A349433 (sum with it).
Cf. also A000010, A000203, A349136, A349371, and also A349444, A349447.

Programs

  • Mathematica
    k[n_] := (n / 2^IntegerExponent[n, 2] + 1)/2; a[n_] := DivisorSum[n, # * MoebiusMu [#] * k[n/#] &]; Array[a, 100] (* Amiram Eldar, Nov 18 2021 *)
  • PARI
    A003602(n) = (1+(n>>valuation(n,2)))/2;
    A055615(n) = (n*moebius(n));
    A349431(n) = sumdiv(n,d,A003602(n/d)*A055615(d));
    
  • PARI
    A023900(n) = factorback(apply(p -> 1-p, factor(n)[, 1]));
    A349431(n) = if(!bitand(n,n-1),A023900(n),A023900(n)/2);

Formula

a(n) = Sum_{d|n} A003602(n/d) * A055615(d).
a(n) = A023900(n) when n is a power of 2, and a(n) = A023900(n)/2 for all other numbers.
a(n) = -A297381(n).

A349447 Dirichlet convolution of A003602 (Kimberling's paraphrases) with A326937 (Dirichlet inverse of A000265).

Original entry on oeis.org

1, 0, -1, 0, -2, 0, -3, 0, -1, 0, -5, 0, -6, 0, 4, 0, -8, 0, -9, 0, 6, 0, -11, 0, -2, 0, -1, 0, -14, 0, -15, 0, 10, 0, 12, 0, -18, 0, 12, 0, -20, 0, -21, 0, 4, 0, -23, 0, -3, 0, 16, 0, -26, 0, 20, 0, 18, 0, -29, 0, -30, 0, 6, 0, 24, 0, -33, 0, 22, 0, -35, 0, -36, 0, 4, 0, 30, 0, -39, 0, -1, 0, -41, 0, 32, 0, 28
Offset: 1

Views

Author

Antti Karttunen, Nov 19 2021

Keywords

Comments

Dirichlet convolution of this sequence with A264740 is A349371.

Crossrefs

Cf. A000265, A003602, A326937, A349448 (Dirichlet inverse).

Programs

  • Mathematica
    k[n_] := (n/2^IntegerExponent[n, 2] + 1)/2; a[n_] := DivisorSum[n, MoebiusMu[#] * # / 2^IntegerExponent[#, 2] * k[n/#] &]; Array[a, 100] (* Amiram Eldar, Nov 19 2021 *)
  • PARI
    A003602(n) = (1+(n>>valuation(n,2)))/2;
    A006519(n) = (1<A055615(n) = (n*moebius(n));
    A326937(n) = (A055615(n)/A006519(n));
    A349447(n) = sumdiv(n,d,A003602(d)*A326937(n/d));

Formula

a(n) = Sum_{d|n} A003602(d) * A326937(n/d).

A349393 Inverse Möbius transform of A126760.

Original entry on oeis.org

1, 2, 2, 3, 3, 4, 4, 4, 3, 6, 5, 6, 6, 8, 6, 5, 7, 6, 8, 9, 8, 10, 9, 8, 12, 12, 4, 12, 11, 12, 12, 6, 10, 14, 18, 9, 14, 16, 12, 12, 15, 16, 16, 15, 9, 18, 17, 10, 21, 24, 14, 18, 19, 8, 26, 16, 16, 22, 21, 18, 22, 24, 12, 7, 30, 20, 24, 21, 18, 36, 25, 12, 26, 28, 24, 24, 34, 24, 28, 15, 5, 30, 29, 24, 38, 32, 22
Offset: 1

Views

Author

Antti Karttunen, Nov 16 2021

Keywords

Crossrefs

Cf. A347233, A347234, A349390, A349391, A349392, A349395 for other Dirichlet convolutions of A126760. And also A349371.

Programs

  • Mathematica
    f[n_] := 2 * Floor[(m = n/2^IntegerExponent[n, 2]/3^IntegerExponent[n, 3])/6] + Mod[m, 3]; a[n_] := DivisorSum[n, f[#] &]; Array[a, 100] (* Amiram Eldar, Nov 16 2021 *)
  • PARI
    A126760(n) = {n&&n\=3^valuation(n, 3)<A126760
    A349393(n) = sumdiv(n,d,A126760(d));
    
  • PARI
    a(n)=my(a=valuation(n,2),b=valuation(n,3),c=(a+1)*(b+1)); sumdiv(n/3^b>>a,d, d\6*2+d%3)*c; \\ Charles R Greathouse IV, Nov 16 2021

Formula

a(n) = Sum_{d|n} A126760(d).

A349370 Dirichlet convolution of Kimberling's paraphrases (A003602) with itself.

Original entry on oeis.org

1, 2, 4, 3, 6, 8, 8, 4, 14, 12, 12, 12, 14, 16, 28, 5, 18, 28, 20, 18, 38, 24, 24, 16, 35, 28, 48, 24, 30, 56, 32, 6, 58, 36, 60, 42, 38, 40, 68, 24, 42, 76, 44, 36, 108, 48, 48, 20, 66, 70, 88, 42, 54, 96, 92, 32, 98, 60, 60, 84, 62, 64, 148, 7, 108, 116, 68, 54, 118, 120, 72, 56, 74, 76, 176, 60, 126, 136, 80, 30
Offset: 1

Views

Author

Antti Karttunen, Nov 15 2021

Keywords

Crossrefs

Cf. A347954, A347955, A347956, A349136, A349371, A349372, A349373, A349374, A349375, A349390, A349431, A349444, A349447 for Dirichlet convolutions of other sequences with A003602.

Programs

  • Mathematica
    k[n_] := (n / 2^IntegerExponent[n, 2] + 1)/2; a[n_] := DivisorSum[n, k[#] * k[n/#] &]; Array[a, 100] (* Amiram Eldar, Nov 16 2021 *)
  • PARI
    A003602(n) = (1+(n>>valuation(n,2)))/2;
    A349370(n) = sumdiv(n,d,A003602(n/d)*A003602(d));

Formula

a(n) = Sum_{d|n} A003602(n/d) * A003602(d).

A349372 Dirichlet convolution of Kimberling's paraphrases (A003602) with tau (number of divisors, A000005).

Original entry on oeis.org

1, 3, 4, 6, 5, 12, 6, 10, 12, 15, 8, 24, 9, 18, 22, 15, 11, 36, 12, 30, 27, 24, 14, 40, 22, 27, 34, 36, 17, 66, 18, 21, 37, 33, 36, 72, 21, 36, 42, 50, 23, 81, 24, 48, 72, 42, 26, 60, 36, 66, 52, 54, 29, 102, 50, 60, 57, 51, 32, 132, 33, 54, 90, 28, 57, 111, 36, 66, 67, 108, 38, 120, 39, 63, 104, 72, 63, 126, 42, 75
Offset: 1

Views

Author

Antti Karttunen, Nov 15 2021

Keywords

Crossrefs

Cf. A347954, A347955, A347956, A349136, A349370, A349371, A349373, A349374, A349375, A349390, A349431, A349444, A349447 for Dirichlet convolutions of other sequences with A003602.
Cf. also A349392.

Programs

  • Mathematica
    k[n_] := (n / 2^IntegerExponent[n, 2] + 1)/2; a[n_] := DivisorSum[n, k[#] * DivisorSigma[0, n/#] &]; Array[a, 100] (* Amiram Eldar, Nov 16 2021 *)
  • PARI
    A003602(n) = (1+(n>>valuation(n,2)))/2;
    A349372(n) = sumdiv(n,d,A003602(n/d)*numdiv(d));

Formula

a(n) = Sum_{d|n} A003602(n/d) * A000005(d).

A349375 Dirichlet convolution of Kimberling's paraphrases (A003602) with Liouville's lambda.

Original entry on oeis.org

1, 0, 1, 1, 2, 0, 3, 0, 4, 0, 5, 1, 6, 0, 4, 1, 8, 0, 9, 2, 6, 0, 11, 0, 11, 0, 10, 3, 14, 0, 15, 0, 10, 0, 12, 4, 18, 0, 12, 0, 20, 0, 21, 5, 14, 0, 23, 1, 22, 0, 16, 6, 26, 0, 20, 0, 18, 0, 29, 4, 30, 0, 21, 1, 24, 0, 33, 8, 22, 0, 35, 0, 36, 0, 21, 9, 30, 0, 39, 2, 31, 0, 41, 6, 32, 0, 28, 0, 44, 0, 36, 11, 30, 0, 36
Offset: 1

Views

Author

Antti Karttunen, Nov 15 2021

Keywords

Crossrefs

Cf. A347954, A347955, A347956, A349136, A349370, A349371, A349372, A349373, A349374, A349390, A349431, A349444, A349447 for Dirichlet convolutions of other sequences with A003602.
Cf. also A349395.

Programs

  • Mathematica
    k[n_] := (n / 2^IntegerExponent[n, 2] + 1)/2; a[n_] := DivisorSum[n, k[#] * LiouvilleLambda[n/#] &]; Array[a, 100] (* Amiram Eldar, Nov 16 2021 *)
  • PARI
    A003602(n) = (1+(n>>valuation(n,2)))/2;
    A008836(n) = ((-1)^bigomega(n));
    A349375(n) = sumdiv(n,d,A003602(n/d)*A008836(d));

Formula

a(n) = Sum_{d|n} A003602(n/d) * A008836(d).

A349374 Dirichlet convolution of Kimberling's paraphrases (A003602) with squarefree part of n (A007913).

Original entry on oeis.org

1, 3, 5, 4, 8, 15, 11, 6, 12, 24, 17, 20, 20, 33, 42, 7, 26, 36, 29, 32, 58, 51, 35, 30, 29, 60, 34, 44, 44, 126, 47, 9, 90, 78, 94, 48, 56, 87, 106, 48, 62, 174, 65, 68, 110, 105, 71, 35, 54, 87, 138, 80, 80, 102, 146, 66, 154, 132, 89, 168, 92, 141, 153, 10, 172, 270, 101, 104, 186, 282, 107, 72, 110, 168, 167, 116
Offset: 1

Views

Author

Antti Karttunen, Nov 15 2021

Keywords

Crossrefs

Cf. A347954, A347955, A347956, A349136, A349370, A349371, A349372, A349374, A349375, A349390, A349431, A349444, A349447 for Dirichlet convolutions of other sequences with A003602.

Programs

  • Mathematica
    f[p_, e_] := p^Mod[e, 2]; s[1] = 1; s[n_] := Times @@ f @@@ FactorInteger[n]; k[n_] := (n / 2^IntegerExponent[n, 2] + 1)/2; a[n_] := DivisorSum[n, k[#] * s[n/#] &]; Array[a, 100] (* Amiram Eldar, Nov 16 2021 *)
  • PARI
    A003602(n) = (1+(n>>valuation(n,2)))/2;
    A349374(n) = sumdiv(n,d,A003602(n/d)*core(d));

Formula

a(n) = Sum_{d|n} A003602(n/d) * A007913(d).
Showing 1-10 of 13 results. Next