matlab数值优化代写: NUMERICAL OPTIMISATION ASSIGNMENT 0

EXERCISE 1.

NUMERICAL OPTIMISATION ASSIGNMENT 0: EXAMPLE

MARTA BETCKE KIKO RUL·LAN

  1. (a)  Write a Matlab function that implements the Rosenbrock function f(x,y)=100(y−x2)2 +(1−x)2.

    Be careful to implement a function that can be evaluated at many points simulta- neously.
    Submit your implementation via Cody Coursework.

  2. (b)  Create a two dimensional grid using Matlab’s command meshgrid. Plot f using your implemented Matlab’s function on the grid. Check out the following func- tions: surf (use option ’EdgeColor’ = ’none’ when using many grid points), surfc, contour, contourf. Can you see the minimiser? Can you use some transformation to highlight the minimiser?

    Submit your solution via Turnitin.

  3. (c)  Calculate the gradient ∇f and the Hessian ∇2f.

    Submit your solution via Turnitin.

  4. (d)  Find the minimiser x∗ of the function f. Show that x∗ is unique and that ∇2f(x∗) is positive definite.
    Submit your solution via Turnitin.
  5. (e)  Compute the gradient ∇f and the Hessian ∇2f numerically using finite differences. Check out the functions gradient, diff, and implement finite differences as a matrix multiplication.
    Submit your solution via Turnitin.

Remark. The submission to Turnitin should not be longer than 2 pages. Avoid submitting more code than needed (if any) and focus on explaining your results.

1