|
| |
|
|
A161943
|
|
a(n) is the number of different equations that can be made by summing numbers from 1 to n and using every number not more than once.
|
|
12
| |
|
|
0, 0, 1, 3, 7, 17, 43, 108, 273, 708, 1867, 4955, 13256, 35790, 97340, 266240, 732014, 2022558, 5612579, 15634288, 43702232, 122550885, 344661924, 971908613, 2747404212, 7784038617, 22100387619, 62869809733, 179173559128, 511497066733, 1462522478549, 4188024794407
(list; graph; refs; listen; history; internal format)
|
|
|
|
OFFSET
| 1,4
|
|
|
COMMENTS
| The summands of each side are in increasing order and the minimum of all summands is on the left side.
|
|
|
LINKS
| Alois P. Heinz, Table of n, a(n) for n = 1..400
|
|
|
EXAMPLE
| a(3) = 1, as the only equation we can make by summing numbers from the set {1, 2, 3} is 1+2=3. a(4) = 3, as we can make three equations: 1+2=3, 1+3=4, 1+4=2+3.
|
|
|
MAPLE
| b:= proc(n, i) option remember; local m;
m:= i*(i+1)/2;
if n>m then 0
elif n=m then 1
else b(n, i-1) +b(abs(n-i), i-1) +b(n+i, i-1)
fi
end:
a:= proc(n) option remember;
`if`(n>2, b(n, n-1)+ a(n-1), 0)
end:
seq (a(n), n=1..40); # Alois P. Heinz, Aug 31 2009, revised Sep 16 2011
|
|
|
MATHEMATICA
| Table[(Length[ Select[Range[0, 3^n - 1], Apply[Plus, Pick[Range[n], PadLeft[IntegerDigits[ #, 3], n], 1]] == Apply[Plus, Pick[Range[n], PadLeft[IntegerDigits[ #, 3], n], 2]] &]] - 1)/ 2, {n, 14}]
|
|
|
CROSSREFS
| Column k=2 of A196231.
Sequence in context: A102071 A191627 A178778 * A134184 A142975 A114589
Adjacent sequences: A161940 A161941 A161942 * A161944 A161945 A161946
|
|
|
KEYWORD
| nonn
|
|
|
AUTHOR
| Tanya Khovanova (tanyakh(AT)yahoo.com), Jun 22 2009
|
|
|
EXTENSIONS
| More terms from Alois P. Heinz (heinz(AT)hs-heilbronn.de), Aug 31 2009
|
| |
|
|