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

A273432 Number of ordered ways to write n as x^2 + y^2 + z^2 + w^2 with 2*x + y - z a nonnegative cube, where x,y,z,w are nonnegative integers with y <= z.

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, May 22 2016

Keywords

Comments

Conjecture: (i) For each c = 1, 2, 4 and n = 0,1,2,..., we can write n as x^2 + y^2 + z^2 + w^2 with c*(2x+y-z) a nonnegative cube, where x,y,z,w are nonnegative integers with y <= z.
(ii) Each n = 0,1,2,.... can be written as x^2 + y^2 + z^2 + w^2 with x-y+z a nonnegative cube, where x,y,z,w are integers with x >= y >= 0 and x >= |z|.
The author proved in arXiv:1604.06723 that for each a = 1, 2 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 + a*z is a cube.
See also A273458 for a similar conjecture.
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 + 0^2 + 1^2 with 0 = 0 and 2*0 + 0 - 0 = 0^3.
a(4) = 1 since 4 = 0^2 + 0^2 + 0^2 + 2^2 with 0 = 0 and 2*0 + 0 - 0 = 0^3.
a(8) = 1 since 8 = 0^2 + 2^2 + 2^2 + 0^2 with 2 = 2 and 2*0 + 2 - 2 = 0^3.
a(10) = 1 since 10 = 1^2 + 1^2 + 2^2 + 2^2 with 1 < 2 and 2*1 + 1 - 2 = 1^3.
a(13) = 1 since 13 = 2^2 + 0^2 + 3^2 + 0^2 with 0 < 3 and 2*2 + 0 - 3 = 1^3.
a(23) = 1 since 23 = 1^2 + 2^2 + 3^2 + 3^2 with 2 < 3 and 2*1 + 2 - 3 = 1^3.
a(26) = 1 since 26 = 1^2 + 3^2 + 4^2 + 0^2 with 3 < 4 and 2*1 + 3 - 4 = 1^3.
a(28) = 1 since 28 = 4^2 + 2^2 + 2^2 + 2^2 with 2 = 2 and 2*4 + 2 - 2 = 2^3.
a(40) = 1 since 40 = 4^2 + 2^2 + 2^2 + 4^2 with 2 = 2 and 2*4 + 2 - 2 = 2^3.
a(104) = 1 since 104 = 4^2 + 6^2 + 6^2 + 4^2 with 6 = 6 and 2*4 + 6 - 6 = 2^3.
a(138) = 1 since 138 = 3^2 + 5^2 + 10^2 + 2^2 with 5 < 10 and 2*3 + 5 - 10 =1^3.
a(200) = 1 since 200 = 0^2 + 10^2 + 10^2 + 0^2 with 10 = 10 and 2*0 + 10 - 10 = 0^3.
a(296) = 1 since 296 = 8^2 + 6^2 + 14^2 + 0^2 with 6 < 14 and 2*8 + 6 - 14 = 2^3.
a(328) = 1 since 328 = 0^2 + 6^2 + 6^2 + 16^2 with 6 = 6 and 2*0 + 6 - 6 = 0^3.
a(520) = 1 since 520 = 4^2 + 2^2 + 10^2 + 20^2 with 2 < 10 and 2*4 + 2 - 10 = 0^3.
a(776) = 1 since 776 = 0^2 + 10^2 + 10^2 + 24^2 with 10 = 10 and 2*0 + 10 - 10 = 0^3.
a(1832) = 1 since 1832 = 4^2 + 30^2 + 30^2 + 4^2 with 30 = 30 and 2*4 + 30 - 30 = 2^3.
a(2976) = 1 since 2976 = 20^2 + 16^2 + 48^2 + 4^2 with 16 < 48 and 2*20 + 16 - 48 = 2^3.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]]
    CQ[n_]:=CQ[n]=IntegerQ[n^(1/3)]
    Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&CQ[2x+y-z],r=r+1],{x,0,n^(1/2)},{y,0,Sqrt[(n-x^2)/2]},{z,y,Min[2x+y,Sqrt[n-x^2-y^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}]

A281494 Number of ordered ways to write n as x^2 + y^2 + z^2 + w^2 with x + y + z + w = 2^(floor((ord_2(n)+1)/2)), where ord_2(n) is the 2-adic order of n, and x,y,z,w are integers with |x| <= |y| <= |z| <= |w|.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Jan 22 2017

Keywords

Comments

The author proved in arXiv:1701.05868 that a(n) > 0 for all n > 0. This is stronger than Lagrange's four-square theorem.
It seems that a(n) = 1 only for n = 1, 5, 11, 17, 29, 41, 101, 107, 2*4^k and 14*4^k (k = 0,1,2,...).

Examples

			a(1) = 1 since 1 = 0^2 + 0^2 + 0^2 + 1^2 with 0 + 0 + 0 + 1 = 1 =2^0 = 2^(floor((ord_2(1)+1)/2)).
a(2) = 1 since 2 = 0^2 + 0^2 + 1^2 + 1^2 with 0 + 0 + 1 + 1 = 2 = 2^(floor((ord_2(2)+1)/2)).
a(5) = 1 since 5 = 0^2 + 0^2 + (-1)^2 + 2^2 with 0 + 0 + (-1) + 2 = 1 = 2^0 = 2^(floor((ord_2(5)+1)/2)).
a(6) = 2 since 6 = 0^2 + 1^2 + (-1)^2 + 2^2 = 0^2 + (-1)^2 + 1^2 + 2^2 with 0 + 1 + (-1) + 2 = 0 + (-1) + 1 + 2 = 2 = 2^(floor((ord_2(6)+1)/2)).
a(11) = 1 since 11 = 0^2 + (-1)^2 + (-1)^2 + 3^2 with 0 + (-1) + (-1) + 3 = 1 = 2^0 = 2^(floor((ord_2(11)+1)/2)).
a(14) = 1 since 14 = 0^2 + 1^2 + (-2)^2 + 3^2 with 0 + 1 + (-2) + 3 = 2 = 2^(floor((ord_2(14)+1)/2)).
a(17) = 1 since 17 = 0^2 + 2^2 + 2^2 + (-3)^2 with 0 + 2 + 2 + (-3) = 1 = 2^0 = 2^(floor((ord_2(17)+1)/2)).
a(41) = 1 since 41 = 0^2 + 0^2 + (-4)^2 + 5^2 with 0 + 0 + (-4) + 5 = 1 = 2^0 = 2^(floor((ord_2(41)+1)/2)).
a(101) = 1 since 101 = 0^2 + (-1)^2 + (-6)^2 + 8^2 with 0 + (-1) + (-6) + 8 = 1 = 2^0 = 2^(floor((ord_2(101)+1)/2)).
a(107) = 1 since 107 = (-1)^2 + (-3)^2 + (-4)^2 + 9^2 with (-1) + (-3) + (-4) + 9 = 1 = 2^0 = 2^(floor((ord_2(107)+1)/2)).
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]];
    Ord[p_,n_]=Ord[p,n]=IntegerExponent[n,p];
    Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&((-1)^i*x+(-1)^j*y+(-1)^k*z+(-1)^s*Sqrt[n-x^2-y^2-z^2]==2^(Floor[(Ord[2,n]+1)/2])),r=r+1],{x,0,Sqrt[n/4]},{i,0,Min[x,1]},{y,x,Sqrt[(n-x^2)/3]},{j,0,Min[y,1]},{z,y,Sqrt[(n-x^2-y^2)/2]},{k,0,Min[z,1]},{s,0,Min[Sqrt[n-x^2-y^2-z^2],1]}];
    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}]
Showing 1-7 of 7 results.