I am stuck in part B of this exercise (I am giving the whole exercise though). I would really appreciate it if someone could explain to me how to solve this type of integral. Thanks a lot!
Question: The usual way of deriving Adams-Bashforth multistep methods is to pass an interpolating polynomial through the previous $k$ values of the derivative, then integrate this from $t_{n+k-1}$ to $t_{n+k}$. An alternative approach, which leads to the Nystrom methods, is to start from the identity $$y(t_{n+k})=y(t_{n+k-2})+\int_{t_{n+k-2}}^{t_{n+k}}f(\tau,y(\tau))d\tau$$ which is satisfied by the exact solution. Then replace $f$ by the same interpolating polynomial (the one through the previous $k$ points), then integrate to get a formula for calculating $y_{n+k}$.
(A) With $k=2$, find the polynomial $P$ that interpolates $(t_n,y_n)$, $(t_{n+1},y_{n+1})$.
Answer: $$P(t)=y_n+(t-t_n)\frac{y_{n+1}-y_n}{h}$$
(B) Replace $f$ in the identity above with $P$ from part (a), and use this to obtain a numerical method of the form $$y_{n+2}-y_n=h\left(\beta_0 y_n'+\beta_1 y_{n+1}'+\beta_2 y_{n+2}'\right)$$ Explicitly calculate the coefficients $\beta_0$, $\beta_1$ and $\beta_2$. Then verify the order of the method is 2.
Answer: $$y_{n+2}-y_n=\int_{t_n}^{t_{n+2}}P(t)dt=\int_{t_n}^{t_{n+2}}\left[y_n+(t-t_n)\frac{y_{n+1}-y_n}{h}\right]dt$$
and I get lost there Apparently the result is:
$$=2hy_n+2h(y_{n+1}-y_n)=2hy_{n+1}$$