= Solution
For a launch angle $\theta$, the <projectile motion> equations give a flight time $2u\sin\theta/g$, a <projectile range> $R=u^2\sin(2\theta)/g$, and an apex height $u^2\sin^2\theta/(2g)$. Thus the ceiling requires $\sin^2\theta\leq2gH/u^2$.
Set $z=\sin^2\theta$. Then $R^2=4u^4z(1-z)/g^2$, which increases up to $z=1/2$. The optimum is therefore $z=\min(1/2,2gH/u^2)$, giving the <projectile range under a ceiling>
$$
\boxed{R_{\max}=\begin{cases}
\sqrt{8H(u^2/g-2H)},&0\leq H\leq u^2/(4g),\\
u^2/g,&H\geq u^2/(4g).
\end{cases}}
$$
The printed expression is valid in the first regime. A higher ceiling leaves the usual $45^\circ$ launch admissible, so it cannot reduce the maximum range. The angle in the ceiling-limited regime is $\arcsin\sqrt{2gH/u^2}$. Equality at the roof is allowed in this ideal geometrical model; if touching the roof is forbidden, the same value is a <supremum> approached from below.
\Image[/past-exam-of-the-physics-1-paper-of-the-university-of-oxford/2019-projectile-ceiling.png]
{title=The tunnel ceiling limits low launches, while a sufficiently high roof leaves the ordinary maximum range unchanged}
Back to article page