Answered step by step
Verified Expert Solution
Question
1 Approved Answer
( 3 ) Write a Matlab routine for implementing the steepest descent method. ( The routine should be written from scratch you to write a
Write a Matlab routine for implementing the steepest descent method. The routine should
be written from scratch
you to write a generalized function that works for any function to optimize. Its inputs could be
"initial vector" and the function to be optimized, and outputs can be the optimal values and
error through iterations.
Your routine should be able to find the minimum of a function with multiple variables using the
following step size methods:
i constant step size
ii variable step size
iii quadratic fitting
A Execute your routine for minimizing Rosenbrock function :
Terminate the algorithm when If the number of iterations exceeds
terminate it regardless of the norm of the gradient. Initialize the input vector of the first
iteration as
B Plot the error as with respect to the iteration number for each step size methods.
C Compare the convergence rates, computation times, final error and final iteration number
for each method in a neat Table. Give your brief comments.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started