Menu

[Solved]1 X Approximated Using Following Taylor Series Expansion 12x 1 2 3 4 Create Matlab Functio Q37281184

In (1+x) can be approximated using the following Taylor series expansion: for (12x>-1) 2 3 4 Create a MATLAB function that imendwhile ENDFunctionIn (1+x) can be approximated using the following Taylor series expansion: for (12x>-1) 2 3 4 Create a MATLAB function that implements the Taylor series above. The program should use a while-loop and add a term to the series with each iteration. Calculate the true percent relative error (E,) defined by: true value-approximation true value *100 for each iteration. The true value can be found using the MATLAB’s log function and the approximation is found using the Taylor series expansion. The loop should terminate when the true percent relative error of falls below 0.0001. Use the pseudocode below. Pseudocode is simply code-like statements used for communicating complex code. Pseudocode does not use syntax of any particular coding language, it is purposefully general so that it can be implemented in any language Function [approx] = my-taylor(x) tpre 100 approx = 0 true-value = ln( 1+x) while tpre is greater than.0001 new-term = (-1)n-1- approx- approx+new term true value-approximation true value 100 endwhile ENDFunction Show transcribed image text In (1+x) can be approximated using the following Taylor series expansion: for (12x>-1) 2 3 4 Create a MATLAB function that implements the Taylor series above. The program should use a while-loop and add a term to the series with each iteration. Calculate the true percent relative error (E,) defined by: true value-approximation true value *100 for each iteration. The true value can be found using the MATLAB’s log function and the approximation is found using the Taylor series expansion. The loop should terminate when the true percent relative error of falls below 0.0001. Use the pseudocode below. Pseudocode is simply code-like statements used for communicating complex code. Pseudocode does not use syntax of any particular coding language, it is purposefully general so that it can be implemented in any language Function [approx] = my-taylor(x) tpre 100 approx = 0 true-value = ln( 1+x) while tpre is greater than.0001 new-term = (-1)n-1- approx- approx+new term true value-approximation true value 100
endwhile ENDFunction

Expert Answer


Answer to In (1+x) can be approximated using the following Taylor series expansion: for (12x>-1) 2 3 4 Create a MATLAB function th… . . .

OR


Leave a Reply

Your email address will not be published. Required fields are marked *