Optimal spatiotemporal reduced order modeling, Part II: application to a nonlinear beam