Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Using MATLAB please solve. Problem 1: Numerical differentiation for equally spaced data points (Gilat 6.17) a) Write a MATLAB user-defined function that determines the first
Using MATLAB please solve.
Problem 1: Numerical differentiation for equally spaced data points (Gilat 6.17) a) Write a MATLAB user-defined function that determines the first and second derivatives of a function that is given by a set of discrete points with equal spacing. For the function name use Idy, d2yl-FirstSecondDeriv (x, y). The input arguments x and y are vectors with the coordinates of the points, and the output arguments dy and d2y are vectors with the values of the first and second derivatives, respectively, at each point. For calculating both derivatives, the function should use the finite difference formulas that have a truncation error of O(h?), i.e, second order difference equations. Hint: Refer to the formulas presented in Table 1 and Table 2 attached. b) Use the function FirstsecondDeriv to calculate the derivatives of the function that is given by the following set of points: 0.5 0 0.5 2.5 3.5 4.5 (x) 3.632 -0393506487 -1282 4518 8.611 -1282 -1591 -15.88 9.402 9017Step 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