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

A181123 Numbers that are the differences of two positive cubes.

Original entry on oeis.org

0, 7, 19, 26, 37, 56, 61, 63, 91, 98, 117, 124, 127, 152, 169, 189, 208, 215, 217, 218, 271, 279, 296, 316, 331, 335, 342, 386, 387, 397, 448, 469, 485, 488, 504, 511, 513, 547, 602, 604, 631, 657, 665, 702, 721, 728, 784, 817, 819, 866, 875, 919, 936, 973
Offset: 1

Views

Author

T. D. Noe, Oct 06 2010

Keywords

Comments

Because x^3-y^3 = (x-y)(x^2+xy+y^2), the difference of two cubes is a prime number only if x=y+1, in which case all the primes are cuban, see A002407.
The difference can be a square (see A038597), but Fermat's Last Theorem prevents the difference from ever being a cube. Beal's Conjecture implies that there are no higher odd powers in this sequence.
If n is in the sequence, it must be x^3-y^3 where 0 < y <= x < n^(1/2). - Robert Israel, Dec 24 2017

Crossrefs

Cf. A024352 (squares), A147857 (4th powers), A181124-A181128 (5th to 9th powers).

Programs

  • Maple
    N:= 10^4: # to get all terms <= N
    sort(convert(select(`<=`, {0, seq(seq(x^3-y^3, y=1..x-1),x=1..floor(sqrt(N)))}, N),list)); # Robert Israel, Dec 24 2017
  • Mathematica
    nn=10^5; p=3; Union[Reap[Do[n=i^p-j^p; If[n<=nn, Sow[n]], {i,Ceiling[(nn/p)^(1/(p-1))]}, {j,i}]][[2,1]]]
    With[{nn=60},Take[Union[Abs[Flatten[Differences/@Tuples[ Range[ nn]^3,2]]]], nn]] (* Harvey P. Dale, May 11 2014 *)
  • PARI
    list(lim)=my(v=List([0]),a3); for(a=2,sqrtint(lim\3), a3=a^3; for(b=if(a3>lim,sqrtnint(a3-lim-1,3)+1,1), a-1, listput(v,a3-b^3))); Set(v) \\ Charles R Greathouse IV, Jan 25 2018

A181128 Difference of two positive 9th powers.

Original entry on oeis.org

0, 511, 19171, 19682, 242461, 261632, 262143, 1690981, 1933442, 1952613, 1953124, 8124571, 9815552, 10058013, 10077184, 10077695, 30275911, 38400482, 40091463, 40333924, 40353095, 40353606, 93864121, 124140032, 132264603, 133955584
Offset: 1

Views

Author

T. D. Noe, Oct 06 2010

Keywords

Comments

No term is a prime number.

Crossrefs

Cf. A024352 (squares), A181123 (cubes), A147857 (4th powers), A181124-A181127 (5th to 8th powers)

Programs

  • Mathematica
    nn=10^15; p=9; Union[Reap[Do[n=i^p-j^p; If[n<=nn, Sow[n]], {i,Ceiling[(nn/p)^(1/(p-1))]}, {j,i}]][[2,1]]]

A258807 a(n) = n^5 - 1.

Original entry on oeis.org

0, 31, 242, 1023, 3124, 7775, 16806, 32767, 59048, 99999, 161050, 248831, 371292, 537823, 759374, 1048575, 1419856, 1889567, 2476098, 3199999, 4084100, 5153631, 6436342, 7962623, 9765624, 11881375, 14348906, 17210367, 20511148, 24299999, 28629150, 33554431
Offset: 1

Views

Author

Vincenzo Librandi, Jun 11 2015

Keywords

Crossrefs

Subsequence of A181124.
Sequences of the type n^k-1: A132411 (k=2), A068601 (k=3), A123865 (k=4), this sequence (k=5), A123866 (k=6), A258808 (k=7), A258809 (k=8), A258810 (k=9), A123867 (k=10), A258812 (k=11), A123868 (k=12).

Programs

  • GAP
    List([1..35],n->n^5-1); # Muniru A Asiru, Oct 28 2018
    
  • Magma
    [n^5-1: n in [1..50]];
    
  • Magma
    I:=[0,31,242,1023, 3124,7775]; [n le 6 select I[n] else 6*Self(n-1)-15*Self(n-2)+20*Self(n-3)-15*Self(n-4)+ 6*Self(n-5)-Self(n-6): n in [1..50]];
    
  • Maple
    seq(n^5-1,n=1..35); # Muniru A Asiru, Oct 28 2018
  • Mathematica
    Table[n^5 - 1, {n, 1, 50}] (* or *) LinearRecurrence[{6, -15, 20, -15, 6, -1}, {0, 31, 242, 1023, 3124, 7775}, 50]
  • PARI
    a(n)=n^5-1 \\ Charles R Greathouse IV, Jun 11 2015
    
  • Python
    for n in range(1, 50): print(n**5 - 1, end=', ') # Stefano Spezia, Oct 28 2018
  • Sage
    [n^5-1 for n in (1..50)] # Bruno Berselli, Jun 11 2015
    

Formula

G.f.: x^2*(31 + 56*x + 36*x^2 - 4*x^3 + x^4)/(1 - x)^6.
a(n) = 6*a(n-1) - 15*a(n-2) + 20*a(n-3) - 15*a(n-4) + 6*a(n-5) - a(n-6).
a(n) = -A024003(n). - Bruno Berselli, Jun 11 2015
Sum_{n>=2} 1/a(n) = Sum_{n>=1} (zeta(5*n) - 1) = 0.0379539032... - Amiram Eldar, Nov 06 2020

A181125 Difference of two positive 6th powers.

Original entry on oeis.org

0, 63, 665, 728, 3367, 4032, 4095, 11529, 14896, 15561, 15624, 31031, 42560, 45927, 46592, 46655, 70993, 102024, 113553, 116920, 117585, 117648, 144495, 215488, 246519, 258048, 261415, 262080, 262143, 269297, 413792, 468559, 484785, 515816
Offset: 1

Views

Author

T. D. Noe, Oct 06 2010

Keywords

Comments

No term is a prime number.

Crossrefs

Cf. A024352 (squares), A181123 (cubes), A147857 (4th powers), A181124-A181128 (5th to 9th powers).
Cf. A022522 (a subsequence, except its first term). - Mathew Englander, Jun 01 2014

Programs

  • Mathematica
    nn=10^10; p=6; Union[Reap[Do[n=i^p-j^p; If[n<=nn, Sow[n]], {i,Ceiling[(nn/p)^(1/(p-1))]}, {j,i}]][[2,1]]]

A181126 Difference of two positive 7th powers.

Original entry on oeis.org

0, 127, 2059, 2186, 14197, 16256, 16383, 61741, 75938, 77997, 78124, 201811, 263552, 277749, 279808, 279935, 543607, 745418, 807159, 821356, 823415, 823542, 1273609, 1817216, 2019027, 2080768, 2094965, 2097024, 2097151, 2685817
Offset: 1

Views

Author

T. D. Noe, Oct 06 2010

Keywords

Comments

Because x^7-y^7 = (x-y)(x^6+x^5*y+x^4*y^2+x^3*y^3+x^2*y^4+x*y^5+y^6), the difference of two 7th powers is a prime number only if x=y+1, in which case all the primes are in A121618.
The number 67675234241018881 = 127^8 is the first of an infinite number of squares of the form (b^(7k)-1)^8 in this sequence. Are any other squares possible?

Crossrefs

Cf. A024352 (squares), A181123 (cubes), A147857 (4th powers), A181124-A181128 (5th to 9th powers)

Programs

  • Mathematica
    nn=10^12; p=7; Union[Reap[Do[n=i^p-j^p; If[n<=nn, Sow[n]], {i,Ceiling[(nn/p)^(1/(p-1))]}, {j,i}]][[2,1]]]
    Join[{0},#[[2]]-#[[1]]&/@Subsets[Range[10]^7,{2}]//Union] (* Harvey P. Dale, Oct 23 2024 *)

A181127 Difference of two positive 8th powers.

Original entry on oeis.org

0, 255, 6305, 6560, 58975, 65280, 65535, 325089, 384064, 390369, 390624, 1288991, 1614080, 1673055, 1679360, 1679615, 4085185, 5374176, 5699265, 5758240, 5764545, 5764800, 11012415, 15097600, 16386591, 16711680, 16770655, 16776960
Offset: 1

Views

Author

T. D. Noe, Oct 06 2010

Keywords

Comments

No term is a prime number.

Crossrefs

Cf. A024352 (squares), A181123 (cubes), A147857 (4th powers), A181124-A181128 (5th to 9th powers)

Programs

  • Mathematica
    nn=10^14; p=8; Union[Reap[Do[n=i^p-j^p; If[n<=nn, Sow[n]], {i,Ceiling[(nn/p)^(1/(p-1))]}, {j,i}]][[2,1]]]

A247099 Numbers which are the sum or difference of two fifth powers.

Original entry on oeis.org

0, 1, 2, 31, 32, 33, 64, 211, 242, 243, 244, 275, 486, 781, 992, 1023, 1024, 1025, 1056, 1267, 2048, 2101, 2882, 3093, 3124, 3125, 3126, 3157, 3368, 4149, 4651, 6250, 6752, 7533, 7744, 7775, 7776, 7777, 7808, 8019, 8800, 9031, 10901, 13682, 15552, 15783, 15961
Offset: 1

Views

Author

Keywords

Examples

			31 = 2^5 - 1^5, 32 = 2^5 + 0^5, 33 = 2^5 + 1^5.
		

Crossrefs

Programs

  • Mathematica
    Union[Flatten[{Total[#],Abs[#[[2]]-#[[1]]]}&/@Tuples[Range[0,10]^5,2]]] (* Harvey P. Dale, Mar 30 2015 *)
  • PARI
    T=thueinit('z^5+1);
    is(n)=n==0 || #thue(T, n)>0

Formula

a(n) << n^(5/2). Can this be improved?

A303744 Numbers that are not a difference between same powers (greater than 1) of positive numbers.

Original entry on oeis.org

1, 2, 4, 6, 10, 14, 18, 22, 30, 34, 38, 42, 46, 50, 54, 58, 62, 66, 70, 74, 78, 82, 86, 90, 94, 102, 106, 110, 114, 118, 122, 126, 130, 134, 138, 142, 146, 150, 154, 158, 162, 166, 170, 174, 178, 182, 186, 190, 194, 198, 202, 206, 210, 214, 222, 226, 230, 234, 238, 246, 250, 254, 258, 262, 266, 270, 274, 278, 282, 286, 290
Offset: 1

Views

Author

Adam Kertesz, Apr 29 2018

Keywords

Comments

Apart from 1 and 4, all terms == 2 (mod 4). - Robert Israel, Jun 25 2018

Examples

			Odd numbers greater than 1 are differences of squares, so they are not here.
8 is not a term, 9 - 1: difference of two squares;
26 is not a term, 27 - 1: difference of two cubes.
		

Crossrefs

Sequences of numbers that are difference of powers: A024352 (squares), A181123 (cubes).
And of further n-th powers: A147857 (4th), A181124 (5th), A181125 (6th), A181126 (7th), A181127 (8th), A181128 (9th).

Programs

  • Maple
    N:= 1000: # to get all terms <= N
    S:= {1,2,4,seq(i,i=6..N,4)}:
    for p from 3 to ilog2(N+1) do
      for n from 1 while n^p - (n-1)^p <= N do
        if n^p > N then m0:= ceil((n^p - N)^(1/p)) else m0:= 1 fi;
        for m from m0 to n-1 do
          v:= n^p-m^p;
          S:= S minus {v};
        od
    od od:
    sort(convert(S,list)); # Robert Israel, Jun 25 2018
Showing 1-8 of 8 results.