Solution
= Solution
The limiting trajectory grazes the planet at <periapsis> $R_p$. Equating the asymptotic and periapsis values of <specific angular momentum> and using the <vis-viva equation> gives
$$
b_{\min}^2\Delta v_{pc}^2
=R_p^2\left(\Delta v_{pc}^2+\frac{2GM_p}{R_p}\right).
$$
Hence the comet avoids the planet when
$$
\boxed{b>b_{\min}=R_p\sqrt{1+\frac{2GM_p}{R_p\Delta v_{pc}^2}}}.
$$