bv_cvxbook_extra_exercises

# Give an approximate op count of your method i 88 we

This preview shows page 1. Sign up to view the full content.

This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ; m = 200; randn(’state’,1); A=randn(m,n); Of course, you should try out your code with diﬀerent dimensions, and diﬀerent data as well. In all cases, be sure that your line search ﬁrst ﬁnds a step length for which the tentative point is in dom f ; if you attempt to evaluate f outside its domain, you’ll get complex numbers, and you’ll never recover. To ﬁnd expressions for ∇f (x) and ∇2 f (x), use the chain rule (see Appendix A.4); if you attempt to compute ∂ 2 f (x)/∂xi ∂xj , you will be sorry. To compute the Newton step, you can use vnt=-H\g. 8.4 Suggestions for exercise 9.31 in Convex Optimization. For 9.31a, you should try out N = 1, N = 15, and N = 30. You might as well compute and store the Cholesky factorization of the Hessian, and then back solve to get the search directions, even though you won’t really see any speedup in Matlab for such a small problem. After you evaluate the Hessian, you can ﬁnd the Cholesky factorization as L=chol(H,’lower’). You can then compute a search step as -L’\(L\g), where g is the gradient at the curre...
View Full Document

## This note was uploaded on 09/10/2013 for the course C 231 taught by Professor F.borrelli during the Fall '13 term at Berkeley.

Ask a homework question - tutors are online