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.

Showing 1-3 of 3 results.

A075786 Palindromic perfect powers.

Original entry on oeis.org

1, 4, 8, 9, 121, 343, 484, 676, 1331, 10201, 12321, 14641, 40804, 44944, 69696, 94249, 698896, 1002001, 1030301, 1234321, 1367631, 4008004, 5221225, 6948496, 100020001, 102030201, 104060401, 121242121, 123454321, 125686521, 400080004, 404090404, 522808225, 617323716, 942060249
Offset: 1

Views

Author

Zak Seidov, Oct 10 2002

Keywords

Comments

Up to 10^12, there are only 43 perfect powers which are palindromic.
The sequence is infinite, for instance it contains (10^k+1)^2. - Emmanuel Vantieghem, Sep 29 2017
Conjecture: there are no palindromic perfect powers with prime exponent > 3. - Chai Wah Wu, Aug 26 2021

Examples

			343 = 7^3 is a term as it is a palindrome and a perfect power. - _David A. Corneth_, Mar 23 2021
		

Crossrefs

Programs

  • Mathematica
    a = {}; Do[q = IntegerDigits[n]; p = FromDigits[ Join[ q, Reverse[ Drop[q, -1]]]]; If[ Apply[ GCD, Last[ Transpose[ FactorInteger[p]]]] > 1, a = Append[a, p]]; p = FromDigits[ Join[ q, Reverse[q]]]; If[ Apply[ GCD, Last[ Transpose[ FactorInteger[p]]]] > 1, a = Append[a, p]], {n, 1, 10^5}]
  • Python
    from math import isqrt
    def ispal(n): s = str(n); return s == s[::-1]
    def athrough(digits):
      found, limit = {1}, 10**digits
      for k in range(2, isqrt(limit) + 1):
        kpow = k*k
        while kpow < limit:
          if ispal(kpow): found.add(kpow)
          kpow *= k
      return sorted(found)
    print(athrough(9)) # Michael S. Branicky, Mar 23 2021

Extensions

Edited and extended by Robert G. Wilson v, Oct 11 2002
More terms from David A. Corneth, Mar 24 2021
b-file corrected and extended by Chai Wah Wu, Aug 26 2021

A342942 Numbers whose palindromization is a perfect power.

Original entry on oeis.org

12, 13, 34, 48, 67, 102, 123, 146, 408, 449, 696, 698, 942, 1002, 1030, 1234, 1367, 4008, 5221, 6948, 10002, 10030, 10203, 10406, 12124, 12345, 12568, 40008, 40409, 52280, 61732, 94206, 100002, 102214, 106625, 121024, 123456, 400008, 637832, 1000002, 1000300, 1002003
Offset: 1

Views

Author

Michel Marcus, Mar 30 2021

Keywords

Comments

Palindromization is the function that extends the string representation of a number into a palindrome.
Even palindromization is the concatenation of a number and its reversal. Odd palindromization excludes the first digit of the reversal.

Examples

			12 is a term because 121 is a square.
13 is a term because 1331 is a cube.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[10,50000],Or@@(GCD@@Last/@FactorInteger@#>1&/@FromDigits/@(Join[a,Reverse@#]&/@{a=IntegerDigits@#,Most@a}))&] (* Giorgos Kalogeropoulos, Mar 30 2021 *)
  • PARI
    rev(x) = strjoin(Vecrev(Str(x)));
    isok(m) = ispower(eval(Str(m, rev(m)))) || ispower(eval(Str(m, rev(m\10))));

A342803 Primes p whose palindromization A082216(p) is a square or higher power.

Original entry on oeis.org

67, 449, 1367, 10303, 12343, 1003003, 1022141, 1230127, 1234543, 4004009, 121200307, 10022234347, 10201204021, 10203242527, 12100242001, 13310399303, 16151080151, 52281509069, 61584539747, 90608667517, 104190107303, 1020102040201, 1022143262341, 12384043938083
Offset: 1

Views

Author

Lamine Ngom, Mar 22 2021

Keywords

Comments

Palindromization is the function that minimally extends the string representation of a number into a palindrome (see A082216).
Are 13 and 1367 the unique terms leading to cubes or higher powers?
It seems that 13 is the unique prime whose even palindromization (the concatenation of a number and its reversal) is a square or higher power.
The next term (if it exists) is greater than 10^17.

Examples

			The prime 449 belongs to sequence because 44944 is a square: 212^2.
The prime 1367 is in the sequence since 1367631 is a cube: 111^3.
The prime 13 is not a term as A082216(13) = 131 and 131 is prime. The prime 10303 is in the sequence since 1030301 is a cube: 101^3. - _Chai Wah Wu_, Aug 26 2021
		

Crossrefs

Cf. A082216 (smallest palindrome beginning with n).
Subsequence of primes of A342942.

Programs

  • Mathematica
    Select[Prime@Range@100000,Or@@(GCD@@Last/@FactorInteger@#>1&/@(FromDigits/@(Join[a,Reverse@#]&/@{a=IntegerDigits@#,Most@a})))&] (* Giorgos Kalogeropoulos, Mar 31 2021 *)

Extensions

Corrected terms and missing terms added by Chai Wah Wu, Aug 26 2021
Showing 1-3 of 3 results.