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.

A319440 Squares of non-palindromic number.

This page as a plain text file.
%I A319440 #21 Oct 28 2024 17:08:51
%S A319440 100,144,169,196,225,256,289,324,361,400,441,529,576,625,676,729,784,
%T A319440 841,900,961,1024,1156,1225,1296,1369,1444,1521,1600,1681,1764,1849,
%U A319440 2025,2116,2209,2304,2401,2500,2601,2704,2809,2916,3136,3249,3364,3481,3600,3721,3844
%N A319440 Squares of non-palindromic number.
%H A319440 Seiichi Manyama, <a href="/A319440/b319440.txt">Table of n, a(n) for n = 1..10000</a>
%F A319440 a(n) = A029742(n)^2.
%t A319440 palQ[n_]:=Module[{idn=IntegerDigits[n]}, idn==Reverse[idn]]; DeleteCases[Range[10, 110],_?palQ]^2 (* _Vincenzo Librandi_, Sep 19 2018 *)
%o A319440 (Magma) [n^2: n in [0..65] | Intseq(n) ne Reverse(Intseq(n))]; // _Vincenzo Librandi_, Sep 19 2018
%o A319440 (Python)
%o A319440 def A319440(n):
%o A319440     def f(x): return n+x//10**((l:=len(s:=str(x)))-(k:=l+1>>1))-(int(s[k-1::-1])>x%10**k)+10**(k-1+(l&1^1))-1
%o A319440     m, k = n, f(n)
%o A319440     while m != k: m, k = k, f(k)
%o A319440     return m**2 # _Chai Wah Wu_, Oct 28 2024
%Y A319440 Cf. A000290, A002113, A029742, A319388, A319441.
%K A319440 nonn,base,easy
%O A319440 1,1
%A A319440 _Seiichi Manyama_, Sep 19 2018