Question: Numerical methodsWrite a user - defined function in MatLab that applies the Ridders interpolation method for calculating derivatives. The function should be called [ a
Numerical methodsWrite a userdefined function in MatLab that applies the Ridders interpolation method for
calculating derivatives. The function should be called
DerivativeRidders func err where a is the Romberg matrix, is the
derivatrive, func is the function defined with function handle @ is the value at which the
derivative is required, is the step and err is the error. For the derivative the function should
use the twopoint central difference scheme. If the err is not defined, the function should select
automatically er If the function should show a message must be nonzero'. The
error should be calculated as the maximum value compared with the previous two values eg
for the case of B the error should be the maxabsBA absBA see lecture slides
Use also format long in the function so that you see as many digits as possible. The size of
the Romberg matrix should be fixed to number The only buildin functions of MatLab you
are allowed to use are: nargin, feval, max, abs disp. After building the function use it to
estimate the derivative of function:
at with Report the results and submit with the MatLab files.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
