A253943 a(n) = 3*binomial(n+1,6).
3, 21, 84, 252, 630, 1386, 2772, 5148, 9009, 15015, 24024, 37128, 55692, 81396, 116280, 162792, 223839, 302841, 403788, 531300, 690690, 888030, 1130220, 1425060, 1781325, 2208843, 2718576, 3322704, 4034712, 4869480, 5843376, 6974352, 8282043, 9787869, 11515140
Offset: 5
Keywords
Examples
For A={1,2,3,4,5,6} subsets with 5 elements are {1,2,3,4,5}, {1,2,3,4,6}, {1,2,3,5,6}, {1,2,4,5,6}, {1,3,4,5,6}, {2,3,4,5,6}. Sum of 2 smallest elements of each subset: a(6) = (1+2) + (1+2) + (1+2) + (1+2) + (1+3) + (2+3) = 21 = 3*C(6+1,6) = 3*A000579(6+1).
Links
- G. C. Greubel, Table of n, a(n) for n = 5..1000
- Serhat Bulut and Oktay Erkan Temizkan, Subset Sum Problem, 2015.
- Index entries for linear recurrences with constant coefficients, signature (7,-21,35,-35,21,-7,1).
Crossrefs
Cf. A000579.
Programs
-
Magma
[3*Binomial(n+1,6): n in [5..40]]; // Vincenzo Librandi, Feb 13 2015
-
Mathematica
Drop[Plus @@ Flatten[Part[#, 1 ;; 2] & /@ Subsets[Range@ #, {5}]] & /@ Range@ 28, 4] (* Michael De Vlieger, Jan 20 2015 *) 3 Binomial[Range[6, 29], 6] (* Michael De Vlieger, Feb 13 2015, after Alonso del Arte at A253946 *)
-
SageMath
def A253943(n): return 3*binomial(n+1,6) print([A253943(n) for n in range(5,51)]) # G. C. Greubel, Apr 03 2025
Formula
a(n) = 3*C(n+1,6) = 3*A000579(n+1).
From Amiram Eldar, Jan 09 2022: (Start)
Sum_{n>=5} 1/a(n) = 2/5.
Sum_{n>=5} (-1)^(n+1)/a(n) = 64*log(2) - 661/15. (End)
From G. C. Greubel, Apr 03 2025: (Start)
G.f.: 3*x^5/(1-x)^7.
E.g.f.: (3/6!)*x^5*(x+6)*exp(x). (End)
Extensions
More terms from Vincenzo Librandi, Feb 13 2015
Comments