Question

1. Matlab has a function fminsearch that can be used to determine the minimum of a multidimensional function. It is based on the Nelder- Mead method, which is a direct-search

method that uses only function values (does not require derivatives) and handles non-smooth objective functions fairly well. Consult the Matlab help pages and write a Matlab code that uses fminsearch to determine the minimum of the function, f(x1, r2) = 2+ *1 - x2 + 2xỉ + 2r1r2+ in the range -2 < xn s0 and 0 < r2 < 3. You might need to use a related function thatincorporates bounds!

Fig: 1

Fig: 2

Fig: 3