Imagine you want to emulate a continuous system with a discrete difference equation of the form $$f(\tau+1) = f(\tau) + F(\tau)$$ $$f(0) = 0$$ where $F(t)$ is a function which states how the system change at every step.
Imagine you have a simple continuous function $\dot{f}(t) = t$ which you want to emulate in the discrete. Is clear that $f(t) = \frac{t^2}{2}$. The first naive thing one would do is to say that $$f(\tau + 1) = f(\tau) + \tau$$ But this does not capture the continuous function at all since the system evolves like this
| $\tau$ | $f(\tau) = f(\tau-1) + (\tau-1)$ | $f(\tau) = \tau^2/2$ |
|---|---|---|
| 1 | 0 | 1/2 |
| 2 | 1 | 2 |
| 3 | 3 | 9/2 |
Instead the right discrete equation (found knowing in advance that $f(t)=t^2/2)$ is $$f(\tau + 1) = f(\tau) + \tau + \frac{1}{2}$$
| $\tau$ | $f(\tau) =f(\tau-1) + (\tau-1) + 1/2$ | $f(\tau) = \tau^2/2$ |
|---|---|---|
| 1 | 1/2 | 1/2 |
| 2 | 2 | 2 |
| 3 | 9/2 | 9/2 |
Let's suppose I have now any continuous function $f(t)$ which I want to "imitate" with a discrete function $F(\tau)$.
- The imitation is possible for any continuous integrable function $f(t)$ or sometimes it's not possible ?
- Is there a closed form formula/transform which allows me to compute $F(\tau)$ from $\dot{f}(t)$ ?
- Con you point me towards literature that explain this ?
I am not sure if this answers your second question: we can choose $I=F(\tau)=\int_\tau^{\tau+1}f’(x)dx$, but computing this integral can be difficult or not possible at all, but there is several methods to numerically approximate this integral. One method involves splitting our domain of integration into smaller pieces, then approximate the integral on each piece and finally adding the results for each piece together. It is called the general quadrature method. It says that if we want to approximate some integral $J=\int_0^h \phi(x)dx$, we let the approximation $\tilde{J}=h\sum_{i=1}^s b_i\phi(c_ih)$ for some weights $b_i$, nodes $c_i$ and integer an $s$. We have the following result:
Theorem. Whenever $\phi$ is a polynomial of degree $<p$
$J=\tilde{J}$ if and only if $\sum_{i=1}^sb_ic_i^{j-1}=1/j$ for $j=1,2...,p$
In chapter 5 of these notes they explain further how much $J$ and $\tilde{J}$ differ when the approximation is not exact.