Question: using matlab Goal: This assignment is about Taylor polynomials for the natural logarithmic function ln(x) and the absolute error in using these polynomials to approximate
Goal: This assignment is about Taylor polynomials for the natural logarithmic function ln(x) and the absolute error in using these polynomials to approximate ln(x). What you have to submit: Two Matlab m-files; one a function file and the second a script file. Submit these files on ilearn. TASKS 1. Create a Matlab function file named taylor-approx-ln.m, which takes as input a real number x (or a vector), a real number a>0, and a non-negative integer n. The function outputs are (a) pn(x), the value of the nth Taylor polynomial of ln(x) about the point x=a evaluated at x. (b) The absolute value of the error in the approximation. 2. Create a Matlab script file named plot_taylor_approx_ln.m. Let a=1. Plot ln(x),p0(x),p1(x), p2(x),p3(x),p10(x) on the interval [0.1,2.3]. Have all graphs on the same figure file and use the Matlab legend command to label each graph
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
