Name: Princeton University ORF 523 Final Exam, Spring 2016 Thursday, May 5, 9am, to Tuesday, May 10, 11am Instructor: A.A. Ahmadi AI: G. Hall 1. Please write out and sign the following pledge on top of the first page of your exam: I pledge my honor that I have not violated the Honor Code or the rules specified by the instructor during this assignment. 2. Don t forget to write your name. Make a copy of your solutions and keep it. 3. The assignment is not to be discussed with anyone except possibly the professor and the TA. You can only ask clarification questions as public questions on Piazza. 4. You are allowed to consult the lecture notes, your own notes, the recommended textbooks of the course, the problem sets and their solutions (yours and ours), the midterm exams and their solutions (yours and ours), but nothing else. You can only use the Internet in case you run into problems related to MATLAB, CVX or YALMIP. (There should be no need for that either hopefully.) 5. For all problems involving MATLAB, CVX, or YALMIP, show your code. The MATLAB output that you present should come from your code. 6. The assignment is to be turned in before Tuesday, May 10, at 11 AM in the box for ORF 523 in Sherrerd 123. Please time stamp your exam (just write the time of drop off and sign it). If you are away, you can email a single PDF file to the instructor and the AI. 7. Good luck!
Grading Problem 1 20 pts Problem 2 20 pts Problem 3 20 pts Problem 4 20 pts Problem 5 20 pts TOTAL 100 1
Problem 1: To cheat or not to cheat? A professor gives out a 5-day take-home final exam to the students in his graduate course. 1 Though they have signed an honor pledge not to cheat, some students (unlike the ones at Princeton) are tempted to search on Google for answers to the exam questions. To discourage them from doing this, the professor has collected a set of aggregate data points (x i, y i ) from students of past years, where x i is the fraction of time spent on Google throughout the exam and y i is the average grade (out of 100) received as a result. These data points are as follows: {(0, 85), (0.15, 50), (0.30, 43), (0.45, 42), (0.6, 39), (0.75, 35), (0.9, 25)}. The statistician colleagues of this professor have performed some model selection hackery and learned that the relationship between x and y is best described by a degree-3 polynomial p(x) = c 0 + c 1 x + c 2 x 2 + c 3 x 3. They have also argued, very convincingly, that the exam grade is a nonincreasing function of the fraction of time spent on the Internet. 1. Fit a cubic polynomial to the data such that least squares error, i.e., 7 (p(x i ) y i ) 2 (1) i=1 is minimized. Report the optimal value as well as the optimal polynomial and plot both the data points and your polynomial on the same graph. Notice that the data that was given to you is nonincreasing. Is the optimal function you found nonincreasing? 2. Show that a quadratic univariate polynomial p is nonnegative on an interval [a, b], a < b, if and only if p(x) = s(x) + λ(x a) (b x) for some λ 0 and some sum of squares polynomial s(x) of degree 2. 3. Solve a new optimization problem with objective (1) but with the additional constraint that your polynomial should be nonincreasing over [0, 1]. Report the optimal value as well as the optimal polynomial and plot both the data points and your polynomial on the same graph. 2 1 All characters appearing in this question are fictitious. Any resemblance to real persons, living or dead, is purely coincidental. 2 We wonder what reverse engineering we ll be able to do with your polynomial? ;) 2
Problem 2: Complexity of SDP feasibility Consider the following decision problem: Given A i S n n, b i R, i = 1,..., m, all with rational entries, decide if there exists a matrix X S n n such that Tr(A i X) = b i, X 0. Determining the complexity of this question is one of the main outstanding open problem in semidefinite programming. At the moment, the problem is not even known to be in NP. 3 1. One may be tempted to conclude that the problem is in NP because if the SDP is feasible, then we can just write down a solution and check its validity (testing positive semidefiniteness of a given n n matrix can be done in O(n 3 )). Produce a family of SDP feasibility problems where any feasible solution takes an exponential number of bits to write down with respect to the input size. (You don t need to put your SDP family in the standard form given above.) 2. Produce a family of SOCP feasibility problems where any feasible solution takes an exponential number of bits to write down with respect to the input size. Hint: See if you can make your SDP problems involve only 2 2 matrices. 3. Here is another shockingly simple problem whose complexity is unknown: Given positive integers a 1,..., a r, k, decide if a1 + + a r k. Show that if SDP feasibility is in NP (resp. P), then this problem is in NP (resp. P). Problem 3: Convex optimization on Princeton s campus In the file princetoncampus.png, you can see a bird s eye view of campus with the 6 undergraduate residential colleges, and Dillon gym, marked by crosses. Open this image in Matlab using the following code once you have added the image to your Matlab path: 1 c o l l e g e s = imread ( princetoncampus. png ) ; 2 imshow ( c o l l e g e s, I n i t i a l M a g n i f i c a t i o n,50) 3 hold on 3 Contrast this with testing LP feasibility, which is in P, and with the fact that we can solve SDPs to arbitrary accuracy in polynomial time. 3
We have placed a grid (a coordinate system) on the image with (0, 0) in the lower left corner. On this grid, the colleges have the following coordinates: z1 = (11, 10) for Forbes z2 = (22, 15) for Whitman z3 = (30, 20) for the regroupment Butler-Wilson z4 = (10, 34) for the regroupment Rockfeller-Mathey Dillon gym has coordinates z5 = (18.5, 21.5). The Matlab file Circledraw.m attached will enable you to plot a circle on this map of campus by using the command Circledraw(x,y,r, color ) where (x, y) are the coordinates of the center of the circle in this new coordinate system, r is its radius, and color its color. The goal in this problem is to find the optimal location of a new gym that minimizes the sum of the squares of distances to the colleges under the following constraints: Case 1: The distance from the new gym to a fire hose located at (30, 30) must be no more than 8. 4
Case 2: The distance from the new gym to Dillon gym must be no less than 8. Case 3: The new gym must simultaneously be at a distance no greater than 8 from the fire hose but no less than 8 from Dillon gym. In each case, answer the following questions: 1. Is the original problem formulation convex? 2. Report the optimal location using CVX. Plot the optimal solution and the boundary of the feasible set on the map. Hint: When appropriate, try and apply an SDP formulaion or an SDP relaxation. Problem 4: Nonnegativity on the simplex Consider the following parametric quadratic function in 4 variables f c (x) := x T Q c x + b T x + r, where x = (x 1, x 2, x 3, x 4 ) T, 9 3/2 3 2 3/2 8 5/2 c 1/2 ( T Q c = 3 5/2 1 9, b = 1 4 5 1), r = 2. 2 c 1/2 9 4 Find the smallest value of c (up to 2 digits after the decimal point) for which f c (x) 0 for any x on the simplex (i.e., the set {x R 4 4 i=1 x i = 1, x i 0, i = 1,..., 4}). Problem 5: Unconstrained minimization of a polynomial Consider the unconstrained optimization problem where p is a polynomial function. min. p(x), (2) x Rn 1. Show that if p has degree 4, testing if problem (2) is unbounded below is NP-hard. 2. Suppose the optimal value p of (2) is finite. Is the optimal value always achieved? (In other words, does there exist x R n such that p(x ) = p?) Why or why not? 3. In class, we showed that if a (not necessarily polynomial) objective function is radially unbounded (i.e., if p(x) + when x + ), then its unconstrained minimum is achieved. unbounded is NP-hard. Show that testing if a multivariate polynomial of degree 4 is radially 5