Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem 2: Consider the following function: f(x) = -0.1x4 -0.15x-0.5x -0.25x+1.2 a. Use the Central Difference Method to estimate the first derivative of at



image
image

Problem 2: Consider the following function: f(x) = -0.1x4 -0.15x-0.5x -0.25x+1.2 a. Use the Central Difference Method to estimate the first derivative of at x = 0.5. Start the computation at h = 1, then progressively divide the step size by a factor of 10 to demonstrate how the True Percent Error (roundoff error) becomes dominant as the step size is reduced. Plot the step size vs. the error. Hint: Use the loglog built-in function when plotting. MATLAB LAB 18 - Numerical Differentiation * Write a MATLAB code for Problems 1 and 2 Problem 1: Consider the following function: f(x) = -0.1x4 -0.15x3 -0.5x2 -0.25x + 1.2 a. Use finite difference (Forward, Backward, Center) to estimate the first derivative at x = 0.5 using a step size of h = 0.5. Calculate the True Percent Error for each finite difference approximation b. Use finite difference (Forward, Backward, Center) to estimate the first derivative at x = 0.5 using a step size of h = 0.25. Calculate the True Percent Error for each finite difference approximation c. Which errors are larger, those with a time step of h = 0.5 or those with a time step of h = 0.25?

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Matlab An Introduction with Applications

Authors: Amos Gilat

5th edition

1118629868, 978-1118801802, 1118801806, 978-1118629864

More Books

Students also viewed these Mechanical Engineering questions