Matlab + Ordinary Least Squares (OLS) method

246 Views Asked by At


I'll be very grateful if you'll help me to solve the equation with Ordinary Least Squares (OLS) method + Matlab.

Given:

$P=\frac{mt}{b+t}$

Also:

t=[1,3,4,7,8,10]
P=[2.1, 4.6, 5.4, 6.1, 6.4, 6.6]

1) Write P in Matlab.
2) Find b,m by solving the equation with Ordinary Least Squares (OLS) method.


Thank's.

1

There are 1 best solutions below

1
On BEST ANSWER

Hint:

Write the equation this way $$\frac{1}{P}=\frac{b}{m}\cdot\frac{1}{t}+\frac{1}{m}$$