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

A375598 Records of A294336 and A294337.

Original entry on oeis.org

1, 2, 4, 6, 7, 10, 12, 15, 16, 18, 23, 25, 27, 28, 30, 34, 38, 39, 42, 45, 50, 52, 55, 59, 68, 69, 70, 72, 81, 84, 90, 97, 104, 107, 110, 117, 123, 128, 136, 138, 147, 153, 161, 170, 181, 194, 203, 206, 207, 217, 231, 240, 248, 256, 258, 262, 273, 297, 305, 330
Offset: 1

Views

Author

Pontus von Brömssen, Aug 20 2024

Keywords

Crossrefs

Formula

a(n) = A294336(2^A375599(n)).
a(n) = A294337(A375599(n)) for n >= 2.

A294336 Number of ways to write n as a finite power-tower a^(b^(c^...)) of positive integers greater than one.

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1
Offset: 1

Views

Author

Gus Wiseman, Oct 28 2017

Keywords

Comments

Möbius-transform of A294337. - Antti Karttunen, Jun 12 2018

Examples

			The a(4096) = 7 ways are: 2^12, 4^6, 8^4, 8^(2^2), 16^3, 64^2, 4096.
		

Crossrefs

Programs

  • Mathematica
    Array[1+Sum[#0[g],{g,Rest[Divisors[GCD@@FactorInteger[#1][[All,2]]]]}]&,200]
  • PARI
    A052409(n) = { my(k=ispower(n)); if(k, k, n>1); }; \\ From A052409
    A294336(n) = if(1==n,n,sumdiv(A052409(n),d,A294336(d))); \\ Antti Karttunen, Jun 12 2018, after Mathematica-code.

Formula

a(1) = 1; for n > 1, a(n) = Sum_{d|A052409(n)} a(d). - Antti Karttunen, Jun 12 2018, after Mathematica-code.
a(n) = A294337(A052409(n)) for n >= 2. - Pontus von Brömssen, Aug 20 2024

Extensions

More terms from Antti Karttunen, Jun 12 2018

A294338 Number of ways to write n as a finite power-tower of positive integers greater than one, allowing both left and right nesting of parentheses.

Original entry on oeis.org

1, 1, 1, 2, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 2, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 6, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 1, 1
Offset: 1

Views

Author

Gus Wiseman, Oct 28 2017

Keywords

Examples

			The a(16) = 5 ways are: 16, 4^2, (2^2)^2, 2^4, 2^(2^2).
		

Crossrefs

Programs

  • Maple
    A294338 := proc(n)
        local expo,g,a,d ;
        if n =1 then
            return 1;
        end if;
        # compute gcd of the set of prime power exponents (A052409)
        ifactors(n)[2] ;
        [ seq(op(2,ep),ep=%)] ;
        igcd(op(%)) ;
        # set of divisors of A052409 (without the 1)
        g := numtheory[divisors](%) minus {1} ;
        a := 0 ;
        for d in g do
            # recursive (sort of convolution) call
            a := a+ procname(d)*procname(root[d](n)) ;
        end do:
        1+a ;
    end proc:
    seq(A294338(n),n=1..120) ; # R. J. Mathar, Nov 27 2017
  • Mathematica
    a[n_]:=1+Sum[a[n^(1/g)]*a[g],{g,Rest[Divisors[GCD@@FactorInteger[n][[All,2]]]]}];
    Array[a,100]

A294339 Number of ways to write 2^n as a finite power-tower of positive integers greater than one, allowing both left and right nesting of parentheses.

Original entry on oeis.org

1, 2, 2, 5, 2, 6, 2, 12, 5, 6, 2, 19, 2, 6, 6, 32, 2, 19, 2, 19, 6, 6, 2, 56, 5, 6, 12, 19, 2, 26, 2, 79, 6, 6, 6, 71, 2, 6, 6, 56, 2, 26, 2, 19, 19, 6, 2, 169, 5, 19, 6, 19, 2, 56, 6, 56, 6, 6, 2, 101, 2, 6, 19, 203, 6, 26, 2, 19, 6, 26, 2, 237, 2, 6, 19, 19
Offset: 1

Views

Author

Gus Wiseman, Oct 28 2017

Keywords

Examples

			The a(6) = 6 ways are 64, 8^2, (2^3)^2, 4^3, (2^2)^3, 2^6.
		

Crossrefs

Programs

  • Maple
    f:= proc(n) option remember; local F,t,s,g,a;
      F:= ifactors(n)[2];
      g:= igcd(op(map(t -> t[2],F)));
      t:= 1;
      for s in numtheory:-divisors(g) minus {1} do
        t:= t + procname(mul(a[1]^(a[2]/s),a=F))*procname(s)
      od;
      t
    end proc:
    seq(f(2^n),n=1..100); # Robert Israel, Dec 01 2017
  • Mathematica
    a[n_]:=1+Sum[a[n^(1/g)]*a[g],{g,Rest[Divisors[GCD@@FactorInteger[n][[All,2]]]]}];
    Table[a[2^n],{n,100}]

Formula

a(n) = A294338(2^n). - R. J. Mathar, Nov 27 2017

A304481 Turn the power-tower for n upside-down.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 9, 8, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 32, 26, 27, 28, 29, 30, 31, 25, 33, 34, 35, 64, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 128, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 36, 65, 66, 67
Offset: 1

Views

Author

Gus Wiseman, May 13 2018

Keywords

Comments

This is an involution of the positive integers.
The power-tower for n is defined as follows. Let {c(i)} = A007916 denote the sequence of numbers > 1 which are not perfect powers. Every positive integer n has a unique representation as a tower n = c(x_1)^c(x_2)^c(x_3)^...^c(x_k), where the exponents are nested from the right. Then a(n) = c(x_k)^...^c(x_3)^c(x_2)^c(x_1).

Examples

			The power tower of 81 is 3^2^2, which turned upside-down is 2^2^3 = 256, so a(81) = 256.
		

Crossrefs

Programs

  • Maple
    f:= proc(n,r) local F,a,y;
         if n = 1 then return 1 fi;
         F:= ifactors(n)[2];
         y:= igcd(seq(t[2],t=F));
         if y = 1 then return n^r fi;
         a:= mul(t[1]^(t[2]/y),t=F);
         procname(y,a^r)
    end proc:
    seq(f(n,1),n=1..100); # Robert Israel, May 13 2018
  • Mathematica
    tow[n_]:=If[n==1,{},With[{g=GCD@@FactorInteger[n][[All,2]]},If[g===1,{n},Prepend[tow[g],n^(1/g)]]]];
    Table[Power@@Reverse[tow[n]],{n,100}]

A304491 Last or deepest exponent in the power-tower for n.

Original entry on oeis.org

1, 2, 3, 2, 5, 6, 7, 3, 2, 10, 11, 12, 13, 14, 15, 2, 17, 18, 19, 20, 21, 22, 23, 24, 2, 26, 3, 28, 29, 30, 31, 5, 33, 34, 35, 2, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 2, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 6, 65, 66, 67, 68, 69
Offset: 1

Views

Author

Gus Wiseman, May 13 2018

Keywords

Comments

Let {c(i)} = A007916 denote the sequence of numbers > 1 which are not perfect powers. Every positive integer n has a unique representation as a tower n = c(x_1)^c(x_2)^c(x_3)^...^c(x_k), where the exponents are nested from the right. Then a(n) = c(x_k).

Examples

			We have 16 = 2^2^2, so a(16) = 2.
We have 64 = 2^6, so a(64) = 6.
We have 81 = 3^2^2, so a(81) = 2.
We have 256 = 2^2^3, so a(256) = 3.
		

Crossrefs

Programs

  • Mathematica
    a[n_]:=If[n==1,1,With[{g=GCD@@FactorInteger[n][[All,2]]},If[g==1,n,a[g]]]];
    Array[a,100]
  • PARI
    a(n)={my(t=n); while(t, n=t; t=ispower(t)); n} \\ Andrew Howroyd, Aug 26 2018

Formula

a(n) = A007916(A278028(n, A288636(n))).

A304495 Decapitate the power-tower for n, i.e., remove the last (deepest) exponent.

Original entry on oeis.org

0, 1, 1, 2, 1, 1, 1, 2, 3, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 5, 1, 3, 1, 1, 1, 1, 2, 1, 1, 1, 6, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 7, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 9, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 10, 1, 1, 1, 1, 1
Offset: 1

Views

Author

Gus Wiseman, May 13 2018

Keywords

Comments

a(1) = 0 by convention.
Let {c(i)} = A007916 denote the sequence of numbers > 1 which are not perfect powers. Every positive integer n has a unique representation as a tower n = c(x_1)^c(x_2)^c(x_3)^...^c(x_k), where the exponents are nested from the right. Then a(n) = c(x_1)^c(x_2)^c(x_3)^...^c(x_{k-1}).

Examples

			We have 64 = 2^6, so a(64) = 2.
We have 216 = 6^3, so a(216) = 6.
We have 256 = 2^2^3, so a(256) = 2^2 = 4.
		

Crossrefs

Programs

  • Mathematica
    tow[n_]:=If[n==1,{},With[{g=GCD@@FactorInteger[n][[All,2]]},If[g===1,{n},Prepend[tow[g],n^(1/g)]]]];
    Table[If[n==1,0,Power@@Most[tow[n]]],{n,100}]
  • PARI
    A304495(n) = if(1==n,0,my(e, r, tow = List([])); while((e = ispower(n,,&r)) > 1, listput(tow, r); n = e;); n = 1; while(length(tow)>0, e = tow[#tow]; listpop(tow); n = e^n;); (n)); \\ Antti Karttunen, Jul 23 2018

Formula

a(m) <> 1 if m is a perfect power (A001597). - Michel Marcus, Jul 23 2018

Extensions

Name edited and more terms from Antti Karttunen, Jul 23 2018

A304492 Position in the sequence of numbers that are not perfect powers (A007916) of the last or deepest exponent in the power-tower for n.

Original entry on oeis.org

1, 2, 3, 2, 4, 5, 6, 3, 2, 7, 8, 9, 10, 11, 12, 2, 13, 14, 15, 16, 17, 18, 19, 20, 2, 21, 3, 22, 23, 24, 25, 4, 26, 27, 28, 2, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 2, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 5, 55, 56, 57, 58, 59, 60
Offset: 1

Views

Author

Gus Wiseman, May 13 2018

Keywords

Comments

Let {c(i)} = A007916 denote the sequence of numbers > 1 which are not perfect powers. Every positive integer n has a unique representation as a tower n = c(x_1)^c(x_2)^c(x_3)^...^c(x_k), where the exponents are nested from the right. Then a(n) = x_k.

Crossrefs

Programs

  • Mathematica
    nn=100;
    a[n_]:=If[n==1,1,With[{g=GCD@@FactorInteger[n][[All,2]]},If[g==1,n,a[g]]]];
    rads=Union[Array[a,nn]];
    Table[a[n],{n,nn}]/.Table[rads[[i]]->i,{i,Length[rads]}]

Formula

a(n) = A278028(n, A288636(n)).

A375599 The n-th record of A294336 occur at index 2^a(n).

Original entry on oeis.org

0, 2, 4, 8, 12, 16, 32, 48, 64, 96, 144, 240, 288, 360, 432, 576, 720, 1260, 1296, 1440, 2160, 2520, 2880, 3600, 5040, 7200, 7560, 8640, 10080, 14400, 15120, 20160, 25200, 30240, 40320, 45360, 50400, 55440, 75600, 90720, 100800, 110880, 151200, 166320, 221760
Offset: 1

Views

Author

Pontus von Brömssen, Aug 20 2024

Keywords

Comments

Also, indices of records of A294337, starting at A294337(0) = 1.

Crossrefs

Formula

A294336(2^a(n)) = A375598(n).
A294337(a(n)) = A375598(n) for n >= 2.
Showing 1-9 of 9 results.