There is a small problem with the whole setup and maybe I can clarify the issue, by pointing out this small error when constructing the differential equation.
Although I am not sure how banks do it, the differential equation should be valid for any amount of time passing: $t$ is measured in years, but fractional values are still allowed. So, an effective annual return is assumed to work like that:
$$P(1)=P(0)\times(1+r)\,,$$ not taking withdrawals into account.
But waiting just one week and looking at the account needs a different $r$, i.e. this would not be
$$P(1/52)\ne P(0)\times\left(1+\frac{r}{52}\right)\,,$$ as you could iterate that to something inconsistent. 52 weekly returns need a different rate constant than one yearly return:
$$P(52\times1/52)=P(0)\times\left(1+\frac{r}{52}\right)^{52} \ne P(0)\times(1+r)$$
So, depending on how much smaller the given period is, the return percentage needs to be a bit smaller than $r$. The correct (effective, infitesimal) rate constant $k$, valid for tiny steps, should be calculated as:
$$\log(1+r)=\log\left(\lim_{n\to\infty} (1+k/n)^n\right) = k\,,$$ this is because the limit turns out to be an exponential: $\exp(k)$ (hence we take the logarithm).
As a side note: for small $r$, that turns out to be:
$$r \ll 1: \quad k\approx \frac{r}{1+r}\,,$$ so, definitely not $r$: $k\ne r$.
Given Example (with $r=0.05$): By taking the natural logarithm of $(1+0.05)$ we get $k=0.04879$ (slightly less than $r$).
Solving the differential equation, with known $k$
$$\dot P = kP\,,\quad P(0)=P_0$$ we get
$$P(t)=P_0 \exp(kt)\,,$$
which, after one year, yields $P(1)=P_0\times 1.05\,,$ as we wanted it to do.
Now, annual accumulated withdrawals are tricky as they can occur at precise moments, or spread out. But, if we assume an almost steady (constant) rate of—say—daily withdrawals:
$$365\times\left(P(t+1/365) - P(t)\right)=-w\,,$$
which amount to $w$, it begins to look like an approximated derivative. Assuming small time steps between withdrawals, we get:
$$\Delta_t \ll 1:\quad \dot P \approx \frac{P(t+\Delta_t) - P(t)}{\Delta_t} = -w$$
So, no surpises, just a linear rate constant: any amount of time can be multiplied with this rate to get the aggregated withdrawals for that time length.
Combining the two actions we get:
$$\frac{dP}{dt}=-kP-w\,,\quad P(0)=P_0\,,$$ where $k=\log(1+r)\,.$