Using Runge-Kutta method of fourth order, solve the differential equation $\frac{dy}{dx} = x + y^2$ with $y(0) = 1$, at $x = 0 \cdot 2$. Use four decimal places for calculation and step length $0 \cdot 1$.
Aryan Yadav, AIR 31, 2025
$f(x,y) = y^2 + x$ , given $y_0 = 1, x_0 = 0$
$h = 0.1$
$K_1 = h f(x_0, y_0) = 0.1(1) = 0.1$
$K_2 = h f(x_0 + \frac{h}{2}, y_0 + \frac{k_1}{2}) = 0.1 f(0.05, 1.05) = 0.1152$
$K_3 = h f(x_0 + \frac{h}{2}, y_0 + \frac{k_2}{2}) = 0.1168$
$K_4 = h f(x_0 + h, y_0 + k_3) = 0.1347$
$y(0.1) = y_0 + \frac{1}{6}(k_1 + k_4 + 2k_2 + 2k_3) = \underline{1.1164}$
$k_1 = h f(x_1, y_1) = 0.1216$
$k_2 = h f(x_1 + \frac{h}{2}, y_1 + \frac{k_1}{2}) = 0.1536$
$k_3 = h f(x_1 + \frac{h}{2}, y_1 + \frac{k_2}{2}) = 0.1574$
$k_4 = h f(x_1 + h, y_1 + k_3) = 0.1822$
$y(0.2) = y_1 + \frac{1}{6}(k_1 + k_4 + 2k_2 + 2k_3)$
$y(0.2) = 1.2707$