Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

( Strange behavior of a continuous function: LM 3 . 1 - 2 5 ) Consider the function f ( x ) = { e

(Strange behavior of a continuous function: LM 3.1-25) Consider the function
f(x)={ex-1xifx01ifx=0
This is a continuous function for all xinR, but numerically it has difficulties when x~~0.
(a) Check this yourself by letting x=10-k for k=1,2,dots,15. Generate a nice table using
either disp or fprintf. Do it without using any loop.
(b) Repeat the previous part but rewrite f(x) as
f2(x)={ex-1logexifx01ifx=0
which was proposed by Bill Kahan. Leave the denominator as logex- do not convert
it to x. Do it without using any loop.
(c) Summarize the results of the two parts into a single table. The table should have three
columns with the first being x, the second being f(x), and the last being f2(x). Use
format long g for your output if using disp; use a compatible format specification
if using fprintf. Do it without using any loop.
Note. Write your code inside a single code block for each part. You do not need to write a
function for this problem.
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Principles Of Database Systems With Internet And Java Applications

Authors: Greg Riccardi

1st Edition

020161247X, 978-0201612479

More Books

Students also viewed these Databases questions

Question

What are some ways you can make your paragraphs more effective?

Answered: 1 week ago