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

A057897 Numbers which can be written as m^k-k, with m, k > 1.

Original entry on oeis.org

2, 5, 7, 12, 14, 23, 24, 27, 34, 47, 58, 61, 62, 77, 79, 98, 119, 121, 122, 142, 167, 194, 213, 223, 238, 248, 252, 254, 287, 322, 340, 359, 398, 439, 482, 503, 509, 527, 574, 621, 623, 674, 723, 726, 727, 782, 839, 898, 959, 997, 1014, 1019, 1022, 1087, 1154
Offset: 1

Views

Author

Henry Bottomley, Sep 26 2000

Keywords

Comments

It may be that positive integers can be written as m^k-k (with m and k > 1) in at most one way [checked up to 10000].
All numbers < 10^16 of this form have a unique representation. The uniqueness question leads to a Pillai-like exponential Diophantine equation a^x-b^y = x-y for x > y > 1 and b > a > 1, which appears to have no solutions. - T. D. Noe, Oct 06 2004

Crossrefs

Cf. A099225 (numbers of the form m^k+k, with m and k > 1), A074981 (n such that there is no solution to Pillai's equation), A099226 (numbers that can be represented as both a^x+x and b^y-y, for some a, b, x, y > 1).

Programs

  • Mathematica
    nLim=1000; lst={}; Do[k=2; While[n=m^k-k; n<=nLim, AppendTo[lst, n]; k++ ], {m, 2, Sqrt[nLim]}]; Union[lst] (* T. D. Noe, Oct 06 2004 *)
  • PARI
    ok(n)={my(e=2); while(2^e <= n+e, if(ispower(n+e, e), return(1)); e++); 0} \\ Andrew Howroyd, Oct 20 2020
    
  • PARI
    upto(lim)={my(p=logint(lim,2)); while(logint(lim+p+1,2)>p, p++); Vec(Set(concat(vector(p-1, e, e++; vector(sqrtnint(lim+e,e)-1, m, (m+1)^e-e)))))} \\ Andrew Howroyd, Oct 20 2020

A253913 Numbers of the form m^k + m, with m >= 0 and k > 1.

Original entry on oeis.org

0, 2, 6, 10, 12, 18, 20, 30, 34, 42, 56, 66, 68, 72, 84, 90, 110, 130, 132, 156, 182, 210, 222, 240, 246, 258, 260, 272, 306, 342, 350, 380, 420, 462, 506, 514, 520, 552, 600, 630, 650, 702, 732, 738, 756, 812, 870, 930, 992, 1010, 1026, 1028, 1056, 1122, 1190, 1260, 1302
Offset: 1

Views

Author

Alex Ratushnyak, Jan 18 2015

Keywords

Crossrefs

Programs

  • Maple
    N:= 10000: # for terms <= N
    S:= 0, 2:
    for k from 2 to floor(log[2](N)) do
      for m from 2 do
        v := m^k+m; if v > N then break fi;
        S:= S, v;
    od od:
    sort(convert({S}, list)): # Robert Israel, Apr 28 2019, changed Jul 8 2021
  • Mathematica
    max = 1000; Sort[Flatten[Table[m^k + m, {m, 2, Floor[Sqrt[max]]}, {k, 2, Floor[Log[m, max]]}]]] (* Alonso del Arte, Jan 18 2015 *)
  • Python
    def aupto(lim):
        xkx = set(x**k + x for k in range(2, lim.bit_length()) for x in range(int(lim**(1/k))+2))
        return sorted(filter(lambda t: t<=lim, xkx))
    print(aupto(1500)) # Michael S. Branicky, Jul 08 2021

Extensions

Changed to include 0 and 2 by Robert Israel, Jul 08 2021

A099226 Numbers that can be represented as both a^x+x and b^y-y, for some a, b, x, y > 1.

Original entry on oeis.org

27, 248, 2194, 32763
Offset: 1

Views

Author

T. D. Noe, Oct 06 2004

Keywords

Comments

No other terms < 10^15. The intersection of A057897 and A099225. The representation question leads to a Pillai-like exponential Diophantine equation a^x-b^y = x+y for y > x > 1 and b > a > 1.

Examples

			27 = 25^2+2 = 32^5-5, 248 = 7^3+3 = 2^8-8, 2194 = 3^7+7 = 13^3-3 and 32763 = 181^2+2 = 8^5-5.
		

Crossrefs

Cf. A074981 (n such that there is no solution to Pillai's equation).

Programs

  • Mathematica
    nLim=40000; lst1={}; Do[k=2; While[n=m^k-k; n<=nLim, AppendTo[lst1, n]; k++ ], {m, 2, Sqrt[nLim]}]; lst2={}; Do[k=2; While[n=m^k+k; n<=nLim, AppendTo[lst2, n]; k++ ], {m, 2, Sqrt[nLim]}]; Intersection[lst1, lst2]

A099227 Primes of the form m^k+k, with m and k > 1.

Original entry on oeis.org

11, 37, 67, 83, 227, 443, 521, 1091, 1523, 2027, 3251, 4099, 6563, 6569, 9803, 10651, 11027, 12323, 13691, 15131, 17579, 21611, 29243, 32771, 32783, 47963, 50627, 56171, 59051, 62003, 65027, 74531, 88211, 91811, 95483, 103043, 119027, 123203
Offset: 1

Views

Author

T. D. Noe, Oct 06 2004

Keywords

Comments

It appears that primes of this form are much less common than primes of the form m^k-k (A099228).
As N increases, squares <= N outnumber all higher powers <= N by an increasingly wide margin, so the above observation is increasingly a consequence of the fact that primes of the form m^2 + 2 are less common than primes of the form m^2 - 2. Among numbers of these two forms, multiples of 3 make up 2/3 of the former, but none of the latter. - Jon E. Schoenfield, Jun 05 2021

Crossrefs

Cf. A099225 (numbers of the form m^k+k, with m and k > 1), A093324 (least k such that n^k+k is prime).
Cf. A099228.

Programs

  • Mathematica
    nLim=200000; lst={}; Do[k=2; While[n=m^k+k; n<=nLim, AppendTo[lst, n]; k++ ], {m, 2, Sqrt[nLim]}]; Select[Union[lst], PrimeQ]
  • PARI
    list(lim)=my(v=List()); for(e=2,logint(lim\=1,2), forstep(n=3-e%2,sqrtnint(lim-e,e),2, my(t=n^e+e); if(isprime(t), listput(v,t)))); Set(v) \\ Charles R Greathouse IV, Jun 23 2023

A253914 Numbers that can be represented as both a^x + x and b^y + b, for some a, b, x, y > 1.

Original entry on oeis.org

6, 18, 20, 30, 66, 258, 260, 732, 1026, 3130, 4098, 4100, 16386, 19686, 46662, 65538, 65540, 65552, 262146, 531444, 823550, 1048578, 1048580, 4194306, 9765630, 14348910, 16777218, 16777220, 16777224, 67108866, 268435458, 268435460, 387420492, 387420498, 1073741826
Offset: 1

Views

Author

Alex Ratushnyak, Jan 18 2015

Keywords

Comments

Intersection of A099225 and A253913.
Includes a^(a*b)+a = (a^b)^a+a for a,b > 1. - Robert Israel, Apr 28 2019

Examples

			a(1) = 6 = 2^2 + 2, in this case a = b = x = y = 2.
a(2) = 18 = 2^4 + 2 = 4^2 + 2.
a(8) = 732 = 3^6 + 3 = 9^3 + 3.
		

Crossrefs

A253916 Numbers that can be represented as both x^y + y and b^c + b + c, for some b, c, x, y > 1.

Original entry on oeis.org

264, 1334, 4108, 373323, 6436371, 387420507, 1099511627816
Offset: 1

Views

Author

Alex Ratushnyak, Jan 18 2015

Keywords

Comments

Intersection of A099225 and A253775.

Examples

			264 is in the list since 264 = 2^8 + 8 and 264 = 4^4 + 4 + 4.
a(2) = 1334 = 11^3 + 3 = 36^2 + 36 + 2.
		

Crossrefs

Showing 1-6 of 6 results.