Answered step by step
Verified Expert Solution
Question
1 Approved Answer
The Taylor series about x = 0 for inverse tangent function is given by tan 1 ( x ) = infty n = 0
The Taylor series about x for inverse tangent function is given by
tanx
infty
n
nxn
n
a Write a computer program to evaluate tanx by truncating the series to N terms. Make
sure you include your code in the submission. Describe the choices you made in writing your
program.
b Use your program to approximate pi by evaluating tan for different values of N Display
your results in a form of a table. Make sure your table also includes absolute and relative
errors. For error calculation use that pi
c Repeat the same work by using tan
d Plot the errors and approximations from parts a and b versus the number of terms in the
Taylor expansion on a semilog loglinear and loglog graph. Look at the graphs you made
and make conclusions about the rate of convergence. In MATLAB you can use commands
semilogy and loglog
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started