login
Number of ways to write n as the sum of two squares and a term of A000009.
3

%I #22 Jan 02 2017 20:00:32

%S 1,2,3,3,4,5,4,4,4,6,5,6,5,6,5,5,5,6,7,7,6,7,7,5,4,7,7,9,5,7,8,7,6,5,

%T 9,6,8,8,6,10,6,9,7,8,5,7,10,7,5,6,9,9,7,10,11,10,6,9,8,5,5,8,10,10,6,

%U 8,10,10,7,8,9,10,8,8,8,9,10,7,8,11

%N Number of ways to write n as the sum of two squares and a term of A000009.

%C Conjecture: a(n) > 0 for all n > 0.

%C Note that the main term of log A000009(n) is Pi*sqrt(n/3). So, A000009(n) eventually grows faster than any polynomial.

%C The conjecture was verified by the author for n up to 4*10^6. After learning this conjecture from the author, Prof. Qing-Hu Hou at Tianjin Univ. finished his verification of the above conjecture for n up to 10^9. - _Zhi-Wei Sun_, Jan 02 2017

%H Zhi-Wei Sun, <a href="/A280386/b280386.txt">Table of n, a(n) for n = 1..10000</a>

%H Zhi-Wei Sun, <a href="http://maths.nju.edu.cn/~zwsun/160p.pdf">Problems on combinatorial properties of primes</a>, in: M. Kaneko, S. Kanemitsu and J. Liu (eds.), Number Theory: Plowing and Starring through High Wave Forms, Proc. 7th China-Japan Seminar (Fukuoka, Oct. 28--Nov. 1, 2013), Ser. Number Theory Appl., Vol. 11, World Sci., Singapore, 2015, pp. 169-187.

%e a(1) = 1 since 1 = 0^2 + 0^2 + 1 with 1 = A000009(1) = A000009(2).

%e a(2) = 2 since 2 = 0^2 + 1^2 + 1 = 0^2 + 0^2 + 2 with 1 = A000009(1) = A000009(2) and 2 = A000009(3) = A000009(4).

%t SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]];

%t q[n_]:=q[n]=PartitionsQ[n];

%t ex={};Do[r=0;m=2;Label[bb];If[q[m]>n,Goto[cc]];Do[If[SQ[n-q[m]-x^2],r=r+1],{x,0,Sqrt[(n-q[m])/2]}];m=m+If[m<3,2,1];Goto[bb];Label[cc];ex=Append[ex,r];Continue,{n,1,80}]

%Y Cf. A000009, A000290, A001481.

%K nonn

%O 1,2

%A _Zhi-Wei Sun_, Jan 01 2017