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.

A273429 Number of ordered ways to write n as x^6 + y^2 + z^2 + w^2, where x,y,z,w are nonnegative integers with y <= z <= w.

Original entry on oeis.org

1, 2, 2, 2, 2, 2, 2, 1, 1, 3, 3, 2, 2, 2, 2, 1, 1, 3, 4, 3, 2, 2, 2, 1, 1, 3, 4, 4, 2, 2, 3, 1, 1, 3, 4, 3, 3, 3, 3, 2, 1, 4, 4, 2, 2, 3, 3, 1, 1, 3, 5, 5, 3, 3, 5, 3, 1, 3, 3, 3, 2, 2, 4, 2, 2, 5, 7, 5, 4, 5, 4, 1, 3, 6, 6, 6, 4, 4, 4, 1, 2
Offset: 0

Views

Author

Zhi-Wei Sun, May 22 2016

Keywords

Comments

The author proved in arXiv:1604.06723 that for each c = 1, 4 any natural number can be written as c*x^6 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers. Thus a(n) > 0 for all n = 0,1,2,....
We note that a(n) = 1 for the following values of n not divisible by 2^6: 7, 8, 15, 16, 23, 24, 31, 32, 40, 47, 48, 56, 71, 79, 92, 112, 143, 176, 191, 240, 304, 368, 560, 624, 688, 752, 1072, 1136, 1456, 1520, 1840, 1904, 2608, 2672, 3760, 3824, 6512, 6896.
For more conjectural refinements of Lagrange's four-square theorem, one may consult the author's preprint arXiv:1604.06723.

Examples

			a(7) = 1 since 7 = 1^6 + 1^2 + 1^2 + 2^2 with 1 = 1 < 2.
a(8) = 1 since 8 = 0^6 + 0^2 + 2^2 + 2^2 with 0 < 2 = 2.
a(15) = 1 since 15 = 1^6 + 1^2 + 2^2 + 3^2 with 1 < 2 < 3.
a(16) = 1 since 16 = 0^6 + 0^2 + 0^2 + 4^2 with 0 = 0 < 4.
a(56) = 1 since 56 = 0^6 + 2^2 + 4^2 + 6^2 with 2 < 4 < 6.
a(71) = 1 since 71 = 1^6 + 3^2 + 5^2 + 6^2 with 3 < 5 < 6.
a(79) = 1 since 79 = 1^6 + 2^2 + 5^2 + 7^2 with 2 < 5 < 7.
a(92) = 1 since 92 = 1^6 + 1^2 + 3^2 + 9^2 with 1 < 3 < 9.
a(143) = 1 since 143 = 1^6 + 5^2 + 6^2 + 9^2 with 5 < 6 < 9.
a(191) = 1 since 191 = 1^6 + 3^2 + 9^2 + 10^2 with 3 < 9 < 10.
a(624) = 1 since 624 = 2^6 + 4^2 + 12^2 + 20^2 with 4 < 12 < 20.
a(2672) = 1 since 2672 = 2^6 + 4^2 + 36^2 + 36^2 with 4 < 36 = 36.
a(3760) = 1 since 3760 = 0^6 + 4^2 + 12^2 + 60^2 with 4 < 12 < 60.
a(3824) = 1 since 3824 = 2^6 + 4^2 + 12^2 + 60^2 with 4 < 12 < 60.
a(6512) = 1 since 6512 = 2^6 + 12^2 + 52^2 + 60^2 with 12 < 52 < 60.
a(6896) = 1 since 6896 = 2^6 + 36^2 + 44^2 + 60^2 with 36 < 44 < 60.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]]
    Do[r=0;Do[If[SQ[n-x^6-y^2-z^2],r=r+1],{x,0,n^(1/6)},{y,0,Sqrt[(n-x^6)/3]},{z,y,Sqrt[(n-x^6-y^2)/2]}];Print[n," ",r];Continue,{n,0,80}]

A273458 Number of ordered ways to write n as x^2 + y^2 + z^2 + w^2 with x-y+z+w a nonnegative cube, where x,y,z,w are integers with x >= y >= 0 and x >= |z| <= |w|.

Original entry on oeis.org

1, 2, 2, 3, 2, 2, 3, 3, 2, 2, 3, 2, 1, 5, 4, 3, 2, 1, 4, 3, 3, 6, 3, 2, 5, 3, 9, 3, 1, 1, 7, 5, 3, 7, 10, 4, 6, 2, 10, 2, 6, 2, 12, 7, 2, 5, 9, 3, 3, 6, 13, 3, 8, 3, 18, 3, 8, 5, 7, 3, 3, 5, 13, 8, 5, 3, 19, 4, 7, 7, 16, 1, 11, 5, 14, 7, 2, 3, 12, 5, 4
Offset: 0

Views

Author

Zhi-Wei Sun, May 22 2016

Keywords

Comments

Conjecture: a(n) > 0 for all n = 0,1,2,....
In the latest version of arXiv:1605.03074, the authors showed that any natural number can be written as x^2 + y^2 + z^2 + w^2 with x,y,z,w integers such that x + y + z + w is a cube (or a square).
For more conjectural refinements of Lagrange's four-square theorem, see the author's preprint arXiv:1604.06723.

Examples

			a(12) = 1 since 12 = 3^2 + 1^2 + (-1)^2 + (-1)^2 with 3 - 1 + (-1) + (-1) = 0^3.
a(17) = 1 since 17 = 2^2 + 0^2 + 2^2 + (-3)^2 with 2 - 0 + 2 + (-3) = 1^3.
a(28) = 1 since 28 = 3^2 + 1^2 + 3^2 + 3^2 with 3 - 1 + 3 + 3 = 2^3.
a(29) = 1 since 29 = 3^2 + 0^2 + 2^2 + (-4)^2 with 3 - 0 + 2 + (-4) = 1^3.
a(71) = 1 since 71 = 5^2 + 1^2 + 3^2 + (-6)^2 with 5 - 1 + 3 + (-6) = 1^3.
a(149) = 1 since 149 = 8^2 + 0^2 + 2^2 + (-9)^2 with 8 - 0 + 2 + (-9) = 1^3.
a(188) = 1 since 188 = 13^2 + 3^2 + 1^2 + (-3)^2 with 13 - 3 + 1 + (-3) = 2^3.
a(284) = 1 since 284 = 15^2 + 5^2 + 3^2 + (-5)^2 with 15 - 5 + 3 + (-5) = 2^3.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]]
    CQ[n_]:=CQ[n]=n>=0&&IntegerQ[n^(1/3)]
    Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&CQ[x-y+(-1)^j*z+(-1)^k*Sqrt[n-x^2-y^2-z^2]],r=r+1],{y,0,(n/2)^(1/2)},{x,y,Sqrt[n-y^2]},{z,0,Min[x,Sqrt[(n-x^2-y^2)/2]]},{j,0,Min[1,z]},{k,0,Min[1,Sqrt[n-x^2-y^2-z^2]]}];
    Print[n," ",r];Continue,{n,0,80}]

A273568 Number of ordered ways to write n as w^2 + x^2 + y^2 + z^2 with w + x + 2*y - 4*z twice a nonnegative cube, where w is an integer and x,y,z are nonnegative integers.

Original entry on oeis.org

1, 1, 2, 1, 3, 2, 2, 2, 2, 4, 3, 3, 4, 1, 2, 2, 1, 4, 6, 2, 4, 5, 3, 5, 5, 4, 1, 4, 5, 3, 3, 3, 1, 5, 4, 4, 4, 6, 8, 5, 1, 5, 4, 3, 13, 9, 2, 6, 2, 4, 7, 9, 8, 7, 8, 5, 6, 2, 4, 5, 7, 9, 11, 5, 2, 5, 10, 6, 12, 9, 4
Offset: 0

Views

Author

Zhi-Wei Sun, May 25 2016

Keywords

Comments

Conjecture: a(n) > 0 for all n = 0,1,2,....
For more conjectural refinements of Lagrange's four-square theorem, see the author's preprint arXiv:1604.06723.

Examples

			a(1) = 1 since 1 = 0^2 + 0^2 + 1^2 + 0^2 with 0 + 0 + 2*1 - 4*0 = 2*1^3.
a(3) = 1 since 3 = (-1)^2 + 1^2 + 1^2 + 0^2 with (-1) + 1 + 2*1 - 4*0 = 2*1^3.
a(13) = 1 since 13 = (-2)^2 + 2^2 + 2^2 + 1^2 with (-2) + 2 + 2*2 - 4*1 = 2*0^3.
a(16) = 1 since 16 = 2^2 + 2^2 + 2^2 + 2^2 with 2 + 2 + 2*2 - 4*2 = 2*0^3.
a(26) = 1 since 26 = 3^2 + 3^2 + 2^2 + 2^2 with 3 + 3 + 2*2 - 4*2 = 2*1^3.
a(32) = 1 since 32 = (-4)^2 + 4^2 + 0^2 + 0^2 with (-4) + 4 + 2*0 - 4*0 = 2*0^3.
a(40) = 1 since 40 = (-2)^2 + 4^2 + 4^2 + 2^2 with (-2) + 4 + 2*4 - 4*2 = 2*1^3.
a(218) = 1 since 218 = (-6)^2 + 6^2 + 11^2 + 5^2 with (-6) + 6 + 2*11 - 4*5 = 2*1^3.
a(416) = 1 since 416 = (-4)^2 + 20^2 + 0^2 + 0^2 with (-4) + 20 + 2*0 - 4*0 = 2*2^3.
a(544) = 1 since 544 = (-4)^2 + 20^2 + 8^2 + 8^2 with (-4) + 20 + 2*8 - 4*8 = 2*0^3.
a(800) = 1 since 800 = (-20)^2 + 20^2 + 0^2 + 0^2 with (-20) + 20 + 2*0 - 4*0 = 2*0^3.
a(1184) = 1 since 1184 = (-28)^2 + 12^2 + 16^2 + 0^2 with (-28) + 12 + 2*16 - 4*0 = 2*2^3.
a(2080) = 1 since 2080 = (-20)^2 + 20^2 + 32^2 + 16^2 with (-20) + 20 + 2*32 - 4*16 = 2*0^3.
a(6304) = 1 since 6304 = (-36)^2 + 36^2 + 56^2 + 24^2 with (-36) + 36 + 2*56 - 4*24 = 2*2^3.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]]
    CQ[n_]:=CQ[n]=n>=0&&IntegerQ[n^(1/3)]
    Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&CQ[(x+2y-4z+(-1)^k*Sqrt[n-x^2-y^2-z^2])/2],r=r+1],{x,0,Sqrt[n]},{y,0,Sqrt[n-x^2]},{z,0,Sqrt[n-x^2-y^2]},{k,0,Min[1,n-x^2-y^2-z^2]}];Print[n," ",r];Continue,{n,0,70}]

A273616 Number of ordered ways to write n as x^2 + y^2 + z^2 + w^2 with (3*x^2+13*y^2)*z a square, where x,y,z,w are nonnegative integers.

Original entry on oeis.org

1, 4, 4, 2, 5, 8, 4, 2, 4, 8, 11, 4, 2, 10, 8, 1, 4, 12, 10, 8, 9, 8, 9, 1, 4, 17, 16, 6, 3, 16, 8, 1, 4, 8, 18, 10, 8, 12, 13, 2, 10, 18, 9, 8, 5, 17, 11, 3, 2, 15, 22, 7, 13, 15, 17, 4, 6, 10, 11, 14, 2, 18, 17, 1, 5, 23, 13, 9, 13, 14, 14, 1, 8, 16, 26, 8, 4, 16, 7, 1, 8
Offset: 0

Views

Author

Zhi-Wei Sun, May 26 2016

Keywords

Comments

Conjecture: For each ordered pair (a,b) = (3,13), (5,11), (15,57), (15,165), (138,150), any natural number can be written as x^2 + y^2 + z^2 + w^2 with (a*x^2+b*y^2)*z a square, where x,y,z,w are nonnegative integers.
For more conjectural refinements of Lagrange's four-square theorem, see the author's preprint arXiv:1604.06723.

Examples

			a(15) = 1 since 15 = 2^2 + 1^2 + 1^2 + 3^2 with (3*2^2+13*1^2)*1 = 5^2.
a(23) = 1 since 23 = 3^2 + 3^2 + 1^2 + 2^2 with (3*3^2+13*3^2)*1 = 12^2.
a(31) = 1 since 31 = 2^2 + 1^2 + 1^2 + 5^2 with (3*2^2+13*1^2)*1 = 5^2.
a(63) = 1 since 63 = 6^2 + 1^2 + 1^2 + 5^2 with (3*6^2+13*1^2)*1 = 11^2.
a(71) = 1 since 71 = 6^2 + 3^2 + 1^2 + 5^2 with (3*6^2+13*3^2)*1 = 15^2.
a(79) = 1 since 79 = 5^2 + 3^2 + 3^2 + 6^2 with (3*5^2+13*3^2)*3 = 24^2.
a(223) = 1 since 223 = 2^2 + 13^2 + 1^2 + 7^2 with (3*2^2+13*13^2)*1 = 47^2.
a(303) = 1 since 303 = 2^2 + 13^2 + 9^2 + 7^2 with (3*2^2+13*13^2)*9 = 141^2.
a(2703) = 1 since 2703 = 15^2 + 25^2 + 22^2 + 37^2 with (3*15^2+13*25^2)*22 = 440^2.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]]
    Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&SQ[(3x^2+13y^2)z],r=r+1],{x,0,Sqrt[n]},{y,0,Sqrt[n-x^2]},{z,0,Sqrt[n-x^2-y^2]}];Print[n," ",r];Label[aa];Continue,{n,0,80}]

A273826 Number of ordered ways to write n as x^2 + y^2 + z^2 + w^2 with x*y + y*z + z*w a fourth power, where x is a positive integer, y is a nonnegative integer, and z and w are integers.

Original entry on oeis.org

1, 5, 5, 3, 8, 6, 5, 4, 2, 11, 5, 5, 10, 1, 3, 1, 9, 15, 4, 9, 2, 4, 6, 2, 13, 13, 10, 7, 8, 6, 3, 5, 9, 14, 6, 9, 13, 9, 9, 10, 13, 11, 5, 4, 14, 5, 8, 5, 6, 15, 10, 17, 14, 13, 6, 1, 18, 17, 2, 8, 8, 5, 17, 3, 23, 15, 9, 17, 10, 9
Offset: 1

Views

Author

Zhi-Wei Sun, May 31 2016

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 0, and a(n) = 1 only for n = 16^k*m (k = 0,1,2,... and m = 1, 14, 56, 91, 184, 329, 355, 1016).
(ii) Any positive integer can be written as x^2 + y^2 + z^2 + w^2 with x*y + y*z + z*w a nonnegative cube, where x is a positive integer, y is a nonnegative integer, and z and w are integers.
(iii) For each triple (a,b,c) = (1,1,2), (1,1,3), (1,2,2), (1,2,3), (1,3,4), (1,5,3), (1,6,2), (2,2,6), (4,4,12), (4,4,16), (4,8,8), (4,12,16), (4,20,12), (8,8,16), (8,8,24), (8,8,32), (8,24,16), any natural number can be written as x^2 + y^2 + z^2 + w^2 with x,y,z,w integers such that a*x*y + b*y*z + c*z*w is a fourth power.
For more conjectural refinements of Lagrange's four-square theorem, see the author's preprint arXiv:1604.06723.

Examples

			a(1) = 1 since 1 = 1^2 + 0^2 + 0^2 + 0^2 with 1 > 0, 0 = 0 and 1*0 + 0*0 + 0*0 = 0^4.
a(14) = 1 since 14 = 3^2 + 1^2 + (-2)^2 + 0^2 with 3 > 0, 1 > 0 and 3*1 + 1*(-2) + (-2)*0 = 1^4.
a(56) = 1 since 56 = 6^2 + 4^2 + (-2)^2 + 0^2 with 6 > 0, 4 > 0 and 6*4 + 4*(-2) + (-2)*0 = 2^4.
a(91) = 1 since 91 = 4^2 + 7^2 + (-1)^2 + 5^2 with 4 > 0, 7 > 0 and 4*7 + 7*(-1) + (-1)*5 = 2^4.
a(184) = 1 since 184 = 10^2 + 4^2 + (-2)^2 + 8^2 with 10 > 0, 4 > 0 and 10*4 + 4*(-2) + (-2)*8 = 2^4.
a(329) = 1 since 329 = 18^2 + 1^2 + (-2)^2 + 0^2 with 18 > 0, 1 > 0 and 18*1 + 1*(-2) + (-2)*0 = 2^4.
a(355) = 1 since 355 = 17^2 + 1^2 + (-8)^2 + 1^2 with 17 > 0, 1 > 0 and 17*1 + 1*(-8) + (-8)*1 = 1^4.
a(1016) = 1 since 1016 = 2^2 + 20^2 + 6^2 + (-24)^2 with 2 > 0, 20 > 0 and 2*20 + 20*6 + 6*(-24) = 2^4.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]]
    QQ[n_]:=QQ[n]=IntegerQ[n^(1/4)]
    Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&QQ[x*y+y*(-1)^j*z+(-1)^(j+k)*z*Sqrt[n-x^2-y^2-z^2]],r=r+1],{x,1,Sqrt[n]},{y,0,Sqrt[n-x^2]},{z,0,Sqrt[n-x^2-y^2]},{j,0,Min[1,z]},{k,0,Min[1,Sqrt[n-x^2-y^2-z^2]]}];Print[n," ",r];Continue,{n,1,70}]

A273875 Number of ordered ways to write n as w^2 + x^2 + y^2 + z^2 with x*y + 2*y*z + 4*z*x a nonnegative cube, where w,x,y,z are integers with w >= 0 and x > 0.

Original entry on oeis.org

1, 2, 2, 2, 4, 3, 1, 1, 4, 3, 1, 1, 3, 3, 1, 1, 3, 6, 4, 6, 5, 2, 4, 2, 4, 5, 5, 5, 5, 5, 3, 2, 4, 6, 4, 8, 5, 5, 3, 4, 7, 7, 6, 3, 10, 2, 4, 1, 3, 10, 4, 8, 4, 8, 5, 4, 5, 9, 5, 4, 4, 4, 10, 1, 11, 11, 4, 10, 10, 4, 4, 9, 6, 9, 7, 5, 6, 8, 5, 2
Offset: 1

Views

Author

Zhi-Wei Sun, Jun 02 2016

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 0.
(ii) Any positive integer can be written as w^2 + x^2 + y^2 + z^2 with x*y + 2*y*z + 4*z*x = 4*t^3 for some t = 0,1,2,..., where w,x,y,z are integers with x > 0. Also, any natural number can be written as w^2 + x^2 + y^2 + z^2 with x*y + 3*y*z + 4*z*x = 3*t^3 for some t = 0,1,2,..., where w,x,y,z are integers with x >= 0.
(iii) For each triple (a,b,c) = (1,1,2), (1,2,3), (3,2,1), (4,1,1), any natural number can be written as w^2 + x^2 + y^2 + z^2 with a*x*y + b*y*z - c*z*w a nonnegative cube, where w,x,y are nonnegative integers and z is an integer.
For more conjectural refinements of Lagrange's four-square theorem, see the author's preprint arXiv:1604.06723.

Examples

			a(1) = 1 since 1 = 0^2 + 1^2 + 0^2 + 0^2 with 1*0 + 2*0*0 + 4*0*1 = 0^3.
a(7) = 1 since 7 = 2^2 + 1^2 + (-1)^2 + 1^2 with 1*(-1) + 2*(-1)*1 + 4*1*1 = 1^3.
a(8) = 1 since 8 = 2^2 + 2^2 + 0^2 + 0^2 with 2*0 + 2*0*0 + 4*0*2 = 0^3.
a(11) = 1 since 11 = 3^2 + 1^2 + 1^2 + 0^2 with 1*1 + 2*1*0 + 4*0*1 = 1^3.
a(12) = 1 since 12 = 3^2 + 1^2 + (-1)^2 + 1^2 with 1*(-1) + 2*(-1)*1 + 4*1*1 = 1^3.
a(15) = 1 since 15 = 1^2 + 1^2 + (-3)^2 + (-2)^2 with 1*(-3) + 2*(-3)*(-2) + 4*(-2)*1 = 1^3.
a(16) = 1 since 16 = 0^2 + 4^2 + 0^2 + 0^2 with 4*0 + 2*0*0 + 4*0*4 = 0^3.
a(48) = 1 since 48 = 4^2 + 4^2 + 0^2 + 4^2 with 4*0 + 2*0*4 + 4*4*4 = 4^3.
a(112) = 1 since 112 = 4^2 + 8^2 + (-4)^2 + 4^2 with 8*(-4) + 2*(-4)*4 + 4*4*8 = 4^3.
a(131) = 1 since 131 = 9^2 + 3^2 + (-4)^2 + 5^2 with 3*(-4) + 2*(-4)*5 + 4*5*3 = 2^3.
a(176) = 1 since 176 = 12^2 + 4^2 + 0^2 + 4^2 with 4*0 + 2*0*4 + 4*4*4 = 4^3.
a(224) = 1 since 224 = 0^2 + 8^2 + 4^2 + 12^2 with 8*4 + 2*4*12 + 4*12*8 = 8^3.
a(304) = 1 since 304 = 4^2 + 4^2 + (-16)^2 + (-4)^2 with 4*(-16) + 2*(-16)*(-4) + 4*(-4)*4 = 0^3.
a(944) = 1 since 944 = 20^2 + 12^2 + (-16)^2 + 12^2 with 12*(-16) + 2*(-16)*12 + 4*12*12 = 0^3.
a(4784) = 1 since 4784 = 60^2 + 28^2 + (-16)^2 + 12^2 with 28*(-16) + 2*(-16)*12 + 4*12*28 = 8^3.
a(8752) = 1 since 8752 = 92^2 + 4^2 + (-16)^2 + (-4)^2 with 4*(-16) + 2*(-16)*(-4) + 4*(-4)*4 = 0^3.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]]
    CQ[n_]:=QQ[n]=n>=0&&IntegerQ[n^(1/3)]
    Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&CQ[x*(-1)^j*y+2(-1)^(j+k)*y*z+4*(-1)^k*z*x],r=r+1],{x,1,Sqrt[n]},{y,0,Sqrt[n-x^2]},{j,0,Min[1,y]},{z,0,Sqrt[n-x^2-y^2]},{k,0,Min[1,z]}];Print[n," ",r];Continue,{n,1,80}]

A282091 Number of ways to write n as x^2 + y^2 + z^2 + w^2 with x + y - z a cube of an integer, where x,y,z,w are nonnegative integers with x >= y <= z and x == y (mod 2).

Original entry on oeis.org

1, 2, 1, 1, 2, 2, 2, 2, 1, 3, 2, 1, 3, 1, 2, 2, 1, 4, 1, 2, 2, 2, 2, 1, 2, 3, 4, 2, 3, 2, 2, 1, 1, 5, 2, 3, 4, 2, 1, 2, 1, 4, 5, 1, 4, 2, 1, 2, 1, 5, 3, 3, 3, 1, 3, 4, 1, 4, 2, 1, 5, 3, 4, 2, 3, 5, 3, 3, 6, 3, 5, 3, 4, 6, 1, 3, 5, 3, 2, 3, 2
Offset: 0

Views

Author

Zhi-Wei Sun, Feb 06 2017

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n = 0,1,2,.... Also, any nonnegative integer can be written as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers and x <= y <= z such that x + y - z is a cube of an integer.
(ii) Any nonnegative integer can be written as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers such that P(x,y,z,w) is a cube of an integer, whenever P(x,y,z,w) is among the following polynomials: 2x-y, 4(2x-y), 4(x+y-z), 2x+y-z, 2*(2x+y-z), 4(2x+y-z), x+2y-2z, 4(x+2y-2z), x+3y-3z, 4(x+3y-3z), 2x+3y-3z, 2(2x+3y-3z), 4(2x+3y-3z), x+5y-5z, 4(x+5y-5z), 2x+4y-10z, 4x+8y-20z, 2x+y-z-w, 4(2x+y-z-w), 4x+y-2z-w, 2(4x+y-2z-w), 4(4x+y-2z-w).
The author has proved that each n = 0,1,2,... can be written as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers such that x (or 4x) is a cube.

Examples

			a(2) = 1 since 2 = 0^2 + 0^2 + 1^2 + 1^2 with 0 = 0 < 1, 0 == 0 (mod 2), and 0 + 0 - 1 = (-1)^3.
a(13) = 1 since 13 = 2^2 + 0^2 + 3^2 + 0^2 with 2 > 0 < 3, 2 == 0 (mod 2), and 2 + 0 - 3 = (-1)^3.
a(18) = 1 since 18 = 2^2 + 2^2 + 3^2 + 1^2 with 2 = 2 < 3, 2 == 2 (mod 2), and 2 + 2 - 3 = 1^3.
a(31) = 1 since 31 = 1^2 + 1^2 + 2^2 + 5^2 with 1 = 1 < 2, 1 == 1 (mod 2), and 1 + 1 - 2 = 0^3.
a(95) = 1 since 95 = 9^2 + 1^2 + 2^2 + 3^2 with 9 > 1 < 2, 9 == 1 (mod 2), and 9 + 1 - 2 = 2^3.
a(479) = 1 since 479 = 15^2 + 7^2 + 14^2 + 3^2 with 15 > 7 < 14, 15 == 7 (mod 2), and 15 + 7 - 14 = 2^3.
a(653) = 1 since 653 = 12^2 + 8^2 + 21^2 + 2^2 with 12 > 8 < 21, 12 == 8 (mod 2), and 12 + 8 - 21 = (-1)^3.
a(1424) = 1 since 1424 = 8^2 + 0^2 + 8^2 + 36^2 with 8 > 0 < 8, 8 == 0 (mod 2), and 8 + 0 - 8 = 0^3.
a(2576) = 0 since 2576 = 24^2 + 16^2 + 40^2 + 12^2 with 24 > 16 < 40, 24 == 16 (mod 2), and 24 + 16 - 40 = 0^3.
a(2960) = 1 since 2960 = 24^2 + 8^2 + 32^2 + 36^2 with 24 > 8 < 32, 24 == 8 (mod 2), and 24 + 8 - 32 = 0^3.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]];
    CQ[n_]:=CQ[n]=IntegerQ[CubeRoot[n]];
    Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&CQ[x+y-z]&&Mod[x-y,2]==0,r=r+1],{y,0,Sqrt[n/3]},{x,y,Sqrt[n-y^2]},{z,y,Sqrt[n-x^2-y^2]}];Print[n," ",r];Continue,{n,0,80}]

A284343 Number of ways to write n as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers and y <= z such that 2*x + y - z is either zero or a power of 8 (including 8^0 = 1).

Original entry on oeis.org

1, 1, 2, 2, 1, 1, 4, 1, 1, 3, 1, 3, 2, 1, 3, 3, 2, 3, 5, 2, 3, 4, 6, 1, 3, 5, 1, 6, 1, 3, 7, 2, 2, 5, 6, 5, 6, 3, 6, 4, 1, 3, 4, 5, 4, 5, 7, 2, 3, 8, 6, 7, 3, 4, 8, 3, 2, 6, 3, 5, 7, 3, 8, 7, 2, 4, 10, 4, 4, 7, 9, 7, 2, 4, 2, 7, 3, 5, 11, 2, 4
Offset: 0

Views

Author

Zhi-Wei Sun, Mar 25 2017

Keywords

Comments

Conjecture: (i) For any c = 1,2,4, each n = 0,1,2,... can be written as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers and y <= z such that c*(2*x+y-z) is either zero or a power of eight (including 8^0 = 1).
(ii) Each n = 0,1,2,... can be written as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers such that P(x,y,z,w) is either zero or a power of four (including 4^0 = 1), whenever P(x,y,z,w) is among the polynomials 2*x-y, x+y-z, x-y-z, x+y-2*z, 2*x+y-z, 2*x-y-z, 2*x-2*y-z, x+2*y-3*z, 2*x+2*y-2*z, 2*x+2*y-4*z, 3*x-2*y-z, x+3*y-3*z, 2*x+3*y-3*z, 4*x+2*y-2*z, 8*x+2*y-2*z, 2*(x-y)+z-w, 4*(x-y)+2*(z-w).
Part (i) of the conjecture is stronger than the first part of Conjecture 4.4 in the linked JNT paper (see also A273432).
Modifying the proofs of Theorem 1.1 and Theorem 1.2(i) in the linked JNT paper slightly, we see that for any a = 1,4 and m = 4,5,6 we can write each n = 0,1,2,... as a*x^m + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers such that x is either zero or a power of two (including 2^0 = 1), and that for any b = 1,2 each n = 0,1,2,... can be written as x^2 + y^2 + z^2 + w^2 with x,y,z,w nonnegative integers such that b*(x-y) is either zero or a power of 4 (including 4^0 = 1).
Starts to differ from A273432 at n=197. - R. J. Mathar, May 25 2023

Examples

			a(4) = 1 since 4 = 0^2 + 0^2 + 0^2 + 2^2 with 0 = 0 and 2*0 + 0 - 0 = 0.
a(5) = 1 since 5 = 1^2 + 0^2 + 2^2 + 0^2 with 0 < 2 and 2*1 + 0 - 2 = 0.
a(7) = 1 since 7 = 1^2 + 1^2 + 2^2 + 1^2 with 1 < 2 and 2*1 + 1 - 2 = 8^0.
a(40) = 1 since 40 = 4^2 + 2^2 + 2^2 + 4^2 with 2 = 2 and 2*4 + 2 - 2 = 8.
a(138) = 1 since 138 = 3^2 + 5^2 + 10^2 + 2^2 with 5 < 10 and 2*3 + 5 - 10 = 8^0.
a(1832) = 1 since 1832 = 4^2 + 30^2 + 30^2 + 4^2 with 30 = 30 and 2*4 + 30 - 30 = 8.
a(2976) = 1 since 2976 = 20^2 + 16^2 + 48^2 + 4^2 with 16 < 48 and 2*20 + 16 - 48 = 8.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]];
    Pow[n_]:=Pow[n]=n==0||(n>0&&IntegerQ[Log[8,n]]);
    Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&Pow[2x+y-z],r=r+1],{x,0,Sqrt[n]},{y,0,Sqrt[(n-x^2)/2]},{z,y,Sqrt[n-x^2-y^2]}];Print[n," ",r],{n,0,80}]
Showing 1-8 of 8 results.