How to use Euler's method to estimate the velocity of the ball after 1 second?

3.3k Views Asked by At

Original Problem: "A ball is dropped from the top of a tall building. If air resistance is taken into account, recall that the downward velocity $v$ of the ball is modeled by the differential equation:

$dv/dt = g - pv$

where $g$ = 9.8 $m/sec^2$ is the acceleration due to gravity, and $p$ = 0.1 is the drag coefficient. Assuming the initial velocity of the ball is zero, use Euler’s method with a step size of $h$ = .25 sec to estimate the velocity of the ball after one second. Keep track of three decimal places during the calculation."

I just started learning the Euler's method. Can someone help me with this problem. I know that:

$dv/dt = f(v,t) = g - pv$

I plug the numbers given into the equation: $dv/dt = 9.8 - .25v$

change of $x$ = step size ($h$) = .25

I think $(v(0),t(0)) = (0,0)$??

1

There are 1 best solutions below

0
On BEST ANSWER

First, we discretize our domain into points $t_n=nh.$ Then, Euler's method is given by $$V^{n+1}=V^n+hf(V^n),$$ corresponding to the equation $$v'=f(v).$$ The sequence $(V^n)$ should approximate the solution in the sense that $V^n\approx v(t_n)$. In your case, we find that $f(v)=g-pv,$ and since we want to compute up to $t=1$ with $h=0.25,$ we want to compute $4$ iterations (this will correspond to time-stepping up to one second). Since $V^0$ is just the initial condition, we find\begin{align*} V^0&=0\\ V^1&=V^0+hf(V^0)=h(g-pV^0)\\ V^2&=V^1+hf(V^1)=V^1+h(g-pV^1)\\ V^3&=V^2+hf(V^2)=V^2+h(g-pV^2)\\ V^4&=V^3+hf(V^3)=V^3+h(g-pV^3) \end{align*} You can calculate these directly. In particular, the final one gives you $$V^4\approx v(t_4)=v(4h)=v(1).$$