OFFSET
0,3
COMMENTS
For a guide to related sequences, see A211795.
FORMULA
a(n) + A212151(n) = n^4.
MATHEMATICA
t = Compile[{{n, _Integer}}, Module[{s = 0},
(Do[If[w*x + y*z >= n, s = s + 1],
{w, 1, #}, {x, 1, #}, {y, 1, #}, {z, 1, #}] &[n]; s)]];
Map[t[#] &, Range[0, 40]] (* A212240 *)
(* Peter J. C. Moses, Apr 13 2012 *)
PROG
(Python)
from sympy import divisor_count
def A212240(n): return n**4-sum((sum(divisor_count(i+1)*divisor_count(j-i) for i in range(j>>1))<<1)+(divisor_count(j+1>>1)**2 if j&1 else 0) for j in range(1, n-1)) # Chai Wah Wu, Jul 26 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Clark Kimberling, May 07 2012
EXTENSIONS
Offset changed to 0 by Georg Fischer, Feb 03 2022
STATUS
approved