Output trajectory even if warnings occur.
Optimize more.