cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A384095 Numbers other than {10^a + 10^b + 1} and {10^a + 5*10^b, min(a, b) = 0} whose square has digit sum 9 and no trailing zero.

This page as a plain text file.
%I A384095 #14 Jun 19 2025 17:02:58
%S A384095 9,18,39,45,48,249,318,321,348,351,549,1149,1761,4899,10149,14499,
%T A384095 375501
%N A384095 Numbers other than {10^a + 10^b + 1} and {10^a + 5*10^b, min(a, b) = 0} whose square has digit sum 9 and no trailing zero.
%C A384095 The definition excludes the two "regular" subsequences of A384094, namely A052216+1 = 3*A237424 and A133472 U A199685, which provide most of its terms.
%C A384095 Is it true that no number > 1049 = A215614(6) has a square with digit sum less than 9, other than the trivial 1 and 4?
%C A384095 The next term, if it exists, is a(18) > 10^8.
%C A384095 a(18) > 10^14 if it exists. - _Robert Israel_, Jun 15 2025
%C A384095 a(18) > 10^40 if it exists. - _Chai Wah Wu_, Jun 19 2025
%p A384095 extend:= proc(a,d) local i,s;
%p A384095     s:= convert(convert(a,base,10),`+`);
%p A384095     op(select(t -> numtheory:-quadres(t,10^d)=1, [seq(i*10^(d-1)+a, i=0 .. 9 - s)]))
%p A384095 end proc:
%p A384095 istriv:= proc(n) local L;
%p A384095    L:= subs(0=NULL,convert(n,base,10));
%p A384095    member(L, [[4],[5],[6],[1,1],[1,1,1],[1,2],[2,1],[1,5],[5,1]])
%p A384095 end proc:
%p A384095 R:= NULL:
%p A384095 A:= [1,4,5,6,9]:
%p A384095 for d from 2 to 20 do
%p A384095   A:= map(extend,A,d);
%p A384095   V:= select(t -> t > 10^(d-1) and issqr(t) and convert(convert(t,base,10),`+`)=9, A);
%p A384095   if V <> [] then V:= sort(remove(istriv,map(sqrt,V))); R:= R,op(V); fi
%p A384095 od:
%p A384095 R;# _Robert Israel_, Jun 15 2025
%o A384095 (PARI) select( {is_A384095(n)=n%10 && sumdigits(n^2)==9 && !bittest(36938, fromdigits(Set(digits(n))))}, [1..10^5])
%Y A384095 Cf. A004159 (sum of digits of n^2), A384094 (sumdigits(n^2) = 9), A133472 (10^n+5), A199685 (5*10^n + 1), A052216 (10^a+10^b), A237424 ((10^a+10^b+1)/3).
%Y A384095 See also: A215614 (sumdigits(n^2) = 7), A058414 (digits(n²) ⊂ {0,1,4}).
%K A384095 nonn,base,hard,more
%O A384095 1,1
%A A384095 _M. F. Hasler_, Jun 15 2025