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-2 of 2 results.

A035130 Cubes when digits rotated right once remain cubic.

Original entry on oeis.org

1, 8, 125, 54439939
Offset: 1

Views

Author

Patrick De Geest, Nov 15 1998

Keywords

Comments

Those resulting in leading zeros excluded.

Examples

			5^3 = 125 -> 512 = 8^3.
		

Crossrefs

Programs

  • Magma
    [k^3:k in [1..100000]| IsPower(Seqint((Intseq(Floor(k^3/10)) cat [Intseq(k^3)[1]])),3)]; // Marius A. Burtea, Oct 08 2019
  • Mathematica
    Select[Range[10000]^3,IntegerQ[Surd[FromDigits[RotateRight[ IntegerDigits[#]]], 3]]&] (* Harvey P. Dale, May 25 2015 *)

Formula

a(n) = A035128(n)^3. - R. J. Mathar, Jan 25 2017

A035127 Squares which when digits are rotated left once remain square.

Original entry on oeis.org

1, 4, 9, 144, 196, 625, 11664, 14884, 46656, 96100, 1493284, 4112784, 6385729, 9253764, 139287204, 149377284, 187799616, 618268225, 634284225, 678758809, 929884036, 14938217284, 43325589904, 61076696769, 97482577284
Offset: 1

Views

Author

Patrick De Geest, Nov 15 1998

Keywords

Comments

Those resulting in leading zeros are excluded.

Examples

			2527^2 = 6385729 -> 3857296 = 1964^2.
		

Crossrefs

Subsequence of A000290.

Programs

  • Mathematica
    okQ[n_]:=Module[{idn=IntegerDigits[n]},idn[[2]]!=0&&IntegerQ[Sqrt[ FromDigits[RotateLeft[idn]]]]]; Join[{1,4,9},Select[Range[4,320000]^2, okQ]] (* Harvey P. Dale, Apr 30 2011 *)
  • Python
    from itertools import count, islice
    from sympy.solvers.diophantine.diophantine import diop_DN
    def A035127_gen(): # generator of terms
        for l in count(0):
            l1, l2 = 10**(l+1), 10**l
            yield from sorted(set(y**2 for z in (diop_DN(10,m*(1-l1)) for m in range(10)) for x, y in z if l1 >= x**2 >= l2))
    A035127_list = list(islice(A035127_gen(),20)) # Chai Wah Wu, Apr 23 2022
Showing 1-2 of 2 results.