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.

Previous Showing 11-15 of 15 results.

A030074 Squares which are palindromes in base 14.

Original entry on oeis.org

0, 1, 4, 9, 225, 576, 900, 2209, 27225, 38809, 44521, 50625, 57121, 155236, 166464, 178084, 4796100, 5978025, 7535025, 8732025, 10017225, 30140100, 32490000, 73359225, 1475865889, 1490963769, 1506138481, 1521390025
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    pb14Q[n_]:=Module[{idn14=IntegerDigits[n, 14]}, idn14==Reverse[idn14]]; Select[Range[0, 20000]^2, pb14Q] (* Vincenzo Librandi, Jul 24 2014 *)

A030075 Squares which are palindromes in base 15.

Original entry on oeis.org

0, 1, 4, 9, 16, 64, 144, 256, 361, 1024, 1521, 4096, 5776, 16384, 20736, 51076, 58081, 65536, 73441, 96721, 204304, 218089, 228484, 232324, 331776, 511225, 817216, 929296, 1048576, 3055504, 3268864, 3489424, 5308416, 7033104
Offset: 1

Views

Author

Keywords

Examples

			8^2 = 64, which in base 15 is 44, and that's palindromic, so 64 is in the sequence.
9^2 = 81, which in base 15 is 56. Since that's not palindromic, 81 is not in the sequence.
		

Crossrefs

Programs

  • Maple
    N:= 10^10: # to get all entries <= N
    count:= 0:
    for x from 0 to floor(sqrt(N)) do
        y:= x^2;
        L:= convert(y,base,15);
      if ListTools[Reverse](L) = L then
         count:= count+1;
         A[count]:= y;
       fi
    od:
    seq(A[i],i=1..count); # Robert Israel, Jul 24 2014
  • Mathematica
    palQ[n_, b_:10] := Module[{idn = IntegerDigits[n, b]}, idn == Reverse[idn]]; Select[Range[0, 2700]^2, palQ[#, 15] &]  (* Harvey P. Dale, Apr 23 2011 *)
  • PARI
    isok(n) = my(d=digits(n,15)); issquare(n) && (d == Vecrev(d)); \\ Michel Marcus, Oct 21 2016

A229687 Odd squares whose binary reversal is also a square.

Original entry on oeis.org

1, 9, 20457529, 143784081, 331130809, 4365905625, 5216450625, 20074072489, 1193532215121, 10036851273801, 36014509461681, 38767247532225, 41413201925481, 155991531977649, 320642706437001, 2543173099393689, 2696589987547401, 4665141483989281, 87463589042698969
Offset: 1

Views

Author

Alex Ratushnyak, Dec 19 2013

Keywords

Comments

The sequence of binary reversals that are squares is a permutation of a(n), it begins: 1, 9, 20457529, 143784081, 331130809, 5216450625, 4365905625, 20074072489, 1193532215121, 10036851273801, 38767247532225, 36014509461681, ...
A029983 is a subsequence (after zero). - Antti Karttunen, Dec 20 2013

Crossrefs

Programs

  • C
    #include 
    #include 
    int main() {
      unsigned long long n, t, r, sr;
      for (n=1; n<(1ULL<<32); n+=2) {
         t = n*n;
         r = 0;
         while (t)  r = r*2+(t&1),  t >>= 1;
         sr = sqrt(r);
         if (sr*sr==r)  printf("%llu, ", n*n);
      }
      return 0;
    }
    
  • Scheme
    (define (A229687 n) (A000290 (A229766 n))) ;; Antti Karttunen, Dec 20 2013

Formula

a(n) = A229766(n)^2.

A272711 Square numbers whose binary reversal is also square.

Original entry on oeis.org

1, 4, 9, 16, 36, 64, 144, 256, 576, 1024, 2304, 4096, 9216, 16384, 36864, 65536, 147456, 262144, 589824, 1048576, 2359296, 4194304, 9437184, 16777216, 20457529, 37748736, 67108864, 81830116, 143784081, 150994944, 268435456, 327320464, 331130809, 575136324, 603979776
Offset: 1

Views

Author

Benjamin Przybocki, May 04 2016

Keywords

Comments

The first term in this sequence whose binary reversal is not 1 or 9 is 20457529 (which is a binary palindrome).
The previous comment means that the sequence does not just contain the squares of numbers in A029744. - R. J. Mathar, May 06 2016
If k is a term, then so is 4*k. - Robert Israel, Jun 06 2023

Crossrefs

Cf. A061457 (analogous in base 10).

Programs

  • Maple
    rev:= proc(n) local L,i;
      L:= convert(n,base,2);
      add(L[-i]*2^(i-1),i=1..nops(L))
    end proc:
    select(n -> issqr(rev(n)), [seq(i^2,i=1..100000)]); # Robert Israel, Jun 06 2023
  • Mathematica
    Select[Range[10^5]^2, IntegerQ@ Sqrt@ FromDigits[ Reverse@ IntegerDigits[#, 2], 2] &] (* Giovanni Resta, May 05 2016 *)
  • PARI
    lista(nn) = {for (n=1, nn, if (issquare(subst(Polrev(binary(n^2)), x, 2)), print1(n^2, ", ")););} \\ Michel Marcus, May 05 2016

A225300 Terms in A025475 that are palindromes in base 2.

Original entry on oeis.org

1, 9, 27, 20457529, 87463589042698969
Offset: 1

Views

Author

Alex Ratushnyak, May 04 2013

Keywords

Examples

			9 = 1001_2.
27 = 11011_2.
20457529 = 1001110000010100000111001_2.
		

Crossrefs

Intersection of A006995 and A025475.
Cf. A029983.

Extensions

Definition clarified by Chai Wah Wu, Mar 18 2018
Previous Showing 11-15 of 15 results.