login
A364444
a(n) is the number of integers k with n^2 < k < (n+1)^2 that are the sum of no more than 3 squares, counting multiple representations only once.
2
0, 2, 3, 5, 7, 8, 10, 11, 14, 15, 16, 18, 20, 22, 23, 24, 27, 29, 30, 31, 34, 34, 36, 38, 40, 42, 44, 44, 47, 48, 49, 51, 54, 55, 57, 58, 61, 61, 62, 65, 67, 69, 69, 71, 73, 75, 76, 78, 81, 81, 83, 85, 87, 89, 89, 91, 94, 95, 97, 97, 100, 101, 103, 104, 107, 109
OFFSET
0,2
PROG
(PARI) isA004215(n)= n\4^valuation(n, 4)%8==7 \\ after M. F. Hasler
a364444(n) = sum (k=n^2+1, n^2+2*n, !isA004215(k))
(Python)
def A364444(n): return sum(1 for k in range(n**2+1, (n+1)**2) if (m:=(~k&k-1).bit_length())&1 or (k>>m)&7<7) # Chai Wah Wu, Aug 01 2023
CROSSREFS
KEYWORD
nonn
AUTHOR
Hugo Pfoertner, Aug 01 2023
STATUS
approved