OFFSET
0,4
LINKS
Robert Israel, Table of n, a(n) for n = 0..10000
FORMULA
a(n) = Sum_{1 <= x <= floor(sqrt(n/2))} A000005(n-x^2). - Robert Israel, Apr 23 2026
EXAMPLE
a(7) = 4 counts these triples: (1, 1, 6), (1, 2, 3), (1, 3, 2), (1, 6, 1).
MAPLE
f:= proc(n) local x;
add(NumberTheory:-tau(n-x^2), x=1..floor(sqrt(n/2)))
end proc:
map(f, [$0..100]); # Robert Israel, Apr 23 2026
MATHEMATICA
t[n_, c_] := Module[{r}, r = Flatten[Table[If[n - x^2 <= 0, {},
Map[({x, #, Quotient[n - x^2, #]} &),
Select[Divisors[n - x^2], Divisible[n - x^2, #] &]]], {x, 1,
Floor[Sqrt[n - 1]]}], 1]; Select[r, Apply[c, #] &]];
c = ((#1)^2 <= #2*#3 &);
Join[{0}, Table[Length[t[n, c]], {n, 1, 130}]]
(* Peter J. C. Moses, Mar 29 2026 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Clark Kimberling, Apr 16 2026
STATUS
approved
