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

A350810 a(n) = ceiling((n-R(n^2))^2/(n+R(n^2))), where R(n^2) is the digit reversal of n^2.

Original entry on oeis.org

0, 1, 3, 50, 39, 48, 75, 27, 3, 8, 92, 407, 923, 651, 479, 606, 933, 372, 114, 11, 92, 422, 859, 607, 456, 602, 850, 410, 81, 12, 96, 4106, 9703, 6410, 5117, 6814, 9521, 4329, 1139, 5, 1742, 4547, 9353, 6261, 5069, 5976, 8882, 3891, 904, 1, 919, 3919, 8925, 6032, 5041, 6147, 9254
Offset: 1

Views

Author

Claude H. R. Dequatre, Jan 17 2022

Keywords

Comments

This sequence gives both at large and small scales well-structured graphs; specific and periodic patterns are visible in separated layers.

Examples

			For n = 1, R(n^2) = 1, thus a(1) = ceiling((1-1)^2/(1+1)) = 0.
For n = 10, R(n^2) = 1, thus a(10) = ceiling((10-1)^2/(10+1)) = 8.
For n = 21, R(n^2) = 144, thus a(21) = ceiling((21-144)^2/(21+144)) = 92.
		

Crossrefs

Programs

  • Mathematica
    Table[Ceiling[(n-FromDigits[Reverse[IntegerDigits[n^2]]])^2/(n+FromDigits[Reverse[IntegerDigits[n^2]]])],{n,57}] (* Stefano Spezia, Jan 18 2022 *)
  • PARI
    a(n) = my(x = fromdigits(Vecrev(digits(n^2))));r = ceil((n-x)^2/(n+x));
    for(n = 1,2000,print1(a(n)", "))
    
  • Python
    def R(n): return int(str(n)[::-1])
    def a(n):
        Rn2 = R(n**2)
        q, r = divmod((n-Rn2)**2, n+Rn2)
        return q if r == 0 else q + 1
    print([a(n) for n in range(1, 67)]) # Michael S. Branicky, Jan 17 2022

A113800 Numbers k such that k^2 plus the reverse of k^2 gives a perfect power.

Original entry on oeis.org

2, 231, 1010, 102010, 451429, 1000100, 9426681, 1000001000, 8803095102, 10002000100, 56017891104, 1000000010000, 4811618419542
Offset: 1

Views

Author

Giovanni Resta, Jan 22 2006

Keywords

Comments

Sequence is infinite since it contains all the numbers of the form (1+100^k)*10^k and (1+100^k)^2*10^k, for k >= 1. - Giovanni Resta, Sep 24 2013

Examples

			451429^2 = 203788142041 and 203788142041 + 140241887302 = 7007^3,
9426681^2 = 88862314675761 and 88862314675761 + 16757641326888 = 10277157^2.
		

Crossrefs

Programs

  • Mathematica
    ppQ[n_] := n != 1 && GCD @@ (Transpose[FactorInteger[n]][[2]]) > 1; rev[n_] := FromDigits@Reverse@IntegerDigits@n ; lst = {}; Do[If[ppQ[n^2 + rev[n^2]], AppendTo[lst, n]], {n, 10^6}]; lst

Extensions

a(8)-a(13) from Giovanni Resta, Sep 24 2013

A356417 Numbers whose reversal is a square.

Original entry on oeis.org

0, 1, 4, 9, 10, 18, 40, 46, 52, 61, 63, 90, 94, 100, 121, 144, 148, 163, 169, 180, 400, 423, 441, 460, 484, 487, 520, 522, 526, 610, 630, 652, 675, 676, 691, 900, 925, 927, 940, 961, 982, 1000, 1042, 1062, 1089, 1210, 1251, 1273, 1297, 1405, 1426, 1440, 1480
Offset: 1

Views

Author

Daniel Blam, Aug 06 2022

Keywords

Comments

Every power of 10 is a term in the sequence.
If k is in the sequence then so is 10*k. - David A. Corneth, Aug 06 2022
If all multiples of 10 were omitted, A074896 would result. - Jon E. Schoenfield, Aug 06 2022

Examples

			0 is a term, 0 -> 0 (0^2).
10 is a term, 10 -> 01 (leading zero is dropped) (1^2).
691 is a term, 691 -> 196 (14^2).
1800 is a term, 1800 -> 0081 (leading zeros are dropped) (9^2).
		

Crossrefs

Programs

  • Mathematica
    Select[Range[0, 1500], IntegerQ[Sqrt[IntegerReverse[#]]] &] (* Amiram Eldar, Aug 06 2022 *)
  • PARI
    isok(k) = issquare(fromdigits(Vecrev(digits(k)))); \\ Michel Marcus, Aug 06 2022
  • Python
    from sympy import integer_nthroot
    def ok(n):
        return integer_nthroot(int(str(n)[::-1]), 2)[1]
    print([k for k in range(1500) if ok(k)])
    
  • Python
    from math import isqrt
    from itertools import count, islice
    def A356417_gen(): # generator of terms
        yield 0
        for l in count(1):
            nlist = []
            for m in range(1,isqrt(10**l)+1):
                if m%10:
                    s = str(m**2)
                    nlist.append(int(s[::-1])*10**(l-len(s)))
            yield from sorted(nlist)
    A356417_list = list(islice(A356417_gen(),100)) # Chai Wah Wu, Aug 07 2022
    

A383027 a(n) is the number whose reversed n-digit square is the largest among all reversals of n-digit squares.

Original entry on oeis.org

3, 7, 17, 83, 167, 583, 1833, 8167, 10583, 41833, 191833, 489417, 1989417, 9958167, 25041833, 74958167, 125041833, 831989417, 1625041833, 9874958167, 15831989417, 65831989417, 309874958167, 834168010583, 1809874958167, 6809874958167, 29165831989417, 51809874958167, 179165831989417
Offset: 1

Views

Author

Zhining Yang, Apr 13 2025

Keywords

Examples

			a(3)=17 because 982 (reverse of 17^2=289) is the largest reverse of all 3-digit squares.
		

Crossrefs

Cf. A002942.

Programs

  • Mathematica
    a[n_]:=Module[{s=Ceiling[Sqrt[10^(n-1)]]},max=IntegerReverse[s^2];
    For[k=s,k<=Floor[Sqrt[(10^n-1)]],k++,t=IntegerReverse[k^2];
    If[t>max,max=t;s=k]];s];Table[a[n],{n,10}]
Previous Showing 11-14 of 14 results.