A338696 Number of ways to write n as x^3 + y^2 + z*(3*z+2), where x and y are nonnegative integers, and z is an integer.
3, 3, 1, 1, 3, 3, 1, 2, 6, 5, 1, 2, 3, 2, 1, 3, 8, 4, 0, 2, 3, 4, 1, 3, 7, 4, 2, 3, 3, 3, 3, 4, 7, 4, 2, 4, 5, 5, 1, 2, 7, 5, 3, 6, 5, 1, 2, 3, 7, 5, 2, 6, 2, 2, 1, 2, 10, 5, 2, 4, 2, 1, 1, 7, 11, 8, 2, 5, 6, 5, 3, 4, 11, 3, 1, 5, 5, 2, 1, 5, 8, 6, 4, 5, 5, 5, 3, 2, 9, 7, 2, 6, 4, 5, 1, 5, 10, 5, 2, 4
Offset: 1
Keywords
Examples
a(63) = 1 with 63 = 3^3 + 6^2 + 0*(3*0+2). a(327) = 1 with 327 = 5^3 + 13^2 + 3*(3*3+2). a(478) = 1 with 478 = 6^3 + 1^2 + 9*(3*9+2). a(847) = 1 with 847 = 1^3 + 29^2 + 1*(3*1+2). a(1043) = 1 with 1043 = 3^3 + 20^2 + 14*(3*14+2). a(3175) = 1 with 3175 = 5^3 + 35^2 + (-25)*(3*(-25)+2).
Links
- Zhi-Wei Sun, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
OctQ[n_]:=OctQ[n]=IntegerQ[Sqrt[3n+1]]; tab={};Do[r=0;Do[If[OctQ[n-x^3-y^2],r=r+1],{x,0,n^(1/3)},{y,0,Sqrt[n-x^3]}];tab=Append[tab,r],{n,1,100}];Print[tab]
Comments