Question: Using Matlab Using Taylor series expansion, sin(x) for values of x close to zero can be approximated using: sin(x)xx33!+x55!x77!+...xnn! Write a function sinxaroundzero(x,n) that returns
Using Matlab
Using Taylor series expansion, sin(x) for values of x close to zero can be approximated using:
sin(x)xx33!+x55!x77!+...xnn!
Write a function sinxaroundzero(x,n) that returns the approximation for sin(x) using this formula. Assume n is an odd integer.
>> a = sinxaroundzero(1, 1) a = 1 >> a = sinxaroundzero(1, 3) a = 0.8333 >> a = sinxaroundzero(1, 5) a = 0.8417
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
