Question: Problem 1 Develop an efficient program that creates a plot of the function f ( x ) = 1 2 + 1 2 0 x

Problem 1
Develop an efficient program that creates a plot of the function
f(x)=12+120xe-t2dt
for xin[0,10]. The integral should be approximated using
Q1: the Trapezoidal Rule,
Q2: the Simpson's 3/8 Rule,
and use as few function evaluations of e-t2 as possible.
Problem 2
Consider the function
f(x)=sin(1x+)
for x ranging from 0 to 1, and the derivative
f'(x)=-cos(1x+)(x+)2
where is a given input parameter.
Q1: Develop a program that creates a plot of the derivative of f=f(x) based on a finite difference approximation using n computational nodes. The program should also graph the exact derivative given by f'=f'(x) above.
Q2: Test the program using n=10 and =15.
Q3: How large do you have to choose n in order for the difference between these two functions to be less than 0.1?
Problem 1 Develop an efficient program that

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!