  We perform the first tight convergence analysis of the gradient method with
varying step sizes when applied to smooth hypoconvex (weakly convex) functions.
Hypoconvex functions are smooth nonconvex functions whose curvature is bounded
and assumed to belong to the interval $[\mu, L]$, with $\mu<0$. Our convergence
rates improve and extend the existing analysis for smooth nonconvex functions
with $L$-Lipschitz gradient (which corresponds to the case $\mu=-L$), and
smoothly interpolates between that class and the class of smooth convex
functions. We obtain our results using the performance estimation framework
adapted to hypoconvex functions, for which new interpolation conditions are
derived. We derive explicit upper bounds on the minimum gradient norm of the
iterates for a large range of step sizes, explain why all such rates share a
common structure, and prove that these rates are tight when step sizes are
smaller or equal to $1/L$. Finally, we identify the optimal constant step size
that minimizes the worst-case of the gradient method applied to hypoconvex
functions.
