Dynamics of shallow elastic arches. Part II: optimal forms