Write a MATLAB function to calculate the values of f(x)where
F (x) = x2 sin (x2)
for any vector x. In addition write a function which takes the vector x and finds the element with the minimum value, xmin, and the element with the maximum value, xmax, and returns the value of the scalar r where:
r =(xmax −xmin)/(xmax +xmin)
Write a MATLAB script which will obtain the values of the function, f(x), for x =0 to 10 in increments 0.1 and plot a graph of this function. Then use the function you have written to calculate the value of r. Save the MATLAB script together with the functions using the name functiontest and run it. Use the function fimplicit3 to draw the implicit function
(x2 + y2−3x) 2−4 x2 (2−x) = 0
Use the ranges of values for x and y as 0 to 2, and−3 to 3 respectively. Label the x and y axes appropriately and give the graph a title.