Consider the differential equation $$\frac{dx}{dt}=\frac1{2x}.$$ This is a separable O.D.E. so we know how to find all of its solutions: they are of the form $$x(t)=\sqrt{t+C}$$ where $C$ is a constant. Imposing the initial condition $x(1)=1$ fixes $C=0$. Then we have $x(2)=\sqrt2$.
Using Euler's method with $h=1/2$ find an approximation to $\sqrt2$. Provide a numeric answer rounded to two decimal places.
Can't seem to be getting anywhere. Can someone please give me hint/solution of the question in the link above?
1 Answer
$\begingroup$We exploit the fact that $x(t)=\sqrt t$ satisfies the given differential equation with initial condition $x(1)=1$. Using Euler's Method, we then get:
$$x\left(\frac32\right)\approx x(1)+\frac12\cdot x'(1)=1+\frac12\cdot\frac{1}{2\cdot1}=\frac54$$ $$x(2)\approx x\left(\frac32\right)+\frac12\cdot x'\left(\frac32\right)\approx \frac54 + \frac12\cdot\frac{1}{2\cdot\frac54}=\frac{29}{20}=1.45$$
Hence $\sqrt2=x(2)\approx1.45$
$\endgroup$ 2