Following Data Points Given X 5 6 10 15 20 40 70 100 Y 83 92 100 97 91 75 61 53 Plot Data Q37095918

The following data points are given:

x

5

6

10

15

20

40

70

100

y

83

92

100

97

91

75

61

53

a) Plot the data points as ‘s’ squares.

b) Determine the constants A and B by curve fitting. Output Aand B

to the command window.

c) In the same figure as the data points, plot the fitted curveas a continuous

curve in 3 ≤ x ≤ 120.

Submit: 1) Script, 2) Numerical values of A and B in commandwindow,

and 3) Figure.


Solution


`Hey,

Note: Brother in case of any queries, just comment inbox I would be very happy to assist all your queries

clear all
clc
x=[5,6,10,15,20,40,70,100];
y=[83,92,100,97,91,75,61,53];
disp(‘Values of A and B are’);
C=polyfit(x,y,1)
yy=polyval(C,x);
plot(x,yy,x,y,’s’);

Figure 1 Eile Edit yiew Insert 1ools Desktop Wndow Help 100 95 75 70 65 60 50 10 20 40 60 70 80 90 100 ENG 1049 AM 4) US 04/1

Kindly

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.