![= caculate!mpulse.m RUNV octave:2> calculateImpulse([0.0,1.5,2.5,3,2.5,1.5,0.0]) ntegralValue = 11 #save this following code](http://img.homeworklib.com/images/c961ed7a-f591-47b5-a7a7-faea3721909b.png?x-oss-process=image/resize,w_560)

#save this following code in calculateImpulse.m to work as a
userdefined function
#defining a function for our integral calculation which accepts an
array of elements
function calculateImpulse(ArrayOfFloats)
#calling inbuilt method in matlab to calculate Integral value
IntegralValue = trapz(ArrayOfFloats)
#plotting with matlab plot function
plot(ArrayOfFloats)
end
#calling the above function from command line (or we can call from other function also)
>>> calculateImpulse([0.0,1.5,2.5,3,2.5,1.5,0.0])
#result
IntegralValue = 11
Produce following function in MATLAB eeeceved. 3) calculatelmpulse: consumes a series (represented by a column-vector of floats)- and computes the integral-of the series using trapezoidal numeric...
(a) (4 points) Fill in the blanks in the following MATLAB function M file trap so that it implements the composilu trapezidul rulo, using a soquence of w -1,2, 4, 8, 16,... trapezoids, to approximatel d . This M file uses the MATLAB built-in function trapz. If 401) and y=() f(!)..... fr. 1)). 3= ($1, then the execution of z = trapz(x, y) approximates using the composite trapezoidal rule (with trapezoids). (Note that the entries of are labeled starting at...