Solution (source code)

= Solution

For the second-order <boundary value problem>, introduce an unknown initial slope $s$ and solve the <initial value problem> $u'=v$, $v'=g(x,u,v)$ with $u(a)=\alpha$, $v(a)=s$. Its endpoint mismatch is $F(s)=u(b;s)-\beta$. The <shooting method> seeks a root $F(s)=0$; in general the dependence of the flow on $s$ is nonlinear. A sign-changing bracket for a continuous $F$ allows the <bisection method>, provided the intervening initial value solutions exist up to $b$.

For <Newton's method>, solve the <parameter sensitivity equation> alongside the trajectory. With $z=\partial_su$ and $w=\partial_sv$,
$$
z'=w,\qquad w'=g_u z+g_{u'}w,\qquad z(a)=0,\quad w(a)=1.
$$
Then $F'(s)=z(b)$ and the update is $\boxed{s_{\mathrm{new}}=s-F(s)/z(b)}$ whenever $z(b)\ne0$.

For the third-order problem, shooting from $a$ leaves both $u'(a)$ and $u''(a)$ unknown, requiring two shooting parameters to satisfy two right-endpoint conditions. Shooting backwards from $b$ already knows $u(b)=\beta$ and $u'(b)=\gamma$; only $u''(b)$ is unknown, with the single residual $u(a)-\alpha$. \b[Backward shooting reduces the nonlinear solve from two scalar unknowns to one.] This parameter-count advantage does not by itself guarantee numerical stability of backward integration.