Question: Using Matlab The sine function can be evaluated by the following infinite series: As a test case, compute sin(0.9) for up to and including eight
Using Matlab
The sine function can be evaluated by the following infinite series:

As a test case, compute sin(0.9) for up to and including eight termsthat is, up to the term x15/15!.
Utilizing a for-loop, compute and display in sequence the values for all 8 terms as shown below. The neatly formatted output should include the iteration number and computed term and %error.


...
For each of the preceding, compute and display the percent relative error as

This will be done with the sin() function.
Part b)
Modify the above program to use a while loop. Your program will terminate when the %error is less than .008. Display the final calculated value for sin(0.9) and the number of iterations (number of loops) the program took for the computation.
3C 3C ... 31 51
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
