A262781 Number of ordered ways to write n as x^2 + phi(y^2) + phi(z^2) (x >= 0 and 0 < y <= z) with y or z prime, where phi(.) is Euler's totient function given by A000010.
0, 0, 1, 2, 1, 0, 2, 3, 1, 1, 2, 3, 2, 3, 2, 2, 1, 3, 3, 1, 2, 3, 4, 1, 1, 3, 2, 3, 2, 4, 1, 3, 2, 2, 3, 1, 3, 3, 4, 2, 2, 3, 5, 5, 1, 4, 4, 4, 2, 6, 4, 4, 4, 6, 3, 4, 5, 4, 5, 4, 4, 3, 6, 4, 2, 3, 3, 5, 4, 4, 4, 3, 1, 4, 5, 4, 3, 6, 3, 1, 2, 3, 4, 4, 5, 5, 3, 3, 2, 8, 5, 3, 4, 2, 4, 4, 2, 3, 7, 2
Offset: 1
Keywords
Links
- Zhi-Wei Sun, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
SQ[n_]:=IntegerQ[Sqrt[n]] f[n_]:=EulerPhi[n^2] Do[r=0;Do[If[f[z]>n,Goto[aa]];Do[If[SQ[n-f[z]-f[y]]&&(PrimeQ[y]||PrimeQ[z]),r=r+1],{y,1,z}];Label[aa];Continue,{z,1,n}];Print[n," ",r];Continue,{n,1,100}]
Formula
a(3) = 1 since 3 = 0^2 + phi(1^2) + phi(2^2) with 2 prime.
a(5) = 1 since 5 = 1^2 + phi(2^2) + phi(2^2) with 2 prime.
a(9) = 1 since 9 = 1^2 + phi(2^2) + phi(3^2) with 2 and 3 both prime.
a(10) = 1 since 10 = 0^2 + phi(2^2) + phi(4^2) with 2 prime.
a(17) = 1 since 17 = 3^2 + phi(2^2) + phi(3^2) with 2 and 3 both prime.
a(20) = 1 since 20 = 4^2 + phi(2^2) + phi(2^2) with 2 prime.
a(24) = 1 since 24 = 4^2 + phi(2^2) + phi(3^2) with 2 and 3 both prime.
a(25) = 1 since 25 = 2^2 + phi(1^2) + phi(5^2) with 5 prime.
a(31) = 1 since 31 = 3^2 + phi(2^2) + phi(5^2) with 2 and 5 both prime.
a(36) = 1 since 36 = 2^2 + phi(5^2) + phi(6^2) with 5 prime.
a(45) = 1 since 45 = 1^2 + phi(2^2) + phi(7^2) with 2 and 7 both prime.
a(73) = 1 since 73 = 5^2 + phi(3^2) + phi(7^2) with 3 and 7 both prime.
a(80) = 1 since 80 = 6^2 + phi(2^2) + phi(7^2) with 2 and 7 both prime.
a(101) = 1 since 101 = 7^2 + phi(5^2) + phi(8^2) with 5 prime.
a(136) = 1 since 136 = 5^2 + phi(1^2) + phi(11^2) with 11 prime.
a(145) = 1 since 145 = 7^2 + phi(7^2) + phi(9^2) with 7 prime.
a(388) = 1 since 388 = 2^2 + phi(7^2) + phi(19^2) with 7 and 19 both prime.
a(649) = 1 since 649 = 11^2 + phi(7^2) + phi(27^2) with 7 prime.
Comments