login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A303370 Least integer k such that (k+1)^k >= n. 1
0, 0, 1, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,4

COMMENTS

n -> a(n+1) is a left inverse for A152917 and also, just like n -> a(n)+1, a left inverse to A000169(n) = n^(n-1), with codomain = the positive integers.

a(n+1) is also the smallest m such that n can be written with at most m digits in base m+1. For example, the largest number that can be written with 2 digits in base 3 is 8 = 22[3], to write 9 we need to switch to a(9+1) = 3 digits in base 4. Similarly, 63 is the largest number that can be written with a(63+1) = 3 digits in base 4, and from 64 on we need to go to a(64+1) = 4 digits in base 5.

There is no doubt that k must be nonnegative, except for the case n = 0, for which we do not want to consider all negative even k which would also satisfy the inequality, and therefore require k >= 0 to get a well defined solution.

First occurrence of k = 0, 1, 2, ...: 0, 2, 3, 10, 65, 626, 7777, 117650, ... = A124923. - Robert G. Wilson v, Apr 29 2018

LINKS

Robert Israel, Table of n, a(n) for n = 0..10000

EXAMPLE

(0+1)^0 = 1 >= 0, therefore a(0) = 0.

(0+1)^0 = 1 >= 1, therefore a(1) = 0.

(0+1)^0 = 1 < 2, but (1+1)^1 = 2 >= 2, therefore a(2) = 1.

(1+1)^1 = 2 < 3, but (2+1)^2 = 9 >= 3, therefore a(n) = 2 for 3 <= n <= 9.

(2+1)^2 = 9 < 10, but (3+1)^3 = 64 >= 10, therefore a(n) = 3 for 10 <= k <= 64.

(3+1)^3 = 64 < 65, but (4+1)^4 = 625 >= 65, therefore a(n) = 4 for 65 <= k <= 625.

MAPLE

A:= Array(0..5^4):

w:= 0:

for k from 0 to 4 do

  v:= (k+1)^k;

  A[w..v]:= k;

  w:= v+1

od:

seq(A[i], i=0..5^4); # Robert Israel, Apr 30 2018

MATHEMATICA

f[n_] := Block[{k = 0}, While[(k + 1)^k < n, k++]; k]; Array[f, 105, 0] (* Robert G. Wilson v, Apr 29 2018 *)

PROG

(PARI) a(n, k=ceil(solve(k=0, log(n+1), (k+1)^k-n)))=k-(k&&k^(k-1)>=n) \\ Corrective term in case ceil() incorrectly rounded up.

CROSSREFS

Cf. A000169, A152917.

Sequence in context: A174373 A232270 A191517 * A082528 A055980 A076080

Adjacent sequences:  A303367 A303368 A303369 * A303371 A303372 A303373

KEYWORD

nonn

AUTHOR

M. F. Hasler, Apr 26 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 | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified February 28 01:38 EST 2020. Contains 332319 sequences. (Running on oeis4.)