#OK to post homework #Kent Mei, 12/13/20, Assignment 24 #--------------------------------- #Part 1 #i) #pnC(97,{1,4,5},7); #108236 integer partitions match the description. #ii) #pnD(97,3); #19990 integer partitions match the description. #--------------------------------- #Part 2 pnkDC:=proc(n,k,d,C,m) local i: option remember: if k > n or not member(k mod m, C) then return 0: fi: if k = n then return 1: fi: add(pnkDC(n-k,i,d,C,m),i=1..k-d): end: pnDC:=proc(n,d,C,m) local i: add(pnkDC(n,i,d,C,m), i = 1..n): end: #i) #pnDC(97,0,{1,4,5},7); #108236 #pnDC(97,3,{0},1); #19990 #After checking on various inputs, it seems like pnDC(n,0,C,m) does give the same output as pnC(n,C,m) #and pnDC(n,d,{0},1) give the same output as pnD(n,d). #ii) #[seq(pnDC(n,1,{1},2),n=1..40)]; #[1, 0, 1, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 4, 5, 5, 5, 6, 7, 8, 8, 9, 11, 12, 12, 14, 16, 17, 18, 20, 23, 25, 26, 29, 33, 35, 37, 41, 46] #It is in the OEIS as A700. #iii) #[seq(pnDC(n,2,{1,4},5),n=1..40)]; #[1, 0, 0, 1, 1, 1, 1, 0, 1, 2, 2, 1, 1, 2, 3, 3, 2, 2, 3, 5, 5, 3, 3, 5, 7, 7, 6, 5, 7, 11, 11, 8, 8, 12, 15, 15, 13, 12, 16, 22] #It seems to be in the OEIS as A203776, the sequence seems to be equivalent to the case where it's just distinct parts instead of having the difference between consecutive terms being at least 2. #--------------------------------- #Part 3 #If we consider the infinite set of all integer partitions regardless of n, #Weight([a1,a2,...,ak]) = q^(a1+...+ak) #When we pick a random integer partition with distinct steps, these are the decisions we can make: #We can either have no 1s, or one 1 (we can't have more because it would no longer be distinct). #We can either have no 2s, or one 2 #and so on. #So, we can form a integer partition with distinct steps by making these decisions for i = 1..infty. #Par_distinct = Product(Par(Only using i), i = 1..infty) #For weight enumerators, (1+q) * (1+q^2) * (1+q^3) + ... = Product(1 + q^i,i = 1..infty) as desired. #--------------------------------- #Part 4 #When we pick a random integer partition with odd steps, these are the decisions we can make: #We can have any amount of 1s #We can have no 2s #We can have any amount of 3s #We can have no 4s #and so on. #In terms of weight enumerators: #|Par|_q = |Set of 1s|_q * |Set of 3s|_q * ... #(1+q+q^2+q^3+...) * (1+q^3+q^6+q^9+...) * ... #1/(1-q) * 1/(1-q^3) * ... #Product(1/(1-q^(2*i+1), i = 0..infty)) as desired. #--------------------------------- #Part 5 #We have to show that Product(1+q^i,i = 1..infty) = Product(1/1-q^(2*j+1), j = 0..infty). #Product(1+q^i, i = 1..infty) #= Product( (1-q^(2i)) / (1-q^i) , i = 1..infty ) #= ((1-q^2) * (1-q^4) * (1-q^6) * ...) / ((1-q) * (1-q^2) * (1-q^3) * ...) #= 1 / ((1-q) * (1-q^3) * (1-q^5) * ...) #= Product(1 / (1 - q^(2*j+1), j = 0..infty) #which is the desired result.