login
A368088
Index of smallest pentagonal number with n digits.
0
1, 3, 9, 26, 82, 259, 817, 2583, 8166, 25821, 81650, 258200, 816497, 2581990, 8164966, 25819890, 81649659, 258198890, 816496582, 2581988898, 8164965810, 25819888975, 81649658093, 258198889748, 816496580928, 2581988897472, 8164965809278, 25819888974717, 81649658092773
OFFSET
1,2
COMMENTS
The digits of the odd- and even-indexed terms converge to those in the decimal expansions of sqrt(2/3) and sqrt(20/3), respectively.
FORMULA
a(n) = ceiling((sqrt(24*10^(n-1) + 1) + 1)/6).
EXAMPLE
a(4) = 26 as the 26th pentagonal number is 26*(3*26-1)/2 = 1001 which has 4 digits (while the 25th is 925 which is only 3).
MATHEMATICA
a[n_] := Ceiling[(Sqrt[24*10^(n-1) + 1] + 1)/6]; Array[a, 40] (* Amiram Eldar, Dec 30 2023 *)
PROG
(PARI) a(n) = 1 + (sqrtint(24*10^(n-1)) + 1)\6 \\ Andrew Howroyd, Dec 30 2023
CROSSREFS
Cf. A068092 (for triangular numbers), A017936 (for squares).
Cf. A157697 (square root of 2/3), A020772 (square root of 20/3)
Sequence in context: A295115 A114982 A133405 * A196952 A148921 A148922
KEYWORD
nonn,easy,base
AUTHOR
Kelvin Voskuijl, Dec 17 2023
STATUS
approved