A386235 Number of partitions (p, q, r) of n into positive integers such that p + 11*q + 13*r is a perfect square.
1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 4, 6, 3, 7, 8, 6, 7, 6, 9, 8, 9, 9, 9, 15, 11, 13, 16, 13, 17, 15, 16, 17, 16, 19, 19, 23, 19, 21, 27, 23, 26, 24, 25, 29, 27, 28, 30, 32, 32, 34, 37, 35, 36, 37, 38, 40, 38, 38, 44, 46, 43, 46, 48, 50, 50, 48, 50, 50, 54, 52, 56, 60, 54, 64, 63, 62, 64
Offset: 3
Keywords
Examples
n = 12: (4,4,4); 4 + 11*4 + 13*4 = 10^2; (7,4,1); 7 + 11*4 + 13*1 = 8^2; so a(12) = 2.
Links
- Hoang Xuan Thanh, Table of n, a(n) for n = 3..20000
Programs
-
Mathematica
a[n_]:=Module[{cnt=0,p,m2},Do[Do[p=n-q-r;m2=p +11*q+13*r;If[IntegerQ[Sqrt[m2]],cnt++],{r, 1, n - q - 1}],{q,1,n-2}];cnt];Array[a,78,3] (* James C. McMahon, Jul 22 2025 *)
-
PARI
a(n) = {my(cnt = 0); for (q = 1, n-2, for (r = 1, n - q - 1, p = n - q - r; m2 = p + 11*q + 13*r; if (issquare(m2), cnt++););); cnt;}
Formula
Conjecture: a(n) ~ K * n^(3/2) where K = 0.0914... from a(10000) = 91413 and a(20000) = 258667.
Comments