I have the following problem (linearized pendulum problem):
$x_1'=x_2$
$x_2'=-\frac{g}{L}*sin(x_1)$
with the following initial condition:
$x_1(t_0)=0$
$x_2(t_0)=0$
Improved Euler Method says that:
$Y_{k+1}=Y_k+\frac{h}{2}*[f(t_k, Y_k)+f(t_{k+1}, Y_k+h*f(t_k, Y_k))]$
In this case I have done the following:
$x_{1, k+1}=x_{1, k}+\frac{h}{2}*[x_{1, k}+(x_{1, k}+h*x_{1, k})]$
$x_{2, k+1}=x_{2, k}+\frac{h}{2}*[-\frac{g}{L}*sin(x_{1, k})+-\frac{g}{L}*sin(x_{1, k}+h*(-\frac{g}{L}*sin(x_{1, k}))))]$
Where is my mistake?
