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

A022555 Positive integers that are not the sum of two nonnegative cubes.

Original entry on oeis.org

3, 4, 5, 6, 7, 10, 11, 12, 13, 14, 15, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 29, 30, 31, 32, 33, 34, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 55, 56, 57, 58, 59, 60, 61, 62, 63, 66, 67, 68, 69, 70, 71, 73, 74, 75, 76, 77
Offset: 1

Views

Author

Keywords

Comments

Omits the positive cubes (A000578) since m^3 = 0^3 + m^3, so is different from A057903.

Crossrefs

Complement of A004999. Cf. A004825, A022561, A022566, A057903, A000578.

Programs

  • Maple
    read transforms; cub := series(add(q^(n^3),n=0..100),q,1000001); t1 := series(cub^2,q,2000); t2 := POWERS(t1,q,2000); COMPl(t2);
  • Mathematica
    r[n_] := Reduce[x >= 0 && y >= 0 && n == x^3 + y^3, {x, y}, Integers]; Select[ Range[80], r[#] === False &]  (* Jean-François Alcover, Nov 06 2012 *)
    Select[Range@100,PowersRepresentations[#,2,3]=={}&] (* A much faster solution given by Giovanni Resta, Nov 06 2012 *)

Extensions

Edited by N. J. A. Sloane, Sep 28 2007

A297970 Numbers that are not the sum of 3 squares and a nonnegative 7th power.

Original entry on oeis.org

112, 240, 368, 496, 624, 752, 880, 1008, 1136, 1264, 1392, 1520, 1648, 1776, 1904, 2032, 2160
Offset: 1

Views

Author

XU Pingya, Jan 10 2018

Keywords

Comments

The last term in this sequence is 2160. The reasons are as follows (let b, c, d, i, j, k, m, r, s, t, w, x, y and z be nonnegative integers).
For the Diophantine equation x^2 + y^2 + z^2 + w^7 = m:
(1) If m is not of the form 4^c * (8b + 7), then it follows from Legendre's three-square theorem that the equation has a solution with w = 0.
(2) 8b + 7 - 1^7 = 8b + 6. Then m = 8b + 7, the equation has a solution with w = 1.
(3) 4 * (8b + 7) - 1^7 = (8 * (4b + 3) + 3) = 8d + 3. Then m = 4 * (8b + 7), the equation has a solution with w = 1.
(4) For b >= 17, 16 * (8b + 7) - 3^7 = 8 * (16 * (b - 17) + 12) + 5 = 8i + 5. Then m = 16 * (8b + 7) and b >= 17, the equation has a solution with w = 3.
(5) 4^3 * (8b + 7) - 2^7 = 4^3 * (8b + 5). Then m = 4^3 * (8b + 7), the equation has a solution with w = 2. And 4^3 * (8b + 7) - 3^7 = 8 * (4^3 * (b - 4) + 38) + 5 = 8j + 5. Then m = 4^3 * (8b + 7) and b >= 4, the equation has a solution with w = 3.
(6) 4^4 * (8b + 7) - 2^7 = 4^3 * (8 * (4b + 3) + 3) = 4^3 * (8k + 3). 4^4 * (8b + 7) - 3^7 = 8 * (256b - 217) + 3 = 8r + 3. Then m = 4^4 * (8b + 7), the equation has a solution with w = 2 and when b > 0, the equation has a solution with w = 3.
(7) When c >= 5, 4^c * (8b + 7) - 2^7 = 4^3 * (8 * (b * 4^(c - 3) + 14 * 4^(c - 5) + 5) = 4^3 * (8s + 5). 4^c * (8b + 7) - 3^7 = 8 * (b * 4^(c - 3) + 14 * 4^(c - 3) - 273) + 3 = 8t + 3. Then n = 4^c * (8b + 7), the equation has solutions with w = 2 and 3.
In short, except for the 17 numbers in the sequence, every nonnegative integer can be represented as the sum of 3 squares and a nonnegative 7th power.

Crossrefs

Finite subsequence of A004215 and A296185.

Programs

  • Mathematica
    t1={};
    Do[Do[If[x^2+y^2+z^2+w^7==n, AppendTo[t1,n]&&Break[]], {x,0,n^(1/2)}, {y,x,(n-x^2)^(1/2)}, {z,y,(n-x^2-y^2)^(1/2)}, {w,0,(n-x^2-y^2-z^2)^(1/7)}], {n,0,3000}];
    t2={};
    Do[If[FreeQ[t1,k]==True, AppendTo[t2,k]], {k,0,3000}];
    t2

Formula

a(n) = 128n - 16 = 16 * A004771(n - 1), 1 <= n <= 17.

A296185 Numbers that are not the sum of 3 squares and an 8th power.

Original entry on oeis.org

112, 240, 368, 496, 624, 752, 880, 1008, 1136, 1264, 1392, 1520, 1648, 1776, 1904, 2032, 2160, 2288, 2416, 2544, 2672, 2800, 2928, 3056, 3184, 3312, 3440, 3568, 3696, 3824, 3952, 4080, 4208, 4336, 4464, 4592, 4720, 4848, 4976, 5104, 5232, 5360, 5488, 5616
Offset: 1

Views

Author

XU Pingya, Jan 13 2018

Keywords

Comments

When m is in this sequence, 9m and m^9 are also in this sequence.
For nonnegative integers a, b, k, n, x, y, z and w, n = x^2 + y^2 + z^2 + w^8 if and only if n is not of the form 4^(4k + 2) * (8b + 7).
1. If n is not of the form 4^a * (8b + 7), then it follows from Legendre's three-square theorem that the equation x^2 + y^2 + z^2 + w^8 = n has a solution with w = 0.
2. If n = 4^a * (8b + 7), then (c, d and j are nonnegative integers):
(1) If a = 4k, then n - (2^k)^8 = 4^(4k) * (8b + 6), and the equation has a solution with w = 2^k.
(2) If a = 4k + 1, then n - (2^k)^8 = 4^(4k) * (32b + 27) is of the form 4^c * (8d + 3), and the equation has a solution with w = 2^k.
(3) If a = 4k + 3, then n - (2^(k + 1))^8 = 4^a * (8b + 3), and the equation has a solution with w = 2^(k + 1).
(4) If a = 4k + 2 and w = 2j + 1, then n == 0 (mod 8), w^8 == 1 (mod 8), and n - w^8 is number of the form 8c + 7. I.e., the equation does not have a solution with w odd.
If a = 4k + 2 and w = 4j + 2, then n - w^8 = 16 * (4^(4k) * (8b + 7) - 16 * (2j + 1)^8) = 4^4 * (4^(4k - 4) * (8b + 7) - (2j + 1)^8). When k = 0, n - w^8 is a number of the form 16 * (8c + 7); when k > 0, n - w^8 is a number of the form 4^4 * (8d + 7). Therefore, the equation does not have a solution with w = 4j + 2. Similarly, it can be proved that there is no solution with w = 4j.

Crossrefs

Programs

  • Mathematica
    t1={};
    Do[Do[If[x^2+y^2+z^2+w^8==n, AppendTo[t1,n]&&Break[]], {x,0,n^(1/2)}, {y,x,(n-x^2)^(1/2)}, {z,y,(n-x^2-y^2)^(1/2)}, {w,0,(n-x^2-y^2-z^2)^(1/8)}], {n,0,5700}];
    t2={};
    Do[If[FreeQ[t1,k]==True, AppendTo[t2,k]], {k,0,5700}];
    t2
  • Python
    from itertools import count, islice
    def A296185_gen(): # generator of terms
        for k in count(0):
            r = 1<<((k<<1)+1<<2)
            yield from range(7*r,r*((r<<8)+7),r<<3)
    A296185_list = list(islice(A296185_gen(),44)) # Chai Wah Wu, May 21 2025

A296579 Numbers that are not the sum of 3 squares and a nonnegative 9th power.

Original entry on oeis.org

112, 240, 368, 448, 496, 624, 752, 880, 960, 1008, 1136, 1264, 1392, 1472, 1520, 1648, 1776, 1904, 1984, 2032, 2160, 2288, 2416, 2496, 2544, 2672, 2800, 2928, 3008, 3056, 3184, 3312, 3440, 3520, 3568, 3696, 3824, 3952, 4032, 4080, 4208, 4336, 4464, 4544, 4592
Offset: 1

Views

Author

XU Pingya, Jan 30 2018

Keywords

Comments

a(n) consists of the number of forms 16*(8i + 7) (0 <= i <= 152) and 64*(8j + 7) (0 <= j <= 37).
The last term in this sequence is a(191) = 19568 = 16*(8*152 + 7) (see A297970).

Crossrefs

Finite subsequence of A004215.
A297970 is a subsequence.

Programs

  • Mathematica
    t1=Table[4^2*(8j+7), {j,0,152}];
    t2=Table[4^3*(8j+7), {j,0,37}];
    t=Union[t1, t2]

A297931 Numbers that are not the sum of a square and 3 nonnegative cubes.

Original entry on oeis.org

15, 22, 23, 48, 86, 94, 112, 120, 139, 184, 203, 211, 230, 237, 263, 301, 309, 312, 335, 373, 399, 1014, 1056, 1455, 1644, 2029, 2272, 2658, 3309, 3469, 4019, 6502, 11101
Offset: 1

Views

Author

XU Pingya, Jan 08 2018

Keywords

Comments

After 11101, there are no more terms up to 570000.
No more terms < 10^10; is this sequence finite? - Mauro Fiorentini, Jan 26 2019

Crossrefs

Programs

  • Mathematica
    t1={};
    Do[Do[If[x^2+y^2+z^2+w^3==n, AppendTo[t1,n]&&Break[]], {x,0,n^(1/2)}, {y,x,(n-x^2)^(1/2)}, {z,y,(n-x^2-y^2)^(1/2)}, {w,0,(n-x^2-y^2-z^2)^(1/3)}], {n,0,5.7*10^5}];
    t2={};
    Do[If[FreeQ[t1,k]==True, AppendTo[t2,k]], {k,0,5.7*10^5}];
    t2
Showing 1-5 of 5 results.