Question
Limit of a function Consider the function and the limit as x approaches zero: f ( x ) = 1 ? cos( x )/x lim
Limit of a function
Consider the function
and the limit as x approaches zero:
f (x) = 1 ? cos(x)/x
lim f (x).
x?0
Since there is a division by zero, Matlab cannot compute f (0). Find the limit of f (x) as x ap- proaches zero numerically. You may find the function logspace useful: logspace(a,b,c) makes a vector of values from a to b of length c then raises 10 to that vector. In this way, logspace(0,-3,4) returns the numbers 100, 10?1, 10?2 and 10?3.
What is the order of convergence? You may answer this question analytically or numerically. For full marks, figure out the order of convergence using Taylor series and see if your numerical data agrees with your answer.
What is the smallest value of x you can use? Why might this be the case? Identify sources of round-off error and how they may affect your results.
Your report cannot exceed one page. It should include at least one figure with proper labels. Make sure to choose axis scales appropriate for the data. Discussions should be kept brief and answer all questions asked.
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