# What is the derivation of the values of a1, a2, p1 and 11 in the Second Order Runge Kutta Method?

So currently I am studying about the Runge Kutta Second Order Method used to estimate first order ordinary differential equations. The following show the formulas. $$y_{i+1} = y_i + (a_1k_1+a_2k_2)h$$ $$k_1 = f(x_i,y_i)$$ $$k_2 = f(x_i + p,y_i + q_{11}k_1h)$$ $$a_1 + a_2 = 1$$ $$a_2p_1 = \frac{1}{2}$$ $$a_2q_{11} = \frac{1}{2}$$ Now I have read that it came from Taylor's Series and that the equations estimate the derivative. But I want to have a better intuition and understanding of where it came from and what the constants $$a_1, a_2, p_1$$ and $$q_{11}$$ actually mean. Why is it that $$a_2$$ changes depending on the type of Runge Kutta Method? Why does a $$q_{11}$$ exist if it looks like it is equal to $$p_1$$? What does the subscript 11 in $$q_{11}$$ stand for? I've read about this topic but not all sources are user friendly so I decided to ask here.

Specific explanation: Consider the ODE $$\dot{y}=f(t,y)$$. The exact solution $$y(t)$$ verifies $$y_{n+1}=y_n + \int_{t_n}^{t_{n+1}}f(t, y(t)) dt$$ for each time step. To numerically compute the integral, one of the quadrature rules can be used, which consist of computing the weighted average of some selected function values on the domain of integration (see example at the end).

The different RK-schemes (roughly spoken) reflect the different quadrature rules. The $$k_i$$ represent the values of $$f$$ at the respective points on the domain, and the $$a_i$$ represent their weights. In your case, there are only two points:

1. $$k_1$$ is evaluated at $$t_i$$: $$k_1=f(t_i,y(t_i))=f(t_i,y_i)$$
2. $$k_2$$ is evaluated at $$t_i+p$$: $$k_2=f(t_i+p, y(t_i+p))$$

As $$y(t_i+p)$$ is unknown, it has to be estimated based on $$k_1$$. The $$q_{ij}$$ now represent how the other $$k_i$$ are to weighten for this estimation (as you have only one other $$k$$, the indexing is a little missleading in this example).

General notation: I'd like to add that your notation is not the commonly used one. The general RK-scheme reads: $$y_{n+1} = y_n + h \sum_{j=1}^s b_j k_j$$ with $$k_j = f\left(t_n + h c_j, y_n + h \sum_{l=1}^s a_{jl} k_l \right),\,j=1,...,s$$

As you see, your $$q_{ij}$$ is usually denoted $$a_{ij}$$, your $$p$$ is denoted $$c_j$$ and your $$a_i$$ is denoted $$b_i$$. I never saw any other notation, so I'd recommend to stick to that.

Moreover, these parameters are usually presented in a so called Butcher tableau: $$\begin{array}{c|cccc} c_1 & a_{11} & a_{12}& \dots & a_{1s}\\ c_2 & a_{21} & a_{22}& \dots & a_{2s}\\ \vdots & \vdots & \vdots& \ddots& \vdots\\ c_s & a_{s1} & a_{s2}& \dots & a_{ss}\\ \hline & b_1 & b_2 & \dots & b_s\\ \end{array}$$\

For consistency, the weighting parameters have to be normalized, which reads:

1. $$\sum_{i=1}^s b_i=1$$
2. $$\sum_{j=1}^s a_{ij}=c_i$$

You can verify that these fit your three last equations.

Quick example on quadrature rules: Simpson's rule (of second order) attributes the value in the middle of the domains four times the weight of the values at the boundary: $$\int_{x_0}^{x_0+h}g(x) = \frac{h}{6}\,\left[g(x_0)+4g(x_0+h/2)+g(x_0+h)\right]$$ The weights are defined by integrating the interpolating polynoms of the desired order.

• +1, but I'd point out that it's Butcher, the name, not butcher, the meat-cutter. Given the English equivalent and the number of butcher (block) tables for sale in stores, I'd say capitalized is preferable. Dec 22, 2020 at 17:25