Question: Given x = [0 , 025, 0.5 , 075, 1.01, f(x)-|0 ,0.0 151.0.1 102, 0.3167, 0.5958] Write a Matlab program to 1) Ev aluate the

Given x = [0 , 025, 0.5 , 075, 1.01, f(x)-|0 ,0.0 151.0.1 102, 0.3167, 0.5958] Write a Matlab program to 1) Ev aluate the integral of fo) in the interval 10.1) using the composite trapezoidal rule with n-4 segments. Return the integral in the output variable 11 2) Evaluate the integral of fo) in the interval (0,1] using the composite Simpson 1/3 rule with n-4 segments. Return the integrat in the output variable 12 3) Evaluate the integral of f(Xr21n the interval 0.1 using the composite trapezoidal rule with n=4 segments. Return the integral in the output a ables 4) Evaluate the integral of (o) 2 in the interval [O, 1] using the composite Simpson 1/3 rule with n-4 segments. Return the integral in the output variable 14 Your Function function [11, I2, 13,I4] Integration) a XOutput: 41 % 11: complgite Trapezoidal Rule for f(x) I2: Composite Simpson Rule for f(x) 13: Composite Trapezoidal Rule for f(x)"2 14: composite simpson Rule for f(x)2 6% WRITE YOUR CODE BELOW
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
