Consider an ODE in the form:
$$\dot{y} = f(y) + \alpha \delta(t - t_0)$$
for some $t_0 \geq 0$.
I know that the standard way to solve it numerically is to transform the ODE in order to turn the effect of Dirac delta into initial conditions (see this for example).
Anyway, I was wondering if there is a pure numerical way to solve this kind of problem. Indeed, consider a real world situation in which the system is modeled as:
$$\dot{y} = f(y) + \alpha u(t),$$
where $u(t)$ is some exogenous input which is not known a priori (e.g. a steady current which suddenly becomes impulsive, a steady market and then a shock, the sudden spread of a disease...).
How can we solve numerically the system provided that $u(t)$ is not known and it may also contains impulsive terms without reformulating the ODE based on the knowledge of $u(t)$?