OFFSET
0,2
COMMENTS
Subsequent terms are too large to display in full.
a(8) = 3789 * 10^973 - 1 (3788 followed by 973 9's).
a(9) = 78889 * 10^((a(8) - 305)/81) - 1 (78888 followed by (421 * 10^973 - 34)/9 9's, specified by Warut Roonguthai for UPINT3).
a(10) = 259 * 10^((a(9) - 93)/81) - 1.
a(11) = 179 * 10^((a(10) - 114)/81) - 1.
a(12) = 47 * 10^((a(11) - 52)/81) - 1.
From Ya-Ping Lu, Jul 26 2025: (Start)
a(13) = 137 * 10^((a(12) - 46)/81) - 1.
a(14) = 1128 * 10^((a(13) - 55)/81) - 1.
a(15) = 58 * 10^((a(14) - 74)/81) - 1.
a(16) = 228 * 10^((a(15) - 57)/81) - 1. (End)
REFERENCES
Richard K. Guy, Unsolved Problems in Number Theory, Sect. E34. (2nd ed. UPINT2 = 1994, 3rd ed. UPINT3 = 2004)
LINKS
Tianxin Cai and Xia Zhou, On The Heights of Happy Numbers, Rocky Mountain J. Math., Vol. 38, No. 6 (2008), 1921-1926.
H. G. Grundman and E. A. Teeple, Heights of happy numbers and cubic happy numbers, Fib Quart. 41 (4) (2003) 301-306.
Hans Havermann, Big and Happy
Gabriel Lapointe, On finding the smallest happy numbers of any heights, arXiv:1904.12032 [math.NT], 2019.
May Mei and Andrew Read-McFarland, Numbers and the Heights of their Happiness, arXiv:1511.01441 [math.NT], 2015.
FORMULA
For n >= 7, a(n) = k(n)*10^((a(n-1)-A003132(k(n)-1))/81)-1, where k(n) = 79, 3789, 78889, 259, 179, 47, 137, 1128, 58, 228, 19, 34, 145 for n = 7, 8,.., 19. - Ya-Ping Lu, Jul 27 2025
PROG
(Python)
f = lambda h: sum(int(d)**2 for d in str(h)); a = 356; n_mx = 19
for n in range(7, n_mx+1):
b = a%81; a1 = max(a%(2*3**(3*(n_mx+1-n))), b); t = max(a1//81-6, 0); h = 1
while f((h+1)*10**t - 1) != a1:
h += 1; s = str(h)
if '0' in s: p0 = s.index('0'); c = 10**(len(s)-p0); h = h//c*c + int(s[p0-1])*(c-1)//9
c9 = str(h).count('9'); hc = h//(10**c9); a = (hc+1)*10**((a1-f(hc))//81)-1
print('a(', n, ') =', hc+1, 'x 10 ^ ( ( a(', n-1, ') -', f(hc), ') / 81) - 1') # Ya-Ping Lu, Jul 26 2025
CROSSREFS
KEYWORD
nonn,base
AUTHOR
EXTENSIONS
a(7), a(8) from Jud McCranie, Sep 15 1994
a(9)-a(12) from Hans Havermann, May 02 2010
Edited by Hans Havermann, May 03 2010, May 04 2010
STATUS
approved
