Write a function to return the value of Rosenbrock's two-dimensional banana function, as well as it's gradient (column) vector and Hessian matrix, given a vector of it's two independent variables x1 and x2. Here's the Rosenbrock function:
100*[(x2-x1^2)^2] + (1-x1)^2
Solution Stats
Problem Comments
2 Comments
Solution Comments
Show comments
Loading...
Problem Recent Solvers169
Suggested Problems
-
Project Euler: Problem 2, Sum of even Fibonacci
2940 Solvers
-
Project Euler: Problem 7, Nth prime
1785 Solvers
-
Convert a numerical matrix into a cell array of strings
2597 Solvers
-
Find a subset that divides the vector into equal halves
405 Solvers
-
Implement a bubble sort technique and output the number of swaps required
404 Solvers
More from this Author17
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
@Robert, can you please verify that the last test case is correct?
I corrected a typo, checked the "Restore all solutions" box, and clicked "Save." Not sure how to tell when they're rescored.