Consider the function fx x4 Calculate the first derivative

Consider the function f(x) = x^4. Calculate the first derivative at point x = 3 numerically with the forward, backward and central difference formulas using the points x = 2, x = 3 and x = 4

Solution

First derivative at point x=3 for f(x)= x4 is to be calculated.

i) Forward difference: f\'(x) = [f(x+h)-f(x)] /h
here h= 1; x=3; hence f\'(x)= f(3+1)- f(3) / 1= [44-34]/1 = 256-81 = 175
Thus derivative of f(x) at x=3 from forward difference = 175;

ii) Backward difference: f\'(x) = [f(x)-f(x-h)] /h
here h= 1; x=3; hence f\'(x)= f(3)- f(3-1) / 1= [34-24]/1 = 81-16 = 65
Thus derivative of f(x) at x=3 from backward difference = 65;

iii) Central difference: f\'(x) = [f(x+h)-f(x-h)] / 2h
here h= 1; x=3; hence f\'(x)= [f(3+1)- f(3-1) ]/ 1= [44-24] /2*1 = [256-16]/ 2 = 240/2=120
Thus derivative of f(x) at x=3 from central difference = 120;

 Consider the function f(x) = x^4. Calculate the first derivative at point x = 3 numerically with the forward, backward and central difference formulas using th

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site