|
|
A245631
|
|
Least number k such that n concatenated with k produces a cube.
|
|
6
|
|
|
25, 7, 43, 913, 12, 4, 29, 5184, 261, 648, 7649, 5, 31, 8877, 625, 6375, 28, 5193, 683, 5379, 6, 6981, 8328, 389, 15456, 2144, 44, 7496, 791, 48625, 4432, 768, 75, 3, 937, 52264, 3248, 9017, 304, 96, 73281, 875, 8976, 10944, 6533, 656, 4552, 26809, 13, 653, 2, 68024, 1441, 872, 1368, 39752, 1787, 32, 319
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
LINKS
|
|
|
EXAMPLE
|
20, 21, 22, 23, 24, 25, and 26 are not cubes. 27 is a cube. Thus a(2) = 7.
|
|
MATHEMATICA
|
lnc[n_]:=Module[{k=1}, While[!IntegerQ[Surd[n*10^IntegerLength[k]+k, 3]], k++]; k]; Array[lnc, 60] (* Harvey P. Dale, Aug 08 2019 *)
|
|
PROG
|
(PARI)
a(n)=p=""; for(k=0, 10^6, p=concat(Str(n), Str(k)); if(ispower(eval(p))&&ispower(eval(p))%3==0, return(k)))
n=1; while(n<100, print1(a(n), ", "); n++)
(Python)
from sympy import integer_nthroot
m = 10*n
if integer_nthroot(m, 3)[1]: return 0
a = 1
while (k:=(integer_nthroot(a*(m+1)-1, 3)[0]+1)**3-m*a)>=10*a:
a *= 10
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|