login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A304495 Decapitate the power-tower for n, i.e., remove the last (deepest) exponent. 4
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 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,4
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}).
LINKS
FORMULA
a(m) <> 1 if m is a perfect power (A001597). - Michel Marcus, Jul 23 2018
EXAMPLE
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.
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}]
PROG
(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
CROSSREFS
Sequence in context: A131256 A362414 A245562 * A175069 A245563 A356917
KEYWORD
nonn
AUTHOR
Gus Wiseman, May 13 2018
EXTENSIONS
Name edited and more terms from Antti Karttunen, Jul 23 2018
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 02:53 EDT 2024. Contains 371906 sequences. (Running on oeis4.)