OFFSET
1,2
FORMULA
a(n) = ceiling(10^((n-1)/3))^3. - Antonio G. Astudillo (afg_astudillo(AT)lycos.com), Mar 30 2003
EXAMPLE
a(4) = 1000 = 10^3 has 4 digits while 9^3 = 729 has 3 digits.
MAPLE
A061434 := n->ceil(10^((n-1)/3))^3;
MATHEMATICA
Table[Ceiling[Surd[10^n, 3]]^3, {n, 0, 20}] (* Harvey P. Dale, Oct 09 2023 *)
PROG
(Python)
from sympy import integer_nthroot
def a(n):
r, exact = integer_nthroot(10**(n-1), 3)
return 10**(n-1) if exact else (r+1)**3
print([a(n) for n in range(1, 21)]) # Michael S. Branicky, Jan 27 2021
(PARI) a(n) = ceil(10^((n-1)/3))^3; \\ Michel Marcus, Jan 27 2021
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
Amarnath Murthy, May 03 2001
EXTENSIONS
More terms from Larry Reeves (larryr(AT)acm.org), May 16 2001
More terms from Antonio G. Astudillo (afg_astudillo(AT)lycos.com), Mar 30 2003
STATUS
approved