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.
%I A003226 M3752 #173 Mar 14 2025 17:26:14 %S A003226 0,1,5,6,25,76,376,625,9376,90625,109376,890625,2890625,7109376, %T A003226 12890625,87109376,212890625,787109376,1787109376,8212890625, %U A003226 18212890625,81787109376,918212890625,9918212890625,40081787109376,59918212890625,259918212890625,740081787109376 %N A003226 Automorphic numbers: m^2 ends with m. %C A003226 Also called curious numbers. %C A003226 For entries after the second, two successive terms sum up to a total having the form 10^n + 1. - _Lekraj Beedassy_, Apr 29 2005 [This comment is clearly wrong as stated. The sums of two consecutive terms are 1, 6, 11, 31, 101, 452, 1001, 10001, 100001, 200001, 1000001, 3781250, .... - _T. D. Noe_, Nov 14 2010] %C A003226 If a d-digit number n is in the sequence, then so is 10^d+1-n. However, the same number can be 10^d+1-n for different n in the sequence (e.g., 10^3+1-376 = 10^4+1-9376 = 625), which spoils Beedassy's comment. - _Robert Israel_, Jun 19 2015 %C A003226 Substring of both its square and its cube not congruent to 0 (mod 10). See A029943. - _Robert G. Wilson v_, Jul 16 2005 %C A003226 a(n)^k ends with a(n) for k > 0; see also A029943. - _Reinhard Zumkeller_, Nov 26 2011 %C A003226 Apart from initial term, a subsequence of A046831. - _M. F. Hasler_, Dec 05 2012 %C A003226 This is also the sequence of numbers such that the n-th m-gonal number ends in n for any m == 0,4,8,16 (mod 20). - _Robert Dawson_, Jul 09 2018 %C A003226 Apart from 6, a subsequence of A301912. - _Robert Dawson_, Aug 01 2018 %D A003226 J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 76, p. 26, Ellipses, Paris 2008. %D A003226 V. deGuerre and R. A. Fairbairn, Automorphic numbers, J. Rec. Math., 1 (No. 3, 1968), 173-179. %D A003226 R. A. Fairbairn, More on automorphic numbers, J. Rec. Math., 2 (No. 3, 1969), 170-174. %D A003226 Jan Gullberg, Mathematics, From the Birth of Numbers, W. W. Norton & Co., NY, page 253-254. %D A003226 B. A. Naik, 'Automorphic numbers' in 'Science Today'(subsequently renamed '2001') May 1982 pp. 59, Times of India, Mumbai. %D A003226 Ya. I. Perelman, Algebra can be fun, pp. 97-98. %D A003226 Clifford A. Pickover, A Passion for Mathematics, John Wiley & Sons, Hoboken, 2005, p. 64. %D A003226 C. P. Schut, Idempotents. Report AM-R9101, Centrum voor Wiskunde en Informatica, Amsterdam, 1991. %D A003226 N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence). %H A003226 Chai Wah Wu, <a href="/A003226/b003226.txt">Table of n, a(n) for n = 1..1786</a> (terms n = 1..200 from Vincenzo Librandi) %H A003226 Robert Dawson, <a href="https://www.emis.de/journals/JIS/VOL21/Dawson/dawson6.html">On Some Sequences Related to Sums of Powers</a>, J. Int. Seq., Vol. 21 (2018), Article 18.7.6. %H A003226 R. A. Fairbairn, <a href="/A003226/a003226_1.pdf">More on automorphic numbers</a>, J. Rec. Math., 2.3 (1969), 170-174. (Annotated scanned copy) %H A003226 V. deGuerre & R. A. Fairbairn, <a href="/A003226/a003226.pdf">Automorphic numbers</a>, J. Rec. Math., 1.3 (1968), 173-179 %H A003226 M. Beeler, R. W. Gosper, and R. Schroeppel, <a href="http://w3.pppl.gov/~hammett/work/2009/AIM-239-ocr.pdf">HAKMEM</a>. MIT AI Memo 239, Feb 29 1972 (Item 59 provides a 40-digit member of this sequence). %H A003226 Shyam Sunder Gupta, <a href="https://doi.org/10.1007/978-981-97-2465-9_2">Elegance of Squares, Cubes, and Higher Powers</a>, Exploring the Beauty of Fascinating Numbers, Springer (2025) Ch. 2, 29-81. %H A003226 W. Schneider, <a href="http://web.archive.org/web/2004/www.wschnei.de/digit-related-numbers/automorphic-numbers.html">Automorphic Numbers</a> %H A003226 C. P. Schut, <a href="/A007185/a007185.pdf">Idempotents</a>, Report AM-R9101, Centre for Mathematics and Computer Science, Amsterdam, 1991. (Annotated scanned copy) %H A003226 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/AutomorphicNumber.html">Automorphic Number</a> %H A003226 Wikipedia, <a href="http://en.wikipedia.org/wiki/Automorphic_number">Automorphic number</a> %H A003226 Xiaolong Ron Yu, <a href="http://www.pme-math.org/journal/issues/PMEJ.Vol.10.No.10.pdf">Curious Numbers</a>, Pi Mu Epsilon Journal, Spring 1999, pp. 819-823. %H A003226 <a href="/index/Ar#automorphic">Index entries for sequences related to automorphic numbers</a> %F A003226 Equals {0, 1} union A007185 union A016090. %p A003226 V:= proc(m) option remember; %p A003226 select(t -> t^2 - t mod 10^m = 0, map(s -> seq(10^(m-1)*j+s, j=0..9), V(m-1))) %p A003226 end proc: %p A003226 V(0):= {0,1}: %p A003226 V(1):= {5,6}: %p A003226 sort(map(op,[V(0),seq(V(i) minus V(i-1),i=1..50)])); # _Robert Israel_, Jun 19 2015 %t A003226 f[k_] := (r = Reduce[0 < 10^k < n < 10^(k + 1) && n^2 == m*10^(k + 1) + n, {n, m}, Integers]; If[Head[r] === And, n /. ToRules[r], n /. {ToRules[r]}]); Flatten[ Join[{0, 1}, Table[f[k], {k, 0, 13}]]] (* _Jean-François Alcover_, Dec 01 2011 *) %t A003226 Union@ Join[{1}, Array[PowerMod[5, 2^#, 10^#] &, 16, 0], Array[PowerMod[16, 5^#, 10^#] &, 16, 0]] (* _Robert G. Wilson v_, Jul 23 2018 *) %o A003226 (Haskell) %o A003226 import Data.List (isSuffixOf) %o A003226 a003226 n = a003226_list !! (n-1) %o A003226 a003226_list = filter (\x -> show x `isSuffixOf` show (x^2)) a008851_list %o A003226 -- _Reinhard Zumkeller_, Jul 27 2011 %o A003226 (PARI) is_A003226(n)={n<2 || 10^valuation(n^2-n,10)>n} \\ _M. F. Hasler_, Dec 05 2012 %o A003226 (PARI) A003226(n)={ n<3 & return(n-1); my(i=10,j=10,b=5,c=6,a=b); for( k=4,n, while(b<=a, b=b^2%i*=10); while(c<=a, c=(2-c)*c%j*=10); a=min(b,c)); a } \\ _M. F. Hasler_, Dec 06 2012 %o A003226 (Sage) %o A003226 def automorphic(maxdigits, pow, base=10) : %o A003226 morphs = [[0]] %o A003226 for i in range(maxdigits): %o A003226 T=[d*base^i+x for x in morphs[-1] for d in range(base)] %o A003226 morphs.append([x for x in T if x^pow % base^(i+1) == x]) %o A003226 res = list(set(sum(morphs, []))); res.sort() %o A003226 return res %o A003226 # call with pow=2 for this sequence, _Eric M. Schmidt_, Feb 09 2014 %o A003226 (Magma) [n: n in [0..10^7] | Intseq(n^2)[1..#Intseq(n)] eq Intseq(n)]; // _Vincenzo Librandi_, Jul 03 2015 %o A003226 (Python) %o A003226 from itertools import count, islice %o A003226 from sympy.ntheory.modular import crt %o A003226 def A003226_gen(): # generator of terms %o A003226 a = 0 %o A003226 yield from (0,1) %o A003226 for n in count(0): %o A003226 b = sorted((int(crt(m:=(1<<n,5**n),(0,1))[0]), int(crt(m,(1,0))[0]))) %o A003226 if b[0] > a: %o A003226 yield from b %o A003226 a = b[1] %o A003226 elif b[1] > a: %o A003226 yield b[1] %o A003226 a = b[1] %o A003226 A003226_list = list(islice(A003226_gen(),15)) # _Chai Wah Wu_, Jul 25 2022 %Y A003226 Cf. A008851, A018247, A018248, A018834, A033819, A035383, A046831, A052228. %K A003226 nonn,base,nice,easy %O A003226 1,3 %A A003226 _N. J. A. Sloane_ %E A003226 More terms from _Michel ten Voorde_, Apr 11 2001 %E A003226 Edited by _David W. Wilson_, Sep 26 2002 %E A003226 Incorrect statement removed from title by _Robert Dawson_, Jul 09 2018