Question: this is for numerical analysis class. please make sure the code of MATLAB is work. ( 1 ) ( Matlab + composite trapezoidal and Simpson

this is for numerical analysis class. please make sure the code of MATLAB is work. (1)(Matlab + composite trapezoidal and Simpson) Let I(f)=abf(x)dx for a con-
tinuous function f.
(a) Implement a Matlab that compute the composite trapezoidal quadrature for-
mula. The function should be define as follows
out =comptrapezoidal (a,b,m,f);
where a and b are a and b,m is the number of subintervals in which a,b is
partitioned, and f is the function f(x).
(b) Implement a Matlab that compute the composite Simpson quadrature formula.
The function should be define as follows
out =compsimpson (a,b,m,f);
where a and b are a and b,m is the number of subintervals in which a,b is
partitioned, and f is the function f(x).
 this is for numerical analysis class. please make sure the code

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 Databases Questions!