A subtlety in the Brachistochrone problem The following is a specific instance of the brachistochrone
problem, which I first encountered in grad school, and I
have occasionally used as hw problem in teaching CM.

A particle is started from rest at the origin and constrained to fall under gravity along a path $y(x)$ which passes through the point $x=5$, $y=-1$ (in arbitrary units, for example meters). We will assume that the gravitational
potential is linear, $V=mgz$.
a) Determine the path that minimizes the time taken. Make a plot of that path. 
b) Is there another path that makes the time taken stationary? If yes, make
a plot of that path and explain whether this path is a minimum, a
maximum, or a saddle point.

The solution to the brachistochrone problem is of course very
well known, so this assignment is really about finding a specific
cycloid that satisfies the boundary conditions. As part b indicates,
there is more than one: The standard cycloid, and two cycloids that
``bounce''.

Now it is clear that the simple cycloid is the absolute minimum,
because traversal time is proportional to the angle traced out. But
what about the other two? Naively they should be saddles, but
the second variation of the action functional is manifestly
positive, indicating that they are local minima. But that can't be
right, unless there is something funny about the topology of the
space of paths. Are the higher cycloids saddle points or minima?
P.S.: To see that the higher cycloids cannot easily be
dismissed as solutions, consider this plot of the velocity
components $(v_x,v_y)$ as a function of time for the second cycloid.

The corresponding components of the acceleration are:

Clearly, the acceleration (and the forces of constraint) are perfectly smooth.
 A: TL;DR: A path built piecewise from more than 1 cycloid (each with possibly different energy $E$, see below), and with cusps at the $x$-axis, is not stationary.
Sketched proof:

*

*Recall that the action (=spent time) of the brachistochrone problem is
$$S~=~\int_0^a\! \mathrm{d}x~L,\qquad  L~=~\sqrt{\frac{1+y^{\prime 2}}{y}},\qquad y~\geq~ 0,\tag{1}$$
with boundary conditions $y(0)=0$ and $y(a)=b$. (Here the $y$-axis is pointing downwards and we chose for simplicity units of time and space such that $2g=1$.)


*Physically, we demand that the path $x\mapsto y(x)$ is at least continuous. Mathematically, the integrand should just be Lebesgue integrable. To be as simple as possible but also incorporate OP's examples we will strike a convenient compromise and assume that the path $x\mapsto y(x)$ is piecewise continuously differentiable, although we will allow the derivative $y^{\prime}\equiv \frac{dy}{dx}$ to become singular at the points between the pieces as long as the integrand remains Lebesgue integrable.


*It follows that a stationary path necessarily satisfies Euler-Lagrange (EL) equation within the interior of each piece. Additional conditions may arise at the points between the pieces.


*Since the Lagrangian $L$ has no explicit $x$-dependence the corresponding notion of energy (within a piece) is conserved:
$$E~=~ y^{\prime} \frac{\partial L}{\partial y^{\prime}}-L~\stackrel{(1)}{=}~-\frac{1}{\sqrt{y(1+y^{\prime 2})}}~<~0.\tag{2}$$


*The piece solution is a cycloid:
$$\begin{align} 2E^2x~=~&\theta-\sin\theta~\approx~\frac{\theta^3}{6},\cr 
2E^2y~=~&1-\cos\theta~\approx~\frac{\theta^2}{2},\end{align}\tag{3}$$
where the approximation is valid close to the cusp. The cusp-equation becomes
$$ y~\stackrel{(3)}{\propto}~ x^{2/3}.\tag{4}$$
Near the cusp, the particle is performing a free falling motion, which is smooth as a function of time $t$.


*The idea is now to truncate the cusp at some horizontal the level $y=\epsilon\ll 1$, i.e. at some $x~\propto~ y^{3/2}~=~\epsilon^{3/2}$. (We consider for simplicity just the right branch of the cusp -- the left branch is similar.) The action of the cusp is
$$L~\stackrel{(1)+(2)}{=}~\frac{1}{|E|y}~\stackrel{(4)}{\propto}~ x^{-2/3}\qquad\Rightarrow\qquad S~\propto~x^{1/3} ~\propto~\epsilon^{1/2}.\tag{5}$$
For comparison, the action of the horizontal path is as expected faster:
$$L~\stackrel{(1)}{=}~\frac{1}{\sqrt{y}}~=~ \frac{1}{\sqrt{\epsilon}}\qquad\Rightarrow\qquad S~\propto~\frac{x}{\sqrt{\epsilon}} ~\stackrel{(4)}{\propto}~\epsilon.\tag{6}$$
This shows that we can change the action to first order in $\epsilon$, and hence the path is not stationary. $\Box$
