[ANSWERED] Suppose a linear equation is to be fit predicting raw material price as a linear function of the…

Written by

in

Suppose a linear equation is to be fit predicting raw material price as a linear function of the quantity of product A and produce B (made of the same raw material) sold given the following data:
Quantity of product A sold
Quantity of product B sold
Price of raw material
9
1
5
13
8
2
17
3
9
8
5
10
10
9
4
15
2
6
Assume the prediction equation is
y
i
=
c
0
c
1
x
1
i
c
2
x
2
i
, where
c
1,
c
2 are the prediction parameters on the quantity of products A and B sold, respectively, and
c
0 is the intercept. Define
x
1
i
,
x
2
i
as the observations on the quantity of products A and B sold, respectively, and
y
i
as the observed price. i identifies the
ith
observation.
1) Suppose the desired criterion for equation fit is that the fitted data exhibit minimum of the sum of the absolute deviations between the raw material price and its prediction.
Please develop a LP model to minimize the sum of the absolute deviations solve the formed LP problem using the MATLAB function-linprog.
1) Suppose the desired criterion for equation fit is that the fitted data exhibit minimum of the largest absolute deviation between the raw material price and its prediction.
Please develop a LP model to minimise the largest absolute deviation and write down the tabular form of the formed LP problem.
2) Suppose the desired criteria for equation fit is that the fitted data exhibit minimum sum of the squared deviations between the raw material price and its prediction. You are then asked to solve the formed least square (LS) problem.
– Write down the linear system equation (Ax=B) of the LS problem, and solve it using the normal equations approach.
3) Assume we have two additional groups of datasets similar to Table 1, and for each dataset, we have found out their predictions

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *