Ask Math Expert


Home >> Math

Assignment 4-

1. For each of the following sequences a0, a1, a2, . . . , determine a closed form for the generating series A(x) = a0 + a1x + a2x2 + · · · .

(a) an = 0 if n is odd, an = 3n if n is even.

(b) an = i=0nbicn-i where the sequence b0, b1, b2, . . . has generating 1/(1-x)2 and the sequence c0, c1, c2, . . has generating series 1/√(1-x).

2. Briefly explain why the number of ways to change n cents into pennies, nickels, dimes, and quarters is the coefficient of xn in

1/(1 - x)(1 - x5)(1 - x10)(1 - x25),

and use this along with a computer to determine the number of ways of changing a dollar into pennies, nickels, dimes and quarters.

3. In this problem, we will show that the average number of comparisons in the QUICKSORT algorithm for sorting n distinct numbers is O(n log n). This algorithm takes a list of n distinct numbers, and sorts them in order from least to greatest. The algorithm runs as follows. First, select a random number p in the list. Then, compare p to all other elements in the list. If an element is less than p, place it in the list anywhere before p. If an element is greater than p, place it in the list anywhere after p. Then, recursively apply this algorithm to the sublist of elements falling before p, and the sublist of elements falling after p, while leaving p in its place. Thus, if an is the average number of comparisons in the QUICKSORT algorithm to sort n distinct numbers, we have a0 = 0 and for n ≥ 1,

an = n - 1 + (1/n) i=0n(ai-1 + an-i)

(a) Let f(x) be the generating series for the sequence {a0, a1, a2, . . .}. Deduce that

f'(x) - (2/1 - x)f(x) = 2x/(1 - x)3.

(b) Using differential equations, one can conclude (formally) that

f(x) = -2(x + log(1 - x))/(1 - x)2

(you do not need to show this). Use this, along with the fact that there is a constant M > 0 such that k=1∑n 1/k < M · log n (you can assume this result), to show that there is a constant C > 0 such that the average number of comparisons in the QUICKSORT algorithm is less than C · n log n.

4. Let A ⊂ {0, 1} be the set of binary strings in which each block of 0s has odd length, and each block of 1s has length one or two. Let A(x) = n=0anxn be the generating series for A with respect to length (i.e. with respect to the weight function ω: A → {0, 1, 2, 3, . . .} given by ω(a) = number of bits in a). Show that every string in A can be uniquely described by the regular expression

(∅ ∪ (00)0)((1 ∪ 11)(00)0)(∅ ∪ 1 ∪ 11).

and use this to find A(x), and hence a recurrence equation for an.

5. A beautiful theorem of Lagrange allows us to extract coefficients of generating series that satisfy certain functional equations. Lagrange's Theorem states that if f(x) is a generating series that satisfies the functional equation f(x) = x · g(f(x)) where g is some other function, then

[xn]f(x) = 1/n[yn-1]gn(y).

We will use this to count cubic plane planted trees. A cubic plane planted tree is a plane planted tree, all of whose vertices are adjacent to at most 4 other vertices.

(a) Let C be the set of cubic plane planted trees, and let ∈ be the unique cubic plane planted tree with only one non-root vertex (as in class). Explain why there is a bijection between C - { ∈} and

k=1∪3{ ∈} × Ck

that preserves the number of non-root vertices and deduce that if C(x) is the generating series for C with respect to the weight function ω: C → {0, 1, 2, . . .} defined by ω(c) = number of non-root vertices in c, then

C(x) = x · (1 - C4(x)/1 - C(x)).

(b) Use Lagrange's Theorem to deduce that the number of cubic plane planted trees on n vertices is

891_Figure.png

Math, Academics

  • Category:- Math
  • Reference No.:- M91822963
  • Price:- $35

Priced at Now at $35, Verified Solution

Have any Question?


Related Questions in Math

Questions -q1 prove the following identitiesa sinx y sinx

Questions - Q1. Prove the following identities a. sin(x + y) + sin(x - y) = 2 sin x cos y b. sec(x - y) = cos(x + y)/(cos 2 x - sin 2 y) c. tan 2 x - sin 2 x = (tan x sin x) 2 Q2. Solve the following equations for x ∈ [0 ...

Maths assignment - 1 analysis of a data setusing a

Maths Assignment - 1. Analysis of a data set Using a continuous data set you are requested to collect in the types of data and gathering data section, perform a statistical analysis on your data. You have opportunities t ...

Questions - provide solution to the following questionsq1

Questions - Provide solution to the following questions: Q1. Evaluate the following: ∫xsin3xdx Q2. If , then for what value of α is A an identity matrix? Q3. The line y = mx + 1 is a tangent to the curve y 2 = 4x. Find t ...

Assessment taskpractical investigation- question 1 requires

Assessment Task Practical Investigation - Question 1 requires selecting reference points from the graph. It is expected that each student will choose different reference points to other students. Take note of the criteri ...

1 suppose that n 10088821 is a product of two distinct

1. Suppose that n = 10088821 is a product of two distinct primes, and Φ(n) = 10082272. Determine the prime factors of n. 2. It is easy to show that the converse of Fermat's Theorem does not hold; i.e., the congruence a n ...

Assignment -question 1 let t and or 0 1 be a boolean

Assignment - Question 1. Let (T, ∧, ∨,', 0, 1) be a Boolean Algebra. Define ∗ : T × T → T and o : T × T → T as follows: x ∗ y := (x ∨ y)' x o y := (x ∧ y)' (a) Show, using the laws of Boolean Algebra, how to define x ∗ y ...

Assignment - provide solution to the following questionsq1

Assignment - Provide solution to the following questions: Q1. Evaluate the following: ∫xsin3x dx Q2. If , then for what value of α is A an identity matrix? Q3. The line y = mx + 1 is a tangent to the curve y 2 = 4x. Find ...

Question 1 what is the nth order approximation using taylor

Question: 1. What is the nth order approximation using Taylor series? 2. What is Error Propagation? 3. Please explain what the total numerical error is? Please illustrate how the change of step size will affect the total ...

Mathematics- algebraic geometry problemlet k denotes an

Mathematics- Algebraic Geometry Problem Let K denotes an algebraically closed field and let P 1 be constructed as in Example 5.5(a) in Gathmanns notes, i.e. P 1 is the gluing of X 1 = A 1 and X 2 = A 1 along  the open su ...

Mathematics- algebraic geometry problemlet k denotes an

Mathematics- Algebraic Geometry Problem Let K denotes an algebraically closed field and let P 1 be constructed as in Example 5.5(a) in Gathmanns notes, i.e. P 1 is the gluing of X 1 = A 1 and X 2 = A 1 along  the open su ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As