Solutions for Math 173 - Generating Functions, Exams of Mathematics

Solutions for various problems related to generating functions (gf) in math 173. Topics such as encoding differences between successive numbers picked, multiplying two gfs, and finding the mini-gf for each pile with no restrictions. The solutions involve using the difference rule and the formula for [(1-x)n].

Typology: Exams

Pre 2010

Uploaded on 08/30/2009

koofers-user-49e
koofers-user-49e 🇺🇸

9 documents

1 / 2

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Suggested Solutions Math 173 March 5, 2009
(1) 6.1; 19) What would we like our GF to look like? Since there are five numbers to pick, we’d
like five terms multiplied together; one for each choice. And we’d like the coefficient of xn
(after everything is multiplied out) to be the number of ways of making the selection from
1,2,...n. But for the latter condition to be true, the exponents in each of the five pieces
can’t be the actual numbers picked. The only thing that makes sense is for them to encode
the differences between successive numbers picked. But even this setup isn’t quite right:
We will need a sixth “choice” that encodes the difference between the final number picked
and n+ 1.
This is a very similar setup to the “extra” box we introduced for those integer-equation
problems like x1+x2+x35. In this case, you can think of the problem as asking you to
choose six numbers between 1 and n+ 1 where you must choose n+ 1.
So our first choice will be the difference between the lowest number picked and 1: encoded
as (1 + x+x2+· · · ). The second through fifth choices will be the differences between
successive numbers. We need a difference of at least two to avoid consecutive choices, so we
can use (x2+x3+· · · )4. The sixth choice will be the difference between the fifth number
picked and the sixth number (i.e., n+ 1). This difference needs to be at least 1. So the
mini-GF here will be (x+x2+x3+· · · ). This leaves us with a final answer of
[xn](1 + x+x2+· · · )(x2+x3+x4+· · · )4(x+x2+x3+· · · ).
Notice that the book sets things up a little differently. We get their answer if we factor
out an x·x4.
(2) 6.2; 3) This is a special case of the general problem of multipling two GF’s. Since the first
GF is so simple, it’s best just to multiply out:
[x8](1 + x2+x4)(1 + x)m= [x8](1 + x)m+ [x8]x2(1 + x)m+ [x8]x4(1 + x)m
=m
8+ [x6](1 + x)m+ [x4](1 + x)m=m
8+m
6+m
4.
(3) 6.2; 17) With no restrictions, the mini-GF for each pile would be (1 + x+x2+· · · ).
The possible number of balls to pick is 2,3,4, . . .. We encode this in a GF with
x2+x3+x4+· · · . Since the mini-GF for each pile is the same, we end up with
[x10](x2+x3+x4+· · · )3= [x4](1 + x+x2+· · · )3
= [x4]1
(1 x)3=4+31
4
from the formula.
The first mini-GF becomes (1 + x+x2), leaving [x10 ](1 + x+x2)(1 + x+x2+· · · )2
for our final GF. So our answer is
[x10]1
(1 x)2+ [x9]1
(1 x)2+ [x8]1
(1 x)2
=10 + 2 1
10 +9+21
9+8+21
8.
Before reading further, see if you can figure out what the book did for its answer.
1
pf2

Partial preview of the text

Download Solutions for Math 173 - Generating Functions and more Exams Mathematics in PDF only on Docsity!

Suggested Solutions — Math 173 — March 5, 2009

(1) 6.1; 19) What would we like our GF to look like? Since there are five numbers to pick, we’d like five terms multiplied together; one for each choice. And we’d like the coefficient of xn (after everything is multiplied out) to be the number of ways of making the selection from 1 , 2 ,... n. But for the latter condition to be true, the exponents in each of the five pieces can’t be the actual numbers picked. The only thing that makes sense is for them to encode the differences between successive numbers picked. But even this setup isn’t quite right: We will need a sixth “choice” that encodes the difference between the final number picked and n + 1. This is a very similar setup to the “extra” box we introduced for those integer-equation problems like x 1 + x 2 + x 3 ≤ 5. In this case, you can think of the problem as asking you to choose six numbers between 1 and n + 1 where you must choose n + 1. So our first choice will be the difference between the lowest number picked and 1: encoded as (1 + x + x^2 + · · · ). The second through fifth choices will be the differences between successive numbers. We need a difference of at least two to avoid consecutive choices, so we can use (x^2 + x^3 + · · · )^4. The sixth choice will be the difference between the fifth number picked and the sixth number (i.e., n + 1). This difference needs to be at least 1. So the mini-GF here will be (x + x^2 + x^3 + · · · ). This leaves us with a final answer of [xn]

(1 + x + x^2 + · · · )(x^2 + x^3 + x^4 + · · · )^4 (x + x^2 + x^3 + · · · )

Notice that the book sets things up a little differently. We get their answer if we factor out an x · x^4. (2) 6.2; 3) This is a special case of the general problem of multipling two GF’s. Since the first GF is so simple, it’s best just to multiply out:

[x^8 ]

(1 + x^2 + x^4 )(1 + x)m

= [x^8 ](1 + x)m^ + [x^8 ]

x^2 (1 + x)m

  • [x^8 ]

x^4 (1 + x)m

m 8

  • [x^6 ](1 + x)m^ + [x^4 ](1 + x)m^ =

m 8

m 6

m 4

(3) 6.2; 17) With no restrictions, the mini-GF for each pile would be (1 + x + x^2 + · · · ).

  • The possible number of balls to pick is 2, 3 , 4 ,.. .. We encode this in a GF with x^2 + x^3 + x^4 + · · ·. Since the mini-GF for each pile is the same, we end up with [x^10 ](x^2 + x^3 + x^4 + · · · )^3 = [x^4 ](1 + x + x^2 + · · · )^3

= [x^4 ]

(1 − x)^3

from the formula.

  • The first mini-GF becomes (1 + x + x^2 ), leaving [x^10 ](1 + x + x^2 )(1 + x + x^2 + · · · )^2 for our final GF. So our answer is

[x^10 ]

(1 − x)^2

  • [x^9 ]

(1 − x)^2

  • [x^8 ]

(1 − x)^2

=

Before reading further, see if you can figure out what the book did for its answer.

1

2

Answer: They used the difference rule to first compute [x^10 ](1 − x)−^3 , then subtracted off the number of ways of choosing at least three balls from the first pile).

  • The third mini-GF becomes (1 + x^2 + x^4 + · · · ), leaving

[x^10 ](1 + x + x^2 + · · · )^2 (1 + x^2 + x^4 + · · · ) =

∑^5

b=

[x^10 −^2 b]

(1 − x)^2

∑^5

b=

10 − 2 b + (2 − 1) 10 − 2 b

(4) 6.2; 31) The RHS is [xr](1 + x)m+n^ = [xr](1 + x)m(1 + x)n. But if we use Rule 6 in the table on pg. 253, we immediately get the LHS.