%I #9 Feb 02 2017 18:40:30
%S 0,1,2,6,13,24,43,71,110,166,242,341,469,633,838,1091,1400,1774,2219,
%T 2745,3364,4089,4933,5904,7015,8279,9713,11338,13172,15230,17524,
%U 20071,22895,26025,29485,33294,37472,42040,47026,52463,58383,64816,71785,79318,87444
%N Number of sets of exactly five positive integers <= n having a square element sum.
%H Alois P. Heinz, <a href="/A281865/b281865.txt">Table of n, a(n) for n = 5..1000</a>
%e a(6) = 1: {1,2,3,4,6}.
%e a(7) = 2: {1,2,3,4,6}, {3,4,5,6,7}.
%e a(8) = 6: {1,2,3,4,6}, {1,3,6,7,8}, {1,4,5,7,8}, {2,3,5,7,8}, {2,4,5,6,8}, {3,4,5,6,7}.
%p b:= proc(n, i, t) option remember;
%p `if`(i<t, 0, `if`(n=0, `if`(t=0, 1, 0),
%p `if`(t<1 or n<t*(t+1)/2 or n>(t+1)*(2*i-t)/2, 0,
%p `if`(i>n, 0, b(n-i, i-1, t-1))+b(n, i-1, t))))
%p end:
%p a:= proc(n) option remember; `if`(n<0, 0, a(n-1)+add(
%p b(j^2-n, n-1, 4), j=isqrt(n-10)..isqrt(5*n-10)))
%p end:
%p seq(a(n), n=5..60);
%Y Column k=5 of A281871.
%K nonn
%O 5,3
%A _Alois P. Heinz_, Feb 01 2017
|