Please fill out this quiz, and press the "Submit" button at the end. Don't collaborate with anyone on quiz exercise solutions.
Please answer all questions.
SID: [No spaces and no dashes.]
Login ID :
1. Suppose we are given a mxn matrix M[1..m][1..n]. We want to find the largest subrectangle of the matrix, such that all of the entries of the matrix within the subrectangle are zero. (By largest, we mean largest by area.)
Professor Celadon proposes using dynamic programming, with the following choice of subproblems: a subproblem is specified by parameters r,s,t,u such that 1 ≤ r ≤ s ≤ m and 1 ≤ t ≤ u ≤ n. He suggests we define F(r,s,t,u) = 1 if all of the entries in the rectangle M[r..s][t..u] are zero (i.e., if M[i][j] = 0 for all i,j that satisfy r ≤ i ≤ s and t ≤ j ≤ u), or 0 otherwise.
How many subproblems are there, in Professor Celadon's approach, as a function of m and n? It's OK to use big-O notation.
How many subproblems are there, in Professor Ecru's approach, as a function of m and n? It's OK to use big-O notation.