Estimating parameters of a differential equation

55 Views Asked by At

Suppose I have the following equation:

$$ \frac{dy}{dt} = (a+bx)y $$

If I am given data concerning $y$ i.e. $(t_i, y(t_i))$ and $x_i$, how can I get estimates for the parameters $a$ and $b$?

1

There are 1 best solutions below

4
On

Integrate both sides $$y(t)-y(0)=a\int_0^t y(\tau) d\tau + b\int_0^t x(\tau) y(\tau) d\tau $$ By trapezoidal integration, calculate the functions $$F(t_i)=\int_0^{t_i} y(\tau) d\tau $$ $$G(t_i)=\int_0^{t_i} x(\tau) y(\tau) d\tau $$ numerically from your data.

Now solve the linear least squares problem $$y(t_i)-y(0)=aF(t_i) + bG(t_i) $$ for $a,b$.

($y(0)$ here is the third parameter / boundary condition of which Ian speaks in a comment. You might already know it from your input data, or you can get it as a third solution of the least-squares problem).